Forum Discussion
DBT Job test warnings causing job failure
The dbt job exit code is not logged when run through a DBT Job as far as I can tell. Running this locally does not return any error codes.
Hi mwferris,
Thanks for confirming that the same project completes locally without errors.
That makes me more confident that the warning is being handled correctly by dbt, but interpreted as a failure by the Fabric dbt Job wrapper.
According to dbt’s test severity behaviour, a test configured with severity: warn should remain a warning unless warnings are explicitly promoted to errors. Your command does not include --warn-error, and the final result shows:
PASS=2 WARN=1 ERROR=0Since Fabric does not expose the process exit code in the job output, I would now focus on the complete job logs and Fabric’s final status evaluation.
Microsoft documents that the full dbt execution logs are available through OneLake dbt Job logging, including details that may be missing or truncated in the normal run view.
I would check the final section of dbt.log and run_results.json for:
- Whether dbt reports successful completion
- Any exception after the dbt command finishes
- The final invocation status
- A Fabric-specific error added after the dbt result is produced
If those logs still show a successful dbt completion with warnings only, I think this is strong evidence of a Fabric dbt Job status-handling issue rather than a problem with your test configuration.
At that point, I would include the full OneLake logs, job ID, Fabric region and dbt adapter/version in a support case or product issue.
Please keep us posted if the complete logs reveal anything after the dbt summary. This looks like a useful edge case for the dbt Job team to investigate.
AI-assisted drafting: AI was used to help structure and phrase this response. I reviewed and validated the technical content before posting.