Skip to content

Fix flaky test_filesystem_split_cache boundary condition#96508

Merged
alexey-milovidov merged 1 commit intomasterfrom
fix-split-cache-test-boundary
Feb 10, 2026
Merged

Fix flaky test_filesystem_split_cache boundary condition#96508
alexey-milovidov merged 1 commit intomasterfrom
fix-split-cache-test-boundary

Conversation

@alexey-milovidov
Copy link
Copy Markdown
Member

@alexey-milovidov alexey-milovidov commented Feb 10, 2026

Summary

  • Fixed test_split_cache_restart failing with assert 0.5 < 0.5 — cache went from 18 to 9 entries after restart, hitting the strict boundary of the tolerance check
  • After OPTIMIZE TABLE merges parts, old parts' cache entries get cleaned up on restart, causing exactly 50% of entries to disappear
  • Changed < 0.5 to <= 0.5 in both tolerance assertions to accept the boundary case

Test plan

  • The fix addresses the exact failure: assert 0.5 < 0.5

https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=96480&sha=eb28c4c0578c9e986eaca6dab5b2e7293bd0ae9e&name_0=PR&name_1=Integration%20tests%20%28amd_asan%2C%20db%20disk%2C%20old%20analyzer%2C%206%2F6%29
#96480

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):

...

🤖 Generated with Claude Code

The `test_split_cache_restart` test failed with `assert 0.5 < 0.5` because
cache went from 18 to 9 entries after restart (exactly 50% change). This
happens when `OPTIMIZE TABLE` merges parts and the old parts' cache entries
get cleaned up on restart.

Changed `< 0.5` to `<= 0.5` in both tolerance checks to include the boundary.

https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=96480&sha=eb28c4c0578c9e986eaca6dab5b2e7293bd0ae9e&name_0=PR&name_1=Integration%20tests%20%28amd_asan%2C%20db%20disk%2C%20old%20analyzer%2C%206%2F6%29

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@clickhouse-gh
Copy link
Copy Markdown
Contributor

clickhouse-gh Bot commented Feb 10, 2026

Workflow [PR], commit [39a176d]

Summary:

@clickhouse-gh clickhouse-gh Bot added the pr-ci label Feb 10, 2026
@kssenii kssenii self-assigned this Feb 10, 2026
@alexey-milovidov alexey-milovidov merged commit 64fefea into master Feb 10, 2026
133 of 134 checks passed
@alexey-milovidov alexey-milovidov deleted the fix-split-cache-test-boundary branch February 10, 2026 15:31
@robot-ch-test-poll3 robot-ch-test-poll3 added the pr-synced-to-cloud The PR is synced to the cloud repo label Feb 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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.

3 participants