Skip to content

Show leaked objects and create logs in TestMaxBrokenPartRatio* teardown - #1575

Merged
Slach merged 2 commits into
masterfrom
max-broken-part-ratio-leak-diag
Sep 23, 2026
Merged

Slach merged 2 commits into
masterfrom
max-broken-part-ratio-leak-diag

Conversation

@Slach

@Slach Slach commented Sep 22, 2026

Copy link
Copy Markdown
Collaborator

Diagnostics only, no product code changes.

Why

The object_disk leak of <prefix>_abort_default that 1c49714 moved into the teardown of TestMaxBrokenPartRatio* keeps failing on CI: Test (1.27, 24.8) in run 35420558789 and Test (1.27, 23.8) in run 35420933277 (both PR #1572, which does not touch create). It does not reproduce locally, 0 of 5 runs on 23.8.

The failure only shows the leaked backup directory name. The output of the aborted create is captured by the test but never logged, because its assertions pass. So there is nothing in the CI log to tell whether RemoveBackupLocal ran cleanBackupObjectDisks, how many keys it deleted, or which objects ended up copied after it.

What

  • TestMaxBrokenPartRatio*: keep the output of both aborted creates (MAX_BROKEN_PART_RATIO=0 and 0.1) and print them when the teardown checkObjectStorageIsEmpty is the first failure of the test.
  • checkRemoteNoFiles: add a recursive listing (ls -AR) of the non-empty path to the error message, so the leaked disk and object keys are visible for every test using the check.

Verification

  • go vet -tags=integration ./test/integration/: OK
  • CLICKHOUSE_VERSION=23.8 RUN_TESTS='^TestMaxBrokenPartRatioS3$' ./test/integration/run.sh: PASS
  • With a temporarily planted leak_probe/disk_s3/aaa/obj1 under the object_disk path on minio (reverted before commit), the teardown printed the recursive listing and the full logs of both aborted creates.

🤖 Generated with Claude Code

Slach and others added 2 commits September 22, 2026 21:03
The object_disk leak of <prefix>_abort_default that 1c49714 moved into
this test's teardown keeps failing on CI (24.8 in run 35420558789, 23.8
in run 35420933277) and does not reproduce locally (0 of 5 on 23.8). The
failure only names the leaked backup directory, and the output of the
aborted create is captured but never logged because its assertions pass,
so there is nothing to tell whether RemoveBackupLocal ran
cleanBackupObjectDisks, how many keys it deleted, or which objects were
copied after it.

Keep the output of both aborted creates and print it when the teardown
emptiness check is the first failure of the test. In checkRemoteNoFiles
add a recursive listing of the non-empty path to the error, so the
leaked disk and object keys are visible for every test using it.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@coveralls

Copy link
Copy Markdown

Coverage Report for CI Build 35885250506

Warning

Build has drifted: This PR's base is out of sync with its target branch, so coverage data may include unrelated changes.
Quick fix: rebase this PR. Learn more →

Coverage at 67.719% (no base build to compare)

Details

  • Coverage remained the same as the base build.
  • Patch coverage: No coverable lines changed in this PR.
  • No coverage regressions found.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

No coverage regressions found.


Coverage Stats

Coverage Status
Relevant Lines: 27437
Covered Lines: 18580
Line Coverage: 67.72%
Coverage Strength: 35533.18 hits per line

💛 - Coveralls

@Slach
Slach merged commit 1f2803a into master Sep 23, 2026
30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants