Randomize new settings in 25.12: skip index for topK#91782
Merged
alexey-milovidov merged 7 commits intomasterfrom Mar 19, 2026
Merged
Randomize new settings in 25.12: skip index for topK#91782alexey-milovidov merged 7 commits intomasterfrom
alexey-milovidov merged 7 commits intomasterfrom
Conversation
Contributor
|
Workflow [PR], commit [e7857ea] Summary: ✅ AI ReviewSummaryThis PR randomizes Missing context
Findings
ClickHouse Rules
Final Verdict
|
alexey-milovidov
added a commit
that referenced
this pull request
Mar 16, 2026
Tests that check EXPLAIN output or row counts for ORDER BY ... LIMIT queries need deterministic topK optimization behavior. Pin `use_skip_indexes_for_top_k` and `use_top_k_dynamic_filtering` to 0 in tests that don't test topK, and pin `query_plan_max_limit_for_top_k_optimization` to a high value in tests that rely on topK being active. #91782 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 task
Tests that verify specific query plans, pipeline structures, or row counts break when `use_skip_indexes_for_top_k`, `use_top_k_dynamic_filtering`, and `query_plan_max_limit_for_top_k_optimization` are randomized. Pin `use_skip_indexes_for_top_k = 0` and `use_top_k_dynamic_filtering = 0` in tests that depend on deterministic read_in_order behavior, EXPLAIN output, or lazy materialization. Pin `query_plan_max_limit_for_top_k_optimization = 1000` in the topK-specific test to ensure LIMIT 10 always qualifies for the optimization. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
87a9277 to
07f74f6
Compare
`03711_top_k_by_skip_index_negative`: pin `query_plan_max_limit_for_top_k_optimization` so that LIMIT 5 always qualifies for the optimization. `03924_sorting_step_stats`: disable `use_skip_indexes_for_top_k` and `use_top_k_dynamic_filtering` to prevent extra steps in EXPLAIN output. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Member
|
I think it broke the tests. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Randomize settings in clickhouse-test: use_skip_indexes_for_top_k, use_top_k_dynamic_filtering, query_plan_max_limit_for_top_k_optimization
Documentation entry for user-facing changes