-
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
fill_from_lock
called when stage.cmd_chaged == True
#3918
Comments
Hi, @tall-josh, thanks a lot for a great bug report/repro. Looks like Lines 81 to 86 in 0bb49d2
A quick-fix (untested) might be something like: diff --git a/dvc/stage/run.py b/dvc/stage/run.py
index 53bab38d..59086365 100644
--- a/dvc/stage/run.py
+++ b/dvc/stage/run.py
@@ -82,6 +82,7 @@ def _is_cached(stage):
cached = (
not stage.is_callback
and not stage.always_changed
+ and not stage.changed_stage()
and stage.already_cached()
)
if cached: Would you like to give it a try? 🙂 |
The reason why it uses |
Hi @skshetry. I tried commenting out |
@skshetry Looks like it worked :-) I have been playing with adding templating for a I've chucked it on a fork if you're interested I'll link this on the #3633 thread |
Previously, the stage would not rerun if the deps/outs are cached even if the cmd has changed. Versions affected: >0.93.0 Fixes iterative#3918
Previously, the stage would not rerun if the deps/outs are cached even if the cmd has changed. Versions affected: >0.93.0 Fixes #3918
Loving how responsive you guys are. Amazing! Definitely owe y'all 🍻 |
Bug Report
Using mutlistage dvc file.
dvc repro
for the fist time ondvc.yaml
works no issue. However, if I change thecmd
indvc.yaml
the new command is not run, instead dvc saysStage 'st2' is cached
(interestingly it omitsskipping
). After doing some digging I noticed thishttps://github.com/iterative/dvc/blob/master/dvc/stage/loader.py#L178
Is using the
lock_data
correct? If thecmd
has changed, shouldn't we use thestage_data
?Please provide information about your setup
dvc.yaml
$ dvc repro dvc.yaml
Correctly runs both stages
Modify
cmd
indvc.yaml
ie: setst2.cmd
to$ dvc repro dvc.yaml
Expected Output
Does not pickup change in
st2.cmd
Additional Information (if any):
If applicable, please also provide a
--verbose
output of the command, eg:dvc add --verbose
.The text was updated successfully, but these errors were encountered: