Wooey icon indicating copy to clipboard operation
Wooey copied to clipboard

Script versioning/job cloning on new versions

Open hottwaj opened this issue 8 years ago • 1 comments

Hey guys, our Wooey deployment is likely to see occasional refinement of scripts with new features added/bugs fixed (we hope!).

A problem that comes up at the moment when a new version of a script is added is that a job that was used on an old version of a script can't be cloned (via the UI) for use on a newer version of the script. Also if I change the "script" FK of an old job so that it points to the newer script, Wooey does not then seem to be able to populate the fields of the newer script when I try to run a "clone" operation.

This prevents users easily repeating old jobs on newer versions of the same script... Certainly something that we'll probably want to do a lot! Thanks

hottwaj avatar Sep 03 '15 15:09 hottwaj

This is something I am working on as well. There are a ton of changes going into script versioning right now on #45 -- I need to write some migration code and that should be finished up.

After that, I can check if a new parameter needs to be made as well and streamline that process (because if the creation of it is identical, it should behave identical). I'm considering the new model to be if there if a change, clone the old scriptparameters and update any discrepancies (so things like customs widgets/etc. would propagate).

This isn't something I am planning for the 0.9.0 milestone -- we want to try and get that on PyPi ASAP, but it's definitely a feature for the release following it.

There is actually quite a bit behind the scenes here. The job parameters are actually stored in the 'ScriptParameters' model (not to be confused with the singular ScriptParameter). Here, these need to be updated as well for the past jobs. This is because old jobs are meant to be representative of a state in time and the results should be reproducible of that moment in time. A better option, imo, would be to have the Clone Job default to the latest version, with a drop-down to say 'clone with version used' or something to that extent.

Chris7 avatar Sep 03 '15 15:09 Chris7