Files not getting deleted after job finishes
Posted: Fri Jun 22, 2018 6:31 am
Hello!
We've been using Afanasy for a while but have just discovered how to use the Maya plugin for it. We have noticed that the plugin creates a temporary .mb file that it should delete at the end of the job. But when the render job has finished the temporary file always stays there if sent from the Maya plugin.
If we send a job from the main Afanasy Send Job app no temporary files are left at the end of the job. I have checked the plugins code and have noticed that it is setting the deletefiles command when creating the job:
Just in case, I changed the previous code to
but it still doesn't do anything. I forced the plugin to send a specific file to delete and then checked the job which is being sent to afanasy:
everything looks okay to me... does anyone know why this is happening and how to solve it?
We've been using Afanasy for a while but have just discovered how to use the Maya plugin for it. We have noticed that the plugin creates a temporary .mb file that it should delete at the end of the job. But when the render job has finished the temporary file always stays there if sent from the Maya plugin.
If we send a job from the main Afanasy Send Job app no temporary files are left at the end of the job. I have checked the plugins code and have noticed that it is setting the deletefiles command when creating the job:
Code: Select all
job.setCmdPost('deletefiles "%s"' % os.path.abspath(filename))
Code: Select all
job.setPostDeleteFiles(os.path.abspath(filename))
Code: Select all
{'folders': {'input': 'C:/Users/cristiansoler/Documents/maya/projects/default/scenes', 'output': 'C:/Users/cristiansoler/Documents/maya/projects/default/images'}, 'command_post': 'deletefiles "C:/Users/cristiansoler/Documents/maya/projects/default/scenes/testRedshift.180621-135228-622.mb"', 'blocks': [{'files': ['C:/Users/cristiansoler/Documents/maya/projects/default/images/testRedshift.png'], 'capacity': 1000, 'name': u'defaultRenderLayer', 'service': 'maya_redshift', 'frames_per_task': 1, 'parser': 'maya_redshift', 'command': 'mayarender -s @#@ -e @#@ -b 1 -rl "defaultRenderLayer" -proj "C:\\Users\\cristiansoler\\Documents\\maya\\projects\\default" C:/Users/cristiansoler/Documents/maya/projects/default/scenes/testRedshift.180622-083008-760.mb', 'frame_last': 4, 'working_directory': 'C:\\Users\\cristiansoler', 'frame_first': 1, 'flags': 1, 'frames_inc': 1}], 'name': 'testRedshift', 'time_creation': 1529649008, 'priority': 99, 'host_name': 'bikes18', 'user_name': 'cristiansoler'}