Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add cmd-line flag to disable metadata + UUID generation and commits #447

Merged

Conversation

jo-basevi
Copy link
Collaborator

Add cmd line flag --metadata-off/-M (better names?) to payu subcommands to disable metadata files or UUIDs being created. This uses control directory for experiment names. (so equivalent to metadata: enable: false in config.yaml)

Added this flag to sub-commands that create an Experiment class instance - so archive, collate, profile, run, setup, sweep and sync.

Closes #446

@pep8speaks
Copy link

pep8speaks commented Jun 24, 2024

Hello @jo-basevi! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

Line 289:2: W292 no newline at end of file

Comment last updated at 2024-08-22 04:01:06 UTC

aidanheerdegen
aidanheerdegen previously approved these changes Aug 20, 2024
Copy link
Collaborator

@aidanheerdegen aidanheerdegen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow that touched a lot! I appreciate the time it took to make all those changes.

Looks good to me. I have a question about the best way to propagate the argument through to subsequent commands, but trust your judgement and am happy to leave as-is, just wanted to point it out.

@jo-basevi jo-basevi force-pushed the 446-add-cmd-line-arg-to-disable-metadata branch from f89bff0 to c2d10c3 Compare August 22, 2024 04:00
@coveralls
Copy link

Coverage Status

coverage: 56.434% (+0.2%) from 56.234%
when pulling c2d10c3 on ACCESS-NRI:446-add-cmd-line-arg-to-disable-metadata
into fcd414b on payu-org:master.

@jo-basevi
Copy link
Collaborator Author

As the intention was to add a command-line argument to make it easier to update manifests for released configurations, running payu setup (and maybe payu sweep) would be the only commands required to have --metadata-off. If wishing to disable metadata for payu run/sync/collate jobs using the metadata: enable: false in config.yaml would be the best option. So that simplifies this PR quite a bit!

@jo-basevi jo-basevi marked this pull request as ready for review August 22, 2024 04:04
Copy link
Collaborator

@aidanheerdegen aidanheerdegen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks, and sorry for the extra work that wasn't required.

@jo-basevi jo-basevi merged commit cf01e0f into payu-org:master Aug 22, 2024
9 checks passed
@jo-basevi jo-basevi deleted the 446-add-cmd-line-arg-to-disable-metadata branch August 22, 2024 04:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Command line argument to disable metadata/UUID generation
4 participants