How to If/Else Assets #28786
Unanswered
jackherwigenersponse
asked this question in
Q&A
Replies: 1 comment 1 reply
-
It sounds like you may be better off using Op Graph for this use case as it can do conditional branching. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am in python
I have four assets. one pulls event days from a DB. It can either return n events, or zero events (The asset writes the found event dates back to the DB if it finds them) I am also using an asset to pull other data that is relevant to the events (and sometimes covers event dates) but does not always. The other two assets do two different kinds of calculations on that non event data. How do I tell Dagster that I want one calculation to run if there was an event found, and another to run if there was not an event found? My definitions object is in a separate definitions.py, and the assets are in an assets.py. The reason I would like to keep the two calculation assets separate is due to the way the business logic is, and it will likely be easier to maintain that way.
I am open though to changing up how I am doing things if it's necessary. I am somewhat new to Dagster.
Beta Was this translation helpful? Give feedback.
All reactions