cylc-flow icon indicating copy to clipboard operation
cylc-flow copied to clipboard

clean: only attempt to clean platforms which have been installed to

Open oliver-sanders opened this issue 2 years ago • 3 comments

Addresses the "broken platform" side of #4935.

  • Store the remote init map in the workflow database.
  • This table is not in itself housekept because the database as a whole is housekept by cylc clean.
  • Add a new remote-init status for platforms which have no hosts available (therefor do not need cleaning as we haven't managed to install anything onto them in the first place).

TODO:

  • [ ] Don't update the status of an install_target if the new status would not require clean and the old would (e.g. can happen on restart if no hosts are available but the remote-init completed for the previous start)
  • [ ] Requires (extremely simple) DB upgrader (i.e. add blank table on restart).
  • [ ] Add test.

Requirements check-list

  • [ ] I have read CONTRIBUTING.md and added my name as a Code Contributor.
  • [ ] Contains logically grouped changes (else tidy your branch by rebase).
  • [ ] Does not contain off-topic changes (use other PRs for other changes).
  • [ ] Applied any dependency changes to both setup.cfg and conda-environment.yml.
  • [ ] Appropriate tests are included (unit and/or functional).
  • [ ] Already covered by existing tests.
  • [ ] Does not need tests (why?).
  • [ ] Appropriate change log entry included.
  • [ ] No change log entry required (why? e.g. invisible to users).
  • [ ] (master branch) I have opened a documentation PR at cylc/cylc-doc/pull/XXXX.
  • [ ] (7.8.x branch) I have updated the documentation in this PR branch.
  • [ ] No documentation update required.

oliver-sanders avatar Jun 30 '22 09:06 oliver-sanders

@hjoliver Does this approach make sense to you?

oliver-sanders avatar Jun 30 '22 09:06 oliver-sanders

Bumping to 8.x as I think this only really impacts us developers dealing with test battery workflows?

For real platforms users will just wait until the platform becomes available again and retry the clean command.

oliver-sanders avatar Jun 30 '22 13:06 oliver-sanders

Yes, it seems an eminently sensible approach!

hjoliver avatar Jul 01 '22 02:07 hjoliver

May come back to this one day, but not today...

oliver-sanders avatar Aug 01 '23 15:08 oliver-sanders