-
Notifications
You must be signed in to change notification settings - Fork 1.7k
[dagster-airlift] Move around classes #29154
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
Conversation
@property | ||
def finished(self) -> bool: | ||
from dagster_airlift.core.airflow_instance import TERMINAL_STATES | ||
return self.state in TERMINAL_STATES |
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.
There's a circular import issue here: airflow_instance.py
imports from runtime_representations.py
and now runtime_representations.py
imports from airflow_instance.py
.
To resolve this, consider either:
- Moving
TERMINAL_STATES
to a common module that both can import - Defining
TERMINAL_STATES
inruntime_representations.py
and importing it inairflow_instance.py
instead - Passing
TERMINAL_STATES
as a parameter when creatingDagRun
instances
This will maintain clean dependency structure and prevent potential import-time issues.
@property | |
def finished(self) -> bool: | |
from dagster_airlift.core.airflow_instance import TERMINAL_STATES | |
return self.state in TERMINAL_STATES | |
@property | |
def finished(self) -> bool: | |
from dagster_airlift.core.constants import TERMINAL_STATES | |
return self.state in TERMINAL_STATES |
Spotted by Diamond
Is this helpful? React 👍 or 👎 to let us know.
6454c96
to
b6e1161
Compare
d9dd539
to
6c9d753
Compare
b6e1161
to
89bae05
Compare
1bb7131
to
297627f
Compare
c2a259c
to
d6b9022
Compare
297627f
to
8b11fcc
Compare
d6b9022
to
afa68dc
Compare
8b11fcc
to
736b731
Compare
afa68dc
to
e7ac036
Compare
…ce retrieval methods (#29155) ## Summary & Motivation Adds storage classes + retrieval methods to the AirflowInstance for airflow datasets. Based on the Airflow rest API which can be found here: https://airflow.apache.org/docs/apache-airflow/stable/stable-rest-api-ref.html ## How I Tested These Changes New kitchen sink test
Deploy preview for dagit-core-storybook ready! ✅ Preview Built with commit 9cdfa18. |
Summary & Motivation
This file was getting too big and is about to get bigger. Move around non-serialized airflow representations to a different file.
How I Tested These Changes
Existing tests