bug? "Use Frame Timeout" not saved

Hi !

If I open a task properties and check “Use Frame Timeout” and click OK, it seems the option is not saved. I reopen properties and it’s not checked.

Hi,
Thanks for the feedback. Sadly, it looks like the UI is currently broken here. I also noticed that the above checkbox “Enable Timeouts For Pre/Post Job Scripts” is also broken once it’s checked (it can’t be unchecked). These issues have now been logged. Here’s a quick script fix to provide the same functionality. Drop the code below into a file and call it something like: “Timeouts.py” and copy the file into <your_repo>/custom/scripts/jobs. Now open monitor, right-click on one or more jobs, scripts -> Timeouts, use the UI to check or uncheck the settings and click “apply”. I’ll attach the py file as well for you.

[code]from System.IO import *
from Deadline.Scripting import *

from DeadlineUI.Controls.Scripting.DeadlineScriptDialog import DeadlineScriptDialog

scriptDialog = None

def main():
global scriptDialog

scriptDialog = DeadlineScriptDialog()
scriptDialog.AllowResizingDialog( False )
scriptDialog.SetTitle( "Timeouts" )

scriptDialog.AddGrid()
scriptDialog.AddSelectionControlToGrid( "EnableTimeoutsJobScriptsBox", "CheckBoxControl", False, "Enable Timeouts For Pre/Post Job Scripts", 0, 0 , "If checked, then the timeouts for this job will also affect its pre/post job scripts, if any are defined.")
scriptDialog.AddSelectionControlToGrid( "UseFrameTimeoutsBox", "CheckBoxControl", False, "Use Frame Timeouts", 1, 0 , "If enabled, timeouts will be calculated based on frames instead of by tasks. The timeouts entered for tasks will be used for each frame in that task.")

applyButton = scriptDialog.AddControlToGrid( "ApplyButton", "ButtonControl", "Apply", 1, 2, expand=False )
applyButton.ValueModified.connect(ApplyButtonPressed)

closeButton = scriptDialog.AddControlToGrid( "CloseButton", "ButtonControl", "Close", 2, 2, expand=False )
closeButton.ValueModified.connect(CloseButtonPressed)

scriptDialog.EndGrid()

scriptDialog.ShowDialog( False )

def ApplyButtonPressed( *args ):
global scriptDialog

jobs = MonitorUtils.GetSelectedJobs()

for job in jobs:
    job.JobEnableTimeoutsForScriptTasks = scriptDialog.GetValue( "EnableTimeoutsJobScriptsBox" )
    job.JobEnableFrameTimeouts = scriptDialog.GetValue( "UseFrameTimeoutsBox" )
    RepositoryUtils.SaveJob(job)

def CloseButtonPressed( *args ):
global scriptDialog
scriptDialog.CloseDialog()[/code]

Timeouts.py.zip (792 Bytes)

Hey Gabriel,

I just wanted to see if you saw Mike’s answer on this as you did indeed report this and it’s being worked on.

yeah thanks ! i didn’t subscribed to the thread. now i see it :stuck_out_tongue: