diff --git a/cylc/flow/scripts/validate_install_play.py b/cylc/flow/scripts/validate_install_play.py index 9343289f987..d701eb02315 100644 --- a/cylc/flow/scripts/validate_install_play.py +++ b/cylc/flow/scripts/validate_install_play.py @@ -86,7 +86,7 @@ def get_option_parser() -> COP: # no sense in a VIP context. if option.kwargs.get('dest') != 'against_source': parser.add_option(*option.args, **option.kwargs) - + parser.set_defaults(is_validate=True) return parser @@ -103,6 +103,9 @@ def main(parser: COP, options: 'Values', workflow_id: Optional[str] = None): log_subcommand('validate', source) asyncio.run(cylc_validate(parser, options, str(source))) + # Unset is validate after validation. + delattr(options, 'is_validate') + log_subcommand('install', source) _, workflow_id = asyncio.run(cylc_install(options, workflow_id)) diff --git a/cylc/flow/scripts/validate_reinstall.py b/cylc/flow/scripts/validate_reinstall.py index 0733512ddad..de1be6dea82 100644 --- a/cylc/flow/scripts/validate_reinstall.py +++ b/cylc/flow/scripts/validate_reinstall.py @@ -97,6 +97,7 @@ def get_option_parser() -> COP: ) for option in VR_OPTIONS: parser.add_option(*option.args, **option.kwargs) + parser.set_defaults(is_validate=True) return parser @@ -169,6 +170,9 @@ async def vr_cli(parser: COP, options: 'Values', workflow_id: str): log_subcommand('validate --against-source', workflow_id) await cylc_validate(parser, options, workflow_id) + # Unset is validate after validation. + delattr(options, 'is_validate') + log_subcommand('reinstall', workflow_id) reinstall_ok = await cylc_reinstall( options, workflow_id,