Skip to content

fix: coerce decimal literals in target subset filters#4267

Merged
ion-elgreco merged 1 commit intodelta-io:mainfrom
ethan-tyler:fix/merge-decimal-coercion
Mar 10, 2026
Merged

fix: coerce decimal literals in target subset filters#4267
ion-elgreco merged 1 commit intodelta-io:mainfrom
ethan-tyler:fix/merge-decimal-coercion

Conversation

@ethan-tyler
Copy link
Copy Markdown
Collaborator

Description

Found this while working on #4266.

Merge target subset filters can retain decimal precision/scale from the source expression instead of the target schema. For example decimal(4, 1) when the column is decimal(6, 1). The newer file skipping path rejects the mismatch.

This fix is normalize target_subset_filter against the target schema before simplification, and extend literal coercion to handle between bounds.

Related Issue(s)

Documentation

Signed-off-by: Ethan Urbanski <ethan@urbanskitech.com>
@github-actions github-actions Bot added binding/python Issues for the Python package binding/rust Issues for the Rust crate labels Mar 10, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented Mar 10, 2026

Codecov Report

❌ Patch coverage is 85.50725% with 10 lines in your changes missing coverage. Please review.
✅ Project coverage is 76.85%. Comparing base (ca0f37e) to head (5e589b5).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
crates/core/src/delta_datafusion/utils.rs 86.66% 3 Missing and 3 partials ⚠️
crates/core/src/operations/merge/mod.rs 83.33% 2 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4267      +/-   ##
==========================================
- Coverage   76.85%   76.85%   -0.01%     
==========================================
  Files         167      167              
  Lines       49098    49139      +41     
  Branches    49098    49139      +41     
==========================================
+ Hits        37735    37766      +31     
- Misses       9453     9459       +6     
- Partials     1910     1914       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ion-elgreco ion-elgreco merged commit 675936a into delta-io:main Mar 10, 2026
30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

binding/python Issues for the Python package binding/rust Issues for the Rust crate

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants