fix(table): treat lone UPDATE_BEFORE as retraction in partial-update #1434
All Vouch review confidence checks passed
Residual risk 0.17 = Change Risk (0.43) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.43 · 387 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.357
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #1434"
general
weight: 0.35
JeonDaehong
Purpose
Linked issue: close #1430
With
partial-update.remove-record-on-delete, a key whose last message is a lone UPDATE_BEFORE (-U) now reads no row, as in Java with apache/paimon PR 11178. Before this change the Rust merge ignored -U under this option.The rules follow the Java
PartialUpdateMergeFunctionof that PR:partial-update.remove-record-on-sequence-groupand sequence groups keep their current behavior.The gap has been reproduced against apache/paimon PR 11178: on a fixed-bucket Parquet table with this option, a committed
+I(1, 10, 20)followed by a lone-U(1, 10, NULL)reads no row in Java and(1, 10, 20)through the PyPaimon Native reader on pypaimon-rust 0.5.0.Brief change log
PartialUpdateMergeFunctionapplies the -U rules above and reports UPDATE_BEFORE or DELETE throughMergeResult::MaterializedRetractRow, which now carries the row kind.kv_file_writerstores that row kind instead of always DELETE, so merging a pre-merged -U again does not re-initialize the row and drop older columns. Reads still drop both kinds.Tests
last_non_null_value, compaction of +I and -U in one or two commits succeeds under thenoneandlookupproducers, the row stays removed, and a later +U restores the other writer's column. It fails without the compaction fix and when the merge result is DELETE again. Without a field aggregator the same cases pass, and a DELETE result instead drops the other writer's column when +I and -U are pre-merged in one commit.API and Format
No public API or file format change.
Documentation
docs/src/compaction.mddocuments this rule.AI Disclosure
Human-led contribution. Grok Bot, working for dragonknightk, assisted with this change, including the code, tests, and description. All submitted content was reviewed by a human before submission.
(๑•̀ㅂ•́)و✧