Michael Qiu

03/15/2023, 6:58 PM
Hey all, I'm noticing some interesting behavior in the
function here, where the Dagster step that executes the DBT build command succeeds even though the DBT build command may fail ([…]/python_modules/libraries/dagster-dbt/dagster_dbt/ Just a disclaimer that we have our own version of
in our codebase, but it is almost identical to the one here. We ended up having to add an except block in the try/finally + some additional handling here just so we know when to fail the step ([…]/python_modules/libraries/dagster-dbt/dagster_dbt/ I just wanted to verify that this is expected behavior, where the step would succeed despite the DBT build operation failing and throwing an exception. Thanks!


03/17/2023, 3:22 PM
hi @Michael Qiu! this is not expected behavior, at least in the default case. there is an "ignore_handled_error" configuration option on the dbt_cli_resource which should toggle this behavior on or off, but it should be set to
by default. This is where the return code of the dbt subprocess is handled:[…]c/python_modules/libraries/dagster-dbt/dagster_dbt/cli/ What version of dbt are you on? Specifically is it <1.4 or >=1.4?

Michael Qiu

03/17/2023, 5:16 PM
We are pre 1.4 right now, but will be upgrading soon. We have a workaround for this for now, but we will test the behavior of this once we upgrade. Thanks for the help!