Draft Shotgun - No Auto Fields Filling

Submit Draft Script To Deadline dialog box doesn’t update the Draft Options fields when it is launched from within Shotgun from Shot/Versions tab -> Right Click -> Submit Draft Job.
In a command prompt window I see Draft pulls all the data from Shotgun (such as User Name, Shot Name, Entity, ID, Frame Range). But unfortunately none of it is being used to populate the fields.
The fields have to be manually changed or filled every time the Draft is called to create a quicktime: Path to Frames, Frame List, Entity, Version.
Since it is clearly seen at the command prompt window output Draft can see the data coming out of Shotgun why then it doesn’t use it to populate the fields with the data? I wonder if it is an expected behavior?

Interesting, that if I right - click on one of the completed rendered tasks in Deadline Monitor and select from a pop-up menu “Scripts - Submit Draft Job” - a very similar “Submit Draft Job To Deadline” dialog box appears (similar to the one that is being initiated from Shotgun). But when the Draft Job is called from Deadline-Monitor all submission dialog box’s fields are filled correctly.
Now I close the Draft Submission dialog box that was opened from Deadline Monitor and return back to Shotgun. I run “Submit Draft Job” command from Shotgun. But now all the fields are correctly filled! I thought may be the Draft Submission dialog box just remembered the values taken from Deadline Monitor submission. I double checked it by running a job from a different shot. Running a Draft Submission in Deadline Monitor somehow fixes the Shotgun’s Submit Draft Job… but only temporary… Shotgun Draft submission will work correctly by filling the values taken from Shotgun… but only once. Then it again stops reading Shotgun values.
If I try to run Submit Draft Job from Shotgun again let’s say for another Version or another Shot… It again doesn’t update the values it supposed to take from Shotgun. In order to make Job Submission Dialog box get the Shotgun values and to populate the submission dialog box fields I have to return back to Deadline Monitor to do the trick again by right-clicking on one of the completed tasks (doesn’t matter what) and selecting from the pull down menu - Submit Draft Job. All the fields are field correctly by Deadline Monitor Draft Job Submission script. Now I can return to Shotgun and safely run another Draft submission from there… for another Version… it doesn’t have to be the same version I just selected in Deadline Monitor. But once again, the Shotgun Draft Submission will only work once.

It is worth to mention that command prompt window that pops up every time Submit Draft Job (from Shotgun) shows the same error:
Here is the entire output of the command prompt window:

draft
submit_job_to_deadline
{‘server_hostname’: ‘test.shotgunstudio.com’, ‘project_name’: ‘test_project’, ‘user_id’: ‘39’, ‘entity_type’: ‘Versi
path_to_frames’, ‘created_at’, ‘sg_uploaded_movie’], ‘ids’: ‘5660’, ‘selected_ids’: ‘5660’, ‘referrer_path’: ‘/detail/S
e’, ‘Artist’, ‘Description’, ‘Frame Count’, ‘Status’, ‘Path to Frames’, ‘Date Created’, ‘Uploaded Movie’]}
fromshotgun version=5660
WARNING: disabling profiling because of error begin profiling section twice without ending the first one (Invoke Type).

This warning message : disabling profiling because of error begin profiling section twice without ending the first one (Invoke Type)
appears only after a successful sumbission… the submission that read the Shotgun values fields properly.
The Submit Draft Job sessions that do not read the Shotgun values don’t display that error message.

I also noticed that Shotgun version of Draft Submission doesn’t support all the Draft templates that DeadlineMonitor Draft Submission does… both h264 Draft templates do not work with Shotgun Draft Submitter.
And the dialog boxes a bit different… the one from Deadline Monitor has a Submit to Shotgun checkbox at the lower middle part of the dialog box… while Shotgun Draft submission box has the “Sumbitt to Shotgun” checkbox is in the bottom. Is it possible that there are two different Draft executed by Deadline Monitor and Shotgun while Shotgun’s version is older?
Deadline Monitor’s Draft on a left, Shotgun on a right side:

Thanks for the thorough report. I’m not too sure why it wouldn’t be pulling in the relevant information from Shotgun. It definitely should be, I’ll have to look into it and try to replicate this over here.

I’ll keep you posted.

Cheers,

  • Jon

So I managed to reproduce this locally, and was able to fix it. The problem was indeed that the sticky settings were overriding the info pulled in from Shotgun.

I’ve attached an updated script that fixes the issue. Simply extract it to ‘scripts/Submission/DraftSubmission/DraftSubmission.py’ in your Deadline repository.

As for Draft templates not being ‘supported’ through Shotgun, I imagine you’re getting an error similar to the following one:

That just means that the particular Draft template you chose is expecting one or more parameters that weren’t provided (as would be the case in the sample h264 one, I believe). Since the Deadline Job ID could be available in Shotgun, I’ve made an update to our code to pass along the Deadline Job ID from Shotgun if it’s there (and mapped). This will be included in the next Deadline update.

If, however, that’s not the error you’re seeing, could you please upload a log that contains the error in question?

Cheers,

Thanks Jon for the help! It works like a charm now! I appreciate it!