Skip to content

Fix missing model name in console error output for driver failures) - #6066

Open
sakshipatil-hue wants to merge 1 commit into
SQLMesh:mainfrom
sakshipatil-hue:patch-2
Open

sakshipatil-hue wants to merge 1 commit into
SQLMesh:mainfrom
sakshipatil-hue:patch-2

Conversation

@sakshipatil-hue

Copy link
Copy Markdown
Contributor

Description

Fixes an issue where low-level driver or engine errors (such as casting exceptions) fail to display the failing model or snapshot name in the console error output.

Updated _format_node_error in sqlmesh/core/console.py to add robust fallback checks. If error.node lacks standard snapshot_name or SnapshotId attributes, it now checks for a .name attribute or safely falls back to stringifying the node (str(error.node)), ensuring the failing model name is always surfaced in logs.

Test Plan

Manually verified that when a node execution fails due to low-level engine or driver errors where error.node lacks standard snapshot attributes, the console correctly falls back to .name or str(error.node) and successfully outputs the failing model name instead of leaving it blank.

Checklist

  • I have run make style and fixed any issues
  • I have added tests for my changes (if applicable)
  • All existing tests pass (make fast-test)
  • My commits are signed off (git commit -s) per the DCO

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant