https://dagster.io/ logo
Title
n

Nickolas Zourmpakis

04/11/2023, 5:24 PM
Hey team. I have a question. I am trying to find a way to stop a graph from running depending on the outcome of an ops. I made the output of the ops "Out(is_required=False)" and depending on the code I yield the output or I don't. And I pass the result of the op to the graph (basically the same way between ops). My problem is that it keeps complaining that I have an unmapped input. I don't want to use the input anywhere. Is there anyway of doing this? Thank you in advance!!
c

claire

04/11/2023, 6:47 PM
Hi Nickolas. Dagster attempts to compile each graph into a flat map of ops. This means that when an op is passed as an input to a graph (even if it is optional) the input must be passed to at least one op within the graph. So I think you'll just need to pass the result of the op into one of the graph's ops, and then your code will work correctly.
n

Nickolas Zourmpakis

04/12/2023, 7:23 AM
Thank you Claire. I was afraid that this was the only way to do it, but I was hoping for something I missed. Again, thank you!! 🙏
:rainbow-daggy: 1