-
Notifications
You must be signed in to change notification settings - Fork 1.9k
[dg] Update dg plus deploy refresh-defs-state command to handle subprocesses
#32851
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
base: 11-17-_dg_add_support_for_gitlab_in_configure_workflow
Are you sure you want to change the base?
Conversation
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
1d6ede1 to
3f77f9e
Compare
3f77f9e to
b20ddf9
Compare
|
Deploy preview for dagster-docs ready! Preview available at https://dagster-docs-a76ev410z-elementl.vercel.app Direct link to changed pages: |
b20ddf9 to
707a52c
Compare
4d5a804 to
cee07c4
Compare
cee07c4 to
fbe63d1
Compare
707a52c to
6edd4e4
Compare
6edd4e4 to
0938685
Compare
smackesey
left a comment
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 vaguely uncomfortable with the "serialized instance as a comms channel for this specific information" hack but it seems like we can always change it later if we come up with a "cleaner" way to handle this stuff under the hood that doesn't involve a full gRPC server.
If it gets the job done!
0938685 to
5251ffe
Compare
5251ffe to
e0fa419
Compare
bf76707 to
5e04f13
Compare

Summary & Motivation
This makes it so
dg plus deploy refresh-defs-statecan handle workspaces in addition to projects. previously we assumed we were executing in the same python environment as the main dg command, but this isn't always the case. Now, we create an InstanceRef that has access to our prod DefsStateStorage. We can then serialize this reference and pass it to the subprocess, which then invokesdg utils refresh-defs-statein the project's python env. This results in the instance in the main process being mutated, which we can then read from at the end to get the updated defs state info.How I Tested These Changes
Changelog