Skip to content

Fixes 37196: Map dbt warning results to Failed - #37198

Merged
TeddyCr merged 1 commit into
open-metadata:mainfrom
TeddyCr:fix/dbt-warn-as-failed
Nov 5, 2026
Merged

TeddyCr merged 1 commit into
open-metadata:mainfrom
TeddyCr:fix/dbt-warn-as-failed

Conversation

@TeddyCr

@TeddyCr TeddyCr commented Nov 5, 2026

Copy link
Copy Markdown
Collaborator

Describe your changes:

Fixes #37196

Ingest dbt warn results as Failed instead of Aborted for data tests and source freshness. Keep the result value 0 and preserve dbt messages/freshness details. Runtime errors remain Aborted.

This is the interim mapping requested in #37196; it does not implement or close the dedicated Warning-status proposals #26538 and #35431. Newly ingested warnings count as failures and can trigger failure alerts. Historical results are not bulk-rewritten.

Type of change:

  • Bug fix

High-level design:

Use the existing shared status mapper by adding warn to its failure enum. Record the temporary mapping and alerting consequences in docs/decisions/2026-11-05-dbt-warnings-map-to-failed.md.

Tests:

Use cases covered

  • Data-test warnings with a message map to Failed, retain the message, and emit value 0.
  • Warnings with no message are still ingested as Failed.
  • Freshness warnings map to Failed and retain age/threshold details.
  • Existing pass, fail/error, compiled-only, and runtime-error paths remain covered.

Unit tests

  • Updated ingestion/tests/unit/test_dbt.py; all three new status assertions failed before the change.
  • make unit_ingestion ARGS='-n 0 tests/unit/test_dbt.py tests/unit/test_dbt_test_definition.py tests/unit/test_dbt_test_descriptions.py tests/unit/entity_resolution/test_resolver.py': 373 passed.
  • Coverage: constants module 100%; all executable status-mapper lines covered. Whole dbt/metadata.py: 76.4% line coverage (broader pre-existing connector code).
  • make py_format_check: passed; 3,175 files formatted.
  • make static-checks: passed, 0 errors (130 existing warnings).
  • Pinned uv lock --check --project ingestion: passed.
  • Decision-record validation and commit hooks: passed.

Backend integration tests

Not applicable — no Java/API/schema changes.

Ingestion integration tests

No existing integration tests import the changed modules. The changed behavior is pure artifact-to-result conversion exercised through the result builders and API-boundary captures in the unit suite. No live-server warning scenario was run.

Playwright (UI) tests

Not applicable — no UI changes.

Manual testing performed

No UI/manual test. Automated regression tests verify emitted result status, value, and diagnostic details.

UI screen recording:

Not applicable — ingestion-only bug fix.

Checklist:

  • PR title and linked issue match.
  • Added regression coverage for the changed behavior.
  • No schema migration required.
  • Decision recorded in the tree.
  • Final committed diff independently reviewed against REVIEW.md: 3872389cb9a3f639554e6e2123e298065afbbc86; no actionable findings.

@TeddyCr
TeddyCr requested a review from a team as a code owner November 5, 2026 18:27
@TeddyCr
TeddyCr requested review from stout-yeoman and a balanced review from Copilot November 5, 2026 18:27

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

✅ PR checks passed

The linked issue has a description and all required Shipping project fields set. Thanks!

@github-actions github-actions Bot added Ingestion safe to test Add this label to run secure Github workflows on PRs labels Nov 5, 2026
@gitar-bot

gitar-bot Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Code Review ✅ Approved

🟡 Medium risk · Mapping dbt warnings to Failed makes new warning results count as failures and could trigger unintended failure alerts or misstate test health.

Maps dbt warn results for data tests and source freshness to Failed instead of Aborted, keeping the result value at 0 and preserving dbt messages and freshness details. No issues found.

Verification

Rules No rules evaluated

Functional validation Not enabled

Set up

Auto-approval Not enabled

Set up

For more verification details, comment gitar display:verbose.

Options

Display: compact → Showing compact verification results.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source

@sonarqubecloud

sonarqubecloud Bot commented Nov 5, 2026

Copy link
Copy Markdown

@TeddyCr
TeddyCr disabled auto-merge November 5, 2026 19:32
@TeddyCr
TeddyCr merged commit 45f6d2f into open-metadata:main Nov 5, 2026
61 of 62 checks passed
TeddyCr added a commit that referenced this pull request Nov 5, 2026
…Fai (#37199)

taskr run 0177.
PR #37198 is staged on the 2.0 worktree, uncommitted: it applied cleanly, matches the upstream diff line for line, and the planned tests, import check and ruff checks all pass (237/237 in test_dbt.py).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Ingestion safe to test Add this label to run secure Github workflows on PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Map dbt warning results to Failed until a dedicated warning status is supported

3 participants