Repository navigation
Flake batch 13: bash_watch restart tests retry the post-replay scan - #1074
Merged
Merged
Conversation
Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com> (cherry picked from commit 1f6722d6ab12bd99aedc676044659fc4357c5e52)
Co-authored-by: alfonso-aft <289616620+alfonso-aft@users.noreply.github.com>
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.
Two tests added by #911 (
each_line_once_warning_stays_armed_through_ack_and_restartand the acknowledged/unacknowledged replay test) failed in merge-queue groups (Linux and macOS) withOption::unwrap()on an empty frame list: after a simulated restart, a single scan of new output emitted no match.scan_task_watch_output's early returns never persist a cursor, so a scan that returns without emitting leaves the bytes for production's watchdog to rescan on its next pass. The tests scanned exactly once. They now retry the scan for up to 10 s and, if no match ever arrives, fail with the watch count, running state and cursors, so a real miss still fails and names its state.Verified: both tests 15x each under concurrent bash_background load on Linux (30/30), and the bash_background lib tests (838 passed). A 6 s pause before the final scan also passed, which rules out task exit at scan time.
Summary by cubic
Fixes two flaky
bash_watchrestart tests that failed intermittently in merge-queue groups withOption::unwrap()on an empty frame list.After a simulated restart, a single scan could return without emitting a match because early returns never persist a cursor, so the watchdog rescans the same bytes on its next pass. The tests now retry the post-replay scan for up to 10 s and, on timeout, fail with the watch count, running state, and cursors — a real miss still fails and names its state. Also adds a test-only benchmark slice descriptor.
Written for commit 13cf4c9. Summary will update on new commits.