Repository navigation
Make match_max effective in 04615_client_progress_table_toggle_config - #112160
Merged
Merged
Conversation
…fig` `match_max 100000` without `-d` applies to the *current* spawn id, and there is none at the point where the test sets it, so all three clients spawned later ran with expect's 2000-byte default buffer instead. That is smaller than a single rendering of the live progress table, while this test streams tens of kilobytes of continuously redrawn table through the pty, so expect kept discarding the oldest part of its buffer during matching. The test failed by timeout on a loaded `amd_debug, distributed plan, s3 storage` runner (9 failures in 12036 runs over the last week, none on `master` head), e.g. https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=100173&sha=0b83f4eaa78570a1cb035da08702534fe3c4bfe7&name_0=PR&name_1=Stateless%20tests%20%28amd_debug%2C%20distributed%20plan%2C%20s3%20storage%2C%20parallel%29 (#100173), where the debug log shows expect matching against a buffer whose beginning had been cut mid-token. Use `match_max -d 100000` so the value the test already asks for is inherited by every `spawn`. Verified locally: `[match_max]` after a `spawn` reports 2000 without `-d` and 100000 with it, and the test still passes. Note that all 53 `.expect` tests under `tests/queries/0_stateless` set `match_max 100000` the same ineffective way; this commit only changes the one test that is failing, since a larger buffer also makes expect retain older output, which could affect negative `expect` patterns in the other tests.
Contributor
|
Workflow [PR], commit [58598eb] Summary: ✅ AI ReviewSummaryThis PR fixes Final Verdict
|
pull Bot
pushed a commit
to Haofei/ClickHouse
that referenced
this pull request
Sep 6, 2026
`match_max 100000` on line 23 runs before the `spawn` on line 41, and without `-d` it applies to the *current* spawn id, of which there is none at that point, so the client ran with expect's 2000-byte default buffer, i.e. 6001 chars of capacity. The bare `\l` expands to `SHOW DATABASES`. On a shared `arm_binary, parallel` runner that listed 69 databases with every row padded to 219 chars, because a concurrent test held a ~200-char database name: a 15,754-char burst, 2.6x the window. The test failed by timeout there, on https://s3.amazonaws.com/clickhouse-test-reports/praktika.html?PR=117423&sha=8f6c4316969230ee19799531b03487484cacf0b6&name_0=PR&name_1=Stateless%20tests%20%28arm_binary%2C%20parallel%29 (ClickHouse#117423), where the `.expect.debuglog` shows expect forgetting output four times while matching the prompt on line 94, ending with the buffer pinned at 6001 and a final read of 13 chars. Use `match_max -d 100000` so the value the test already asks for is inherited by the `spawn`. Verified locally: `[match_max]` after a `spawn` reports 2000 without `-d` and 100000 with it. With 75 databases and one 206-char name making the listing 17,679 chars, the debuglogs of 50 runs hold 304 full-buffer discards without this change and 0 with it, and the widest buffer expect examines rises from the 6001-char ceiling to the whole listing; reverting only the `-d` brings the discards back. 50/50 runs pass with and without that fixture. The 60 s timeout itself is rate-dependent and did not reproduce locally, so what is shown here is that the assertion ran inside a discard regime the test's declared buffer would never have entered. Of the 62 `.expect` tests under `tests/queries/0_stateless`, the other 60 set `match_max` the same ineffective way; as in ClickHouse#112160 this commit only changes the test that is failing, since a larger buffer also makes expect retain older output, which could affect negative `expect` patterns in the other tests. Co-Authored-By: Claude Opus 5 <[email protected]>
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):
Make
match_maxactually take effect in04615_client_progress_table_toggle_config.match_max 100000without-dapplies to the current spawn id, and there is none at the point where the test sets it, so all three clients spawned later ran with expect's 2000-byte default buffer instead. That is smaller than a single rendering of the live progress table, while this test streams tens of kilobytes of continuously redrawn table through the pty, so expect kept discarding the oldest part of its buffer while matching.The test fails by timeout on loaded runners (9 failures in 12036 runs over the last week, none on
masterhead), for example: https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=100173&sha=0b83f4eaa78570a1cb035da08702534fe3c4bfe7&name_0=PR&name_1=Stateless%20tests%20%28amd_debug%2C%20distributed%20plan%2C%20s3%20storage%2C%20parallel%29 — the expect debug log there shows matching against a buffer whose beginning had been cut mid-token.Verified locally:
[match_max]right after aspawnreports2000without-dand100000with it, and the test still passes (3/3 runs).Note that all 53
.expecttests undertests/queries/0_statelesssetmatch_max 100000the same ineffective way. This change touches only the test that is currently failing, because a larger buffer also makes expect retain older output, which could change how negativeexpectpatterns behave in the other tests — that sweep is better done deliberately.Related: #100173
Version info
26.8.1.303(included in26.8and later)