-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
exp run: track files for skipped/run-cached stages #9889
Conversation
8d9fd4c
to
bcd0b68
Compare
ret = _reproduce_stage(stage, **kwargs) | ||
if not kwargs.get("dry") and (paths := _get_stage_files(stage)): | ||
logger.debug("Staging stage-related files: %s", paths) | ||
stage.repo.scm_context.add(paths) | ||
return ret |
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.
stage.reproduce()
returns None for skipped (unchanged run-cached) stages, and when the entire pipeline is skipped dvc.reproduce()
ends up returning an empty list. In exp run
we still need to force git-tracking the dvc.yaml
and dvc.lock
for those skipped stages.
Codecov ReportPatch coverage is
π’ Thoughts on this report? Let us know!. |
@pmrowla, what do you think of changing the return type of |
I thought about having it return the tuple of |
I think it should be something like following now, after @dataclass
class Result:
reproduced: List["Stage"] = field(default_factory=list)
unchanged: List["Stage"] = field(default_factory=list)
failed: List["Stage"] = field(default_factory=list)
skipped: List["Stage"] = field(default_factory=list) I think we are long due for changing return type of But I guess adjusting tests will be painful, so I'm happy with this too for now. But we'll have to change the return type at some point. |
I am also okay with introducing a |
Btw, what should be the behaviour here if |
I agree changing the return type would be cleaner but no strong opinion or need to block the P.R. |
If it fails, we don't make a commit and everything gets |
bcd0b68
to
829504b
Compare
I think we're all in agreement that the return type for Going to go ahead and merge this as-is for now |
β I have followed the Contributing to DVC checklist.
π If this PR requires documentation updates, I have created a separate PR (or issue, at least) in dvc.org and linked it here.
Thank you for the contribution - we'll try to review it as soon as possible. π
Fixes #9781