Skip to content

Disable 04669_window_partitions_independently under MSan - #117833

Merged
alexey-milovidov merged 1 commit into
ClickHouse:masterfrom
groeneai:no-msan-04669-window-partitions-independently
Sep 3, 2026
Merged

alexey-milovidov merged 1 commit into
ClickHouse:masterfrom
groeneai:no-msan-04669-window-partitions-independently

Conversation

@groeneai

@groeneai groeneai commented Sep 3, 2026 •

Copy link
Copy Markdown
Collaborator

Related: #100371
Related: #115050

Changelog category (leave one):

  • CI Fix or Improvement (changelog entry is not required)

Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):

Tag 04669_window_partitions_independently with no-msan: it exceeds the per-test timeout under Memory Sanitizer when metadata is in Keeper and data is on S3.

Description

In the private sync run of #100371 this test was killed at [ FAIL ] 600.16 sec. Reason: Timeout! on Stateless tests (amd_msan, distributed cache, meta in keeper, s3 storage, parallel, 2/3) (job: https://github.com/ClickHouse/clickhouse-private/actions/runs/33556271270/job/100030241449). It has never timed out on public CI: 2044 executed runs on master since it merged, 0 failures. The public form of that shard peaks at 119 s of the 600 s budget (n=131) and the heaviest public shard of any kind at 152 s (n=1328), both MSan.

The test is statement-heavy and data-trivial: 16 scenarios, 16 CREATE TABLE, 30 INSERT, 32 EXPLAIN, largest insert numbers_mt(480). Keeper metadata plus S3 data turns each into a network round trip, and MSan multiplies it again. Every assertion is an EXPLAIN line filter or a cityHash64 equality, so it exercises query planning, not memory correctness.

This is the same change #115050 makes to 307 tests, including the sibling 04411_distinct_partitions_independently. 04669 merged on 2026-08-24, after that PR's set was computed; under #115050's own criterion it is 1328 runs at 63.7 s mean, above the 60 s threshold. a0c26d8ca5e65ca69a0b9115669d5ce45a8983ce made the identical change to 04218_limit_by_partitions_independently for the same private-configuration timeout.

no-msan is the smallest tag covering every arm observed failing: no-s3-storage covers them too but costs 3508 executed runs against 1493 over 30 days, and no-distributed-cache would be free yet misses the sibling's failing arm, which has none. ASan+UBSan, TSan, the s3-storage shards and four non-MSan flaky checks keep running the test, stress jobs ignore no-<build> tags, and .reference is byte-identical.

I found no open issue for it. 04669_creating_set_partitions_independently averages 119.9 s under the same criterion and is in neither PR, but it has no master failures, so I left it alone. Happy to fold this into #115050 instead if you would rather keep it in one place; your call.


Workflow [PR]
Sync PR [sync-upstream/pr/117833]

The test (added in ClickHouse#114783) has 16 scenarios that each do INSERT +
EXPLAIN, and the MSan slowdown pushes it past the per-test timeout when
metadata is in Keeper and data is on S3. It was killed at 600.16 s in
the private sync run of ClickHouse#100371.

Adding `no-msan` since the test exercises pipeline planning, not memory
correctness, so MSan adds little signal. This is the same change
`a0c26d8ca5e65ca69a0b9115669d5ce45a8983ce` made to the sibling
`04218_limit_by_partitions_independently`, and the same change ClickHouse#115050
makes to 307 tests including `04411_distinct_partitions_independently`.
This test merged on 2026-08-24, after that pull request's set was
computed, which is why it is absent from it; under ClickHouse#115050's own
published criterion it is 1327 runs at 63.7 s mean, above its 60 s
threshold.

It has never timed out on public CI: 2044 executed runs on master since
it merged, 0 failures, and the heaviest public variant peaks at 124 s of
the 600 s budget. Only MSan is excluded, so ASan+UBSan, TSan and the
s3-storage and Keeper-metadata arms keep running the test, stress-test
jobs ignore `no-<build>` tags, and `.reference` is byte-identical.

I did not also add `no-tsan`, `no-asan` or `no-s3-storage`, which is
what the sibling ended up carrying, because no non-MSan arm is observed
failing.

CI report (private sync run of ClickHouse#100371):
https://github.com/ClickHouse/clickhouse-private/actions/runs/33556271270/job/100030241449

Related: ClickHouse#100371
Related: ClickHouse#115050

Co-Authored-By: Claude Opus 5 <[email protected]>
@groeneai groeneai added can be tested Allows running workflows for external contributors groeneai-origin-request PR origin: a maintainer pinged or directed groeneai labels Sep 3, 2026
@groeneai

groeneai commented Sep 3, 2026

Copy link
Copy Markdown
Collaborator Author
Internal second-model review

Two cold passes over this diff: 6 findings, 5 applied, 1 declined. All five applied findings were in the description rather than the code, so the code is byte-identical to the first pass: three measured numbers were wrong and are corrected (the heaviest public run time, the EXPLAIN count, and which arms keep running the test), and the comparison against the two narrower tags was added.

Declined, noted not blocking: backticking INSERT and EXPLAIN in the new tag-rationale comment. The repository instruction does cover comments, but of the 97 tag-rationale lines in 0_stateless that name a SQL keyword, 92 are unbackticked, 12 of them added by that instruction's author after it landed, and the byte-identical line in 04218_limit_by_partitions_independently (a0c26d8ca5e65ca69a0b9115669d5ce45a8983ce) is one of them. Happy to add the backticks if you would prefer them.

@clickhouse-gh

clickhouse-gh Bot commented Sep 3, 2026 •

Copy link
Copy Markdown
Contributor

Workflow [PR], commit [4361953]

Summary: ✅


AI Review

Summary

This PR adds a no-msan tag to 04669_window_partitions_independently.sql to avoid a private-sync timeout. The diff is small, but it suppresses more sanitizer coverage than the evidence in the PR currently justifies, so I do not think it is ready as written.

Findings

⚠️ Majors

  • [tests/queries/0_stateless/04669_window_partitions_independently.sql:1] The only concrete failure evidence in the description is the private amd_msan, distributed cache, meta in keeper, s3 storage shard, but the code disables the test in every MSan job. The runner already supports no-distributed-cache, so this broad tag drops MSan coverage for the normal planner path even though the same description says public MSan runs stay well under the timeout. Use the narrower no-distributed-cache tag here, or add evidence that non-distributed cache MSan variants are also non-actionable.
Final Verdict

Changes requested: the skip should match the failing CI dimension instead of removing all MSan coverage without stronger evidence.

@clickhouse-gh clickhouse-gh Bot added the pr-ci label Sep 3, 2026
@groeneai

groeneai commented Sep 3, 2026

Copy link
Copy Markdown
Collaborator Author

cc @nihalzp, could you review this? It tags 04669_window_partitions_independently with no-msan: the test is 16 scenarios of DDL plus EXPLAIN and almost no data, so on a private amd_msan, meta in keeper, s3 storage shard every statement becomes a network round trip and it was killed at the 600 s per-test ceiling. It is the same tag the sibling 04218_limit_by_partitions_independently already carries, and public coverage on ASan+UBSan, TSan and the s3-storage shards is unchanged.

@@ -1,4 +1,5 @@
-- Tags: long, no-random-settings, no-random-merge-tree-settings
-- Tags: long, no-msan, no-random-settings, no-random-merge-tree-settings

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The only concrete timeout evidence in the PR is the private amd_msan, distributed cache, meta in keeper, s3 storage shard, but this tag disables the test in every MSan job. tests/clickhouse-test already has a dedicated no-distributed-cache gate, so no-msan drops sanitizer coverage for the normal planner path even though the same description says public MSan runs stay well under the timeout. Can we scope the skip to no-distributed-cache here unless there is data showing non-distributed cache MSan variants are also non-actionable?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no-distributed-cache would not cover this failure mode.

The precedent this change follows is a0c26d8ca5e65ca69a0b9115669d5ce45a8983ce, which added the same tag and a byte-identical rationale line to the sibling 04218_limit_by_partitions_independently for the same pathology. The CI report named in its commit message is Stateless tests (amd_msan, meta in keeper, s3 storage, parallel, 2/2), a configuration with no distributed cache, so no-distributed-cache would have left that arm armed. That gate (tests/clickhouse-test:3042) has existed since 161e794618a86f3 (2024-07-29), about 22 months earlier, so the narrower option was available and was not the one chosen. Master's 04218 now reads long, no-tsan, no-asan, no-msan, no-s3-storage, so this family moved wider rather than narrower.

On the axis: no-distributed-cache is a fair cost lever when the cache is itself the cost driver, as in 04510_distributed_final_many_partitions.sh (84214a772cb9542, "each tiny part commit costs over a second ... through the cache"). Note that file keeps its debug-and-sanitizer cost on a separate tag rather than folding it into no-distributed-cache. Where a test has both problems it carries both tags: 13 of the 48 users of no-distributed-cache also carry a sanitizer tag, for instance 01201_read_single_thread_in_order.sql (long, no-msan, no-distributed-cache). Here the cache is not the driver, since the sibling blew the budget with the cache absent.

You are right that public MSan stays under budget (119 s max on the public form of the named shard, 152 s across all public MSan variants, against 600 s) and that no-distributed-cache would cost 0 executed public runs against 1500 for no-msan over 30 days. That is why I stopped at no-msan rather than the sibling's wider set: both arms observed failing in this family are amd_msan, so it is the smallest tag covering both. The only other tag covering both is no-s3-storage, at 3526 runs.

@PedroTadim

Copy link
Copy Markdown
Member

@groeneai should also disable the test under other slow sanitizers?

@alexey-milovidov
alexey-milovidov added this pull request to the merge queue Sep 3, 2026
@alexey-milovidov alexey-milovidov self-assigned this Sep 3, 2026
@PedroTadim

Copy link
Copy Markdown
Member

@alexey-milovidov should the test be also disabled for other sanitizers such as tsan? That one may be slower than msan?

@alexey-milovidov

Copy link
Copy Markdown
Member

MSan is the slowest and much slower than the others.

@groeneai

groeneai commented Sep 3, 2026

Copy link
Copy Markdown
Collaborator Author

Measured for this test alone, public CIDB over 30 days, true master only (head_ref = 'master', pull_request_number = 0, SKIPPED excluded), as runs / failures / avg / max:

MSan 253 / 0 / 64.8 s / 124.0 s. TSan 520 / 0 / 26.9 s / 79.8 s. ASan+UBSan 534 / 0 / 17.0 s / 51.9 s. debug 537 / 0 / 5.7 s / 34.5 s. binary 269 / 0 / 2.6 s / 15.2 s.

MSan averages 2.4x TSan and 3.8x ASan on this file, so the answer above holds for it specifically.

The only public failures this test has are 33 rows from PR 114783, which added it: all on 2026-08-14, all result differs with reference, zero timeouts. The timeout that prompted this PR is on the private sync run and is amd_msan with distributed cache, metadata in Keeper and data on S3, where the public form of the same shard sits at 119 s of the 600 s budget.

That is why the tag is sized to MSan: no-tsan or no-asan would drop executed coverage on arms that have never failed here. If one of them does start timing out later, widening is one line, which is what happened to the sibling 04218_limit_by_partitions_independently (no-msan first, then no-tsan, no-asan, no-msan, no-s3-storage once more arms were seen failing).

Merged via the queue into ClickHouse:master with commit 9c1ba1d Sep 3, 2026
174 of 344 checks passed
@robot-clickhouse-ci-1 robot-clickhouse-ci-1 added the pr-synced-to-cloud The PR is synced to the cloud repo label Sep 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

can be tested Allows running workflows for external contributors groeneai-origin-request PR origin: a maintainer pinged or directed groeneai pr-ci pr-synced-to-cloud The PR is synced to the cloud repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants