fix: handle plain ibis backends in join backend rebinding#222
Conversation
Claude Code ReviewVerdict: Approve — the fix is correct, minimal, and well-tested. ops.py —
|
_rebind_join_backends uses xorq's walk_nodes to traverse expression trees, which fails with ValueError on plain ibis Table objects (e.g. Snowflake, Databricks). Gracefully skip rebinding when walk_nodes cannot handle the expression — rebinding is only needed for xorq-vendored backends. Closes #221 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…backends The previous YAML integration test didn't actually reproduce the bug because DuckDB gets xorq-wrapped. This direct unit test calls _rebind_join_backends with plain ibis tables, hitting the exact ValueError code path from GH-221. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Mixed xorq-left + plain-ibis-right scenario - xorq-wrapped happy path (no regression) - Chained multi-table joins on plain ibis backends Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
73d094e to
1694983
Compare
|
Facing the same issue for Athena. |
# Conflicts: # src/boring_semantic_layer/ops.py # src/boring_semantic_layer/tests/test_plain_ibis.py
Replace bare `except Exception` with the specific exceptions actually raised: `ImportError` for the xorq shim import, `(ValueError, TypeError)` for walk_nodes encountering plain ibis tables. This avoids masking unrelated bugs while preserving the fallback behavior for unsupported backends (Snowflake, Databricks, BigQuery). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Patch bump covering join fixes on plain ibis backends (boringdata#222), grain mismatch on `with_measures` over joins (boringdata#261), the ibis-native calc-measure classifier refactor (boringdata#262), and the HashingTag serialization fix (boringdata#264). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Summary
ValueError: Don't know how to handle type <class 'ibis.expr.types.relations.Table'>when using joins on plain ibis backends (Snowflake, Databricks, etc.)_rebind_join_backendsnow gracefully skips xorq-specific node traversal when the expression tree contains plain ibis tablesCloses #221