Repository navigation
Fix flaky test_kafka_formats_with_broken_message integration test - #100286
Merged
Merged
Conversation
The test was failing with `JSONDecodeError` because it queried the `kafka_errors_*_mv` materialized view without waiting for the error row to be flushed. The data rows could already be present while the error row was still pending. Use `query_with_retry` to wait for the error row to appear before parsing the JSON result. https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=100115&sha=bc88afbf7346646c37befae5ead1fe4c906f33e1&name_0=PR&name_1=Integration%20tests%20%28amd_asan_ubsan%2C%20db%20disk%2C%20old%20analyzer%2C%201%2F6%29 Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
Contributor
|
Workflow [PR], commit [da2c394] Summary: ✅ AI ReviewSummaryThis PR stabilizes ClickHouse Rules
Final Verdict
|
alexey-milovidov
left a comment
Member
Author
There was a problem hiding this comment.
That's reasonable.
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.
Fix flaky
test_kafka_formats_with_broken_messageby waiting for the error row to appear in the materialized view before querying it.The test waited for data rows via
query_with_retry, but then queriedkafka_errors_*_mvdirectly without retry. If the error row hadn't been flushed yet, the query returned an empty string, causingjson.loads("")to throwJSONDecodeError.https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=100115&sha=bc88afbf7346646c37befae5ead1fe4c906f33e1&name_0=PR&name_1=Integration%20tests%20%28amd_asan_ubsan%2C%20db%20disk%2C%20old%20analyzer%2C%201%2F6%29
#100115
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
...
Documentation entry for user-facing changes
Version info
26.4.1.94