Uploaded image for project: 'Data Management'
  1. Data Management
  2. DM-26621

Improve ScriptQueue handling of scripts that fail before running.

    XMLWordPrintable

    Details

    • Type: Story
    • Status: Done
    • Resolution: Done
    • Fix Version/s: None
    • Component/s: None
    • Labels:

      Description

      Currently when a script fails to configure or some other failure while loading (before running), the scrip queue provides little feedback on what happened to it. The script simply disappears from the queue going from the salIndices to nowhere. 

      I think it would be better if those scripts also land in the pastSalIndices with some information on which stage it failed (loading? configuring?). 

        Attachments

          Activity

          Hide
          rowen Russell Owen added a comment -

          The current feedback is that the ScriptInfo script event outputs processState=config failed.

          I am willing to put such scripts on the history as that will clearly make it easier to see what went wrong. I will try to also prevent requeueing such scripts, since they will definitely fail again (unless the script is edited before requeueing, which seems too much of a stretch).

          Show
          rowen Russell Owen added a comment - The current feedback is that the ScriptInfo script event outputs processState=config failed. I am willing to put such scripts on the history as that will clearly make it easier to see what went wrong. I will try to also prevent requeueing such scripts, since they will definitely fail again (unless the script is edited before requeueing, which seems too much of a stretch).
          Hide
          rowen Russell Owen added a comment - - edited

          The new code moves all scripts to the history, whether they fail or are stopped. Note that when stopping a collection of scripts the order in which they appear in the history is not deterministic. I added support to test_script_queue.py and test_queue_model.py to handle this: if past_sal_indices is a set then order is ignored.

          I decided not to try to block requeue of scripts that failed reconfiguration as I think it makes the system overly complicated. We can add that later if necessary.

          I also overhauled the documentation to improve it and use the modern layout.

          Pull request: https://github.com/lsst-ts/ts_scriptqueue/pull/54
          built docs: https://ts-scriptqueue.lsst.io/v/PR-54/index.html

          Show
          rowen Russell Owen added a comment - - edited The new code moves all scripts to the history, whether they fail or are stopped. Note that when stopping a collection of scripts the order in which they appear in the history is not deterministic. I added support to test_script_queue.py and test_queue_model.py to handle this: if past_sal_indices is a set then order is ignored. I decided not to try to block requeue of scripts that failed reconfiguration as I think it makes the system overly complicated. We can add that later if necessary. I also overhauled the documentation to improve it and use the modern layout. Pull request: https://github.com/lsst-ts/ts_scriptqueue/pull/54 built docs: https://ts-scriptqueue.lsst.io/v/PR-54/index.html
          Hide
          tribeiro Tiago Ribeiro added a comment -

          Reviewed in GitHub and tested it locally. Looks good. 

          Show
          tribeiro Tiago Ribeiro added a comment - Reviewed in GitHub and tested it locally. Looks good. 
          Hide
          rowen Russell Owen added a comment -

          Released as v2.7.0

          Show
          rowen Russell Owen added a comment - Released as v2.7.0

            People

            Assignee:
            rowen Russell Owen
            Reporter:
            tribeiro Tiago Ribeiro
            Reviewers:
            Tiago Ribeiro
            Watchers:
            Andy Clements, Michael Reuter, Patrick Ingraham, Russell Owen, Tiago Ribeiro
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Jenkins

                No builds found.