Submission GUI Python error

I’m trying to add a Combo Control GUI object to my Submission script, but I need to include only one option in it, not an array of options, since I currently only have one version of the plugin I’m writing the submission for. But for future extensions, I’d like to have the GUI base set.

So, when I add the GUI control this way:

scriptDialog.AddComboControl( "VersionBox", "ComboControl", "4.0", ("4.0"), 50, -1 )

I’m getting a Python error when trying to run the submission script in the Deadline Monitor.

[code]Could not run script because an error occurred:

Python Error: expected Array[str], got str (Microsoft.Scripting.ArgumentTypeException)
(System.Exception)[/code]

However, this works perfectly fine:

scriptDialog.AddComboControl( "VersionBox", "ComboControl", "4.0", ("4.0", "5.0"), 50, -1 )

Is this a bug?

It’s not a bug, it’s just that to the interpreter, (“4.0”) looks like a string in parenthesis, not a string array. Sticking a comma in there will help, like this:

scriptDialog.AddComboControl( "VersionBox", "ComboControl", "4.0", ("4.0",), 50, -1 )

Cheers,

  • Ryan

Ah! Yes, that helped! Thank you, once again! :wink: