fix(cli-e2e): stabilise liveness-sweep "untouched" test on slow CI#30
Merged
Merged
Conversation
The test was using a 1-second heartbeat threshold while two sequential CLI invocations (`session beat` then `session start-instance`) each take ~700-800ms on hosted macOS/Ubuntu runners. The cumulative latency between bumping the heartbeat and the sweep reading it routinely crossed 1s, so the row was wrongly reclassified to `orphaned` before the assertion ran. Bump the threshold for this test to 5s and stretch the pre-beat wait to 6s so the original heartbeat is still unambiguously stale (the test still proves "beat revives a stale row"), but the beat → sweep window has 4+ seconds of headroom — well beyond CI CLI overhead. The orphan-path test in the same suite keeps its 1s threshold because it benefits from timing slop rather than fighting it. Verified locally: 3/3 runs pass at ~7.1s each. Co-Authored-By: claude-flow <ruv@ruv.net>
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.
Summary
ocr session liveness sweep > leaves a row whose heartbeat was just bumped untouchedwas flaking on hosted macOS and Ubuntu runners after v1.11.0 landedsession beatand the nextsession start-instance(which triggers the sweep) — the row got reclassified toorphanedbefore the assertion ranTest plan
🤖 Generated with claude-flow