Chris Anderson
12/07/2022, 8:00 PMobservations
but get an error of dagster._core.errors.DagsterInvalidInvocationError: Compute function of op 'observations' has context argument, but no context was provided when invoking.
(both versions of this error, if i don't provide the context from the multi-asset to the op it's line 169, if I do it's line 177 of dagster\_core\definitions\solid_definition.py
) Other assets and ops I have turned into assets in a graph handle context injection on their own so I do know that it should be handled behind the scenes.owen
12/07/2022, 11:20 PMAssetsDefinition.from_op(...)
. However, dynamic ops also won't really work with this, instead I'd recommend placing the dynamic op inside of a graph and then calling AssetsDefinition.from_graph
. The return value of the graph also shouldn't be dynamic -- basically all the dynamic outputs need to be `collect`ed before they can be turned into an asset.Chris Anderson
12/07/2022, 11:24 PMmulti-asset
s and asset
decorators and into a graph
with AssetsDefinition.from_graph
and it works perfectly fine, op calling context and all. So if anyone else runs into this issue here's the solution for now 😛