Repository navigation
Add test: Lightweight UPDATE/DELETE materialization of _block_number/_block_offset on an upgraded table (MutateSomePartColumns path) is untested - #112379
Conversation
|
Pre-PR Validation Gate (per ClickGap pipeline): a) Deterministic repro? ✅ b) Root cause explained? ✅ c) Fix matches root cause? ✅ d) Test intent preserved? / New tests added? ✅ e) Both directions demonstrated? ✅ f) Fix is general, not a narrow patch? ✅ |
|
Workflow [PR], commit [ad28098] Summary: ✅ AI ReviewSummaryThis PR adds a focused stateless regression test for the upgraded-table mutation path that materializes Final Verdict✅ No new findings. |
Requested by @clickhouse-gh[bot] in ClickHouse#112379 (comment)
Found via ClickGap automated review. Please close or comment if this is incorrect or needs adjustment.
This is a test-only PR — no source code changes. Please review: test quality, whether the claimed coverage gaps are real, and whether test output makes sense.
Adds test coverage for 1 untested code path(s), found during automated review of PR #109281.
That PR The PR fixes materialization of
_block_number/_block_offsetcolumns and their part-level min-max index across merges and mutations. (1)MergeTask::ExecuteAndFinalizeHorizontalPart::preparenow passesWITH_BLOCK_NUMBER_OFFSETtogetMinMaxColumnsonly when both block columns are enabled (`1. Lightweight
UPDATE/DELETEmaterialization of_block_number/_block_offseton an upgraded table (MutateSomePartColumnspath) is untestedsrc/Storages/MergeTree/MutateTask.cpp:753,src/Storages/MergeTree/MutateTask.cpp:630Risk:
splitAndModifyMutationCommands(MutateTask.cpp:630-640) appendsREAD_COLUMNcommands for the block columns when!for_interpreter.empty()and the part lacks them, andgetColumnsForNewDataPart(MutateTask.cpp:753-754) keeps them whenupdated_header.has(name). The PR's own tests only reach these branches throughREWRITE PARTS, which forces theMutateAllPartColumnsTaskpath; a plainUPDATE/DELETEof a non-key column on a wide part takes theelsebranch at MutateTask.cpp:3667 …What's unique vs PR tests: The PR's 04501 reaches block-column materialization only through
REWRITE PARTS, which forcesMutateAllPartColumnsTask, and asserts existence only. Existing block-column mutation tests (02668, 03001, 03275) enable the settings AT CREATE, so the part always already has the columns and the new!part_columns.has(...)materialization branch never fires. This test is the only one that upgrades an existing table (MODIFY SETTING) and then runs a lightweightUPDATE(non-key column, wide part …Tags:
-- Tags: no-random-settings, no-random-merge-tree-settings, no-shared-merge-tree—no-random-settings: test pins mutation version in generated part names (all_1_1_0_3); randomized settings can add extra mutations and shift versions;no-random-merge-tree-settings: test explicitly sets enable_block_number_column/enable_block_offset_column/min_bytes_for_wide_part; randomization would override them;no-shared-merge-tree: part naming and materialization differ under shared-merge-tree, breaking the parts_columns assertionChangelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Not applicable — test-only change.
Documentation entry for user-facing changes
Version info
26.8.1.365(included in26.8and later)