FranZ 4 Posted May 25, 2016 Report Share Posted May 25, 2016 I have an action that can take a while to run. When I launch my action, if the amount of work is short, I see the green message in the web UI. But, if the amount of work takes a while (over 5 seconds, for example), I see the red message "Could not launch action." in the web UI. My action still runs correctly with no errors. It seems very much like the action "times out" and decides that it "Could not launch action". Is there any way to set the time out to be longer? Link to post Share on other sites
tokejepsen 55 Posted May 25, 2016 Report Share Posted May 25, 2016 I just recetly had a conversation with support about this, and short answer is that there aren't any way of extending the time out. Longer answer is that you can use ftrack jobs to let your users know about when action is completed. You'll need to publish a reply before any of the heavy lifting in your action; https://bitbucket.org/tokejepsen/ftrack-hooks/src/8c822233a35dd0be71194b4ada9064fbf8839eb4/delivery.py?fileviewer=file-view-default#delivery.py-58 Link to post Share on other sites
Mattias Lagergren 145 Posted May 26, 2016 Report Share Posted May 26, 2016 We recommend that heavy work is done asynchronously and as tokejepsen mentioned, communicate the progress with a job. One reason for the timeout being so short is that while your action script is working any discover events will be queued up. We have some examples of actions that does it asynchronously: https://bitbucket.org/snippets/ftrack/nKoB - see the async decorator Link to post Share on other sites
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now