-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
retry function in dbt-core #7020
Conversation
Thank you for your pull request! We could not find a changelog entry for this change. For details on how to document a change, see the contributing guide. |
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.
very cool proof of concept :)
this command should probably not parse any project file, it should just read the manifest in that state
Yes, we need to do this to enable "manifest-only" execution! Related to many of the conversations we've been having. Where/how should we persist runtime config? In the manifest? As contents of raw dbt_project.yml
file, or resolved Project
object?
ctx.obj["manifest"], | ||
) | ||
|
||
from dbt import selected_resources |
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.
We need to de-globalize this (ik yk): #6009
task.compile_manifest() | ||
selected_resources.set_selected_resources(set(unique_ids)) | ||
new_graph = task.graph.get_subset_graph(set(unique_ids)) | ||
# should we give a way here for consumers to mutate the graph? |
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.
Maybe? Mutate the graph in the sense of:
- pass a
graph
into the task (I think this might be possible if we did [CT-1891] Abstract graph generation from task classes #6708) — a cached graph for now, but maybe someday a custom/modifiedgraph
- define custom selectors / selection methods (a very cool & compelling idea!)
if result.status not in [RunStatus.Success, TestStatus.Pass] | ||
] | ||
# Using build task since it has a more complete runner set now | ||
task = BuildTask( |
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 I right in thinking - we'd need a way to dynamically load the appropriate task, based on previous_state.results.args.which
?
Closing for now, in favor of the new issue: |
This code is garbage, just to demo some ideas RN
implement a retry command that can run your project from an existing state
TODO
Previous run
running retry