-
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
repro: make stages run in order of the graph #9675
Conversation
In case of --single-item, this means it'll run in the order of arguments passed. For --downstream, this fixes running of stage out of order when multiple arguments are passed. For normal case, this enforces the same logic, so that they are never run out-of-order.
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #9675 +/- ##
==========================================
- Coverage 90.63% 90.57% -0.06%
==========================================
Files 472 480 +8
Lines 36280 36334 +54
Branches 5218 5219 +1
==========================================
+ Hits 32882 32911 +29
- Misses 2812 2839 +27
+ Partials 586 584 -2
☔ View full report in Codecov by Sentry. |
Let's check and update the docs for this please. I think we had one or more descriptions of the execution order. Plus we need to check the option descriptions. |
Nothing should change from the user’s perspective here, at least from what’s documented. This is mostly a bugfix. |
Asair we mention that we don't guarantee the order of execution, i might be wrong though. |
This PR closes #9367, and makes a few other changes:
--single-item
now runs in the order the target is provided, instead of the position in it's dag. So, if you providedvc repro stage1 stage2 --single-item
,stage1
will run beforestage2
even ifstage2
comes beforestage1
. Because that's what you want most of the time.(And I did not want to complicate the code too much.)
--downstream
stages will run in the order of the graph instead of running stages of each target with post-order traversal.The order is also enforced in normal cases, not just in
--downstream
by traversing the graph in post order. Previously, we were removing duplicates manually.dvc/dvc/repo/reproduce.py
Lines 222 to 228 in 36ec25f