dagster._check.CheckError: Invariant failed. Descr...
# ask-ai
s
dagster._check.CheckError: Invariant failed. Description: All leaf nodes within graph 'electrothermal_model_validation_sim_set' must generate outputs which are mapped to outputs of the graph, and produce assets. The following leaf node(s) are non-asset producing ops: {'run_validation_sim'}. This behavior is not currently supported because these ops are not required for the creation of the associated asset(s).
s
The error message you're encountering indicates that within your graph
electrothermal_model_validation_sim_set
, there is a leaf node named
run_validation_sim
that does not produce an asset. In Dagster, when using graph-backed assets, all leaf nodes in the graph should produce assets. If a leaf node does not produce an asset, it can lead to confusion and is not supported behavior. The documentation states that the only leaf nodes of a graph-backed asset should be ops that produce assets. If non-asset-producing ops are detected as leaf nodes, Dagster should error early to prevent confusing behavior. This is consistent with an issue reported on Dagster's GitHub repository, which suggests that Dagster should error when non-asset-producing ops are leaf nodes in a graph-backed asset. To resolve this issue, you should ensure that all leaf nodes in your graph are associated with asset production. If the
run_validation_sim
op is intended to produce an asset, you should modify it to do so. If it's not meant to produce an asset, you may need to reconsider its placement in the graph or its role within the asset computation. If you need further assistance with this issue, please provide additional context or code snippets, and I'll do my best to help you troubleshoot the problem.