-
Notifications
You must be signed in to change notification settings - Fork 734
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
introduce --dry-run run
mode
#1881
base: master
Are you sure you want to change the base?
Conversation
--dry-run run
mode
@@ -901,6 +899,12 @@ def version(obj): | |||
type=click.Choice(MONITOR_SIDECARS), | |||
help="Monitoring backend type", | |||
) | |||
@click.option( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not a fan of having options cause other options to be ignored with no warning. I would add a check to see if there are conflicting options. dry-run
is also a bit misleading (it's not dry run and things may happen, for example conda package caching, anything the code does as well, etc).
) | ||
if all_decospecs: | ||
decorators._attach_decorators(ctx.obj.flow, all_decospecs) | ||
decospecs = list(decospecs or []) + list(ctx.obj.environment.decospecs() or []) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit, use ctx.obj.decospecs (no point redoing the same computation and conversion)
# words, for the same decorator, we want `myflow.py run --with foo` to | ||
# take precedence over any other `foo` decospec | ||
ctx.obj.tl_decospecs = list(decospecs or []) | ||
# run/resume can add more decorators with --with, which take precedence |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
am fine with this (and associated change) but would re-add the comment about how precedence is determined by order right now (first one wins) so we need to save to apply in before_run. (ie: this comment is correct but doesn't say why we do it this way).
the rationale for this PR is to make it easier for folks to run tests through Metaflow without reporting anything on the progress to the UI or storing any artifacts.
also includes cosmetic changes for decorator handling in cli.py which can be safely ignored (or omitted or pulled out in a separate PR)