Skip to content

Fix flaky hop-return cap test under the address sanitizer - #353

Merged
alexkroman merged 1 commit into
mainfrom
claude/zealous-wozniak-7h56f1
Nov 24, 2026
Merged

alexkroman merged 1 commit into
mainfrom
claude/zealous-wozniak-7h56f1

Conversation

@alexkroman

Copy link
Copy Markdown
Collaborator

What & why

DictationCoordinatorReturnTests.returnsAtCap ("with a keeper expected but silent, the return comes at the cap") advanced the TestClock immediately after the window opened. The cap is a Task that sleeps on that clock, so on a slow run (the address sanitizer) the advance could land before the task reached clock.sleep. The sleeper then registered with its deadline still ahead of virtual time, nothing ever woke it, and until gave up after 3 s.

The test now awaits clock.waitUntilSleeping(for: .seconds(BlurtShared.hopReturnCap)) before advancing, the same pattern the heartbeat tests use. Test-only change; no app code touched.

Seen failing ios-sanitizers (address) on #327, a Mac-only change unrelated to this test.

How it was tested

Written on Linux, so not built or run locally; CI's ios-sanitizers jobs on macOS are the verification.

  • scripts/check.sh passes (or CI will, if I'm not on a Mac)
  • I read AGENTS.md and this doesn't reintroduce anything
    deliberately removed
  • Docs updated if behavior changed (no behavior change)

Generated by Claude Code

`returnsAtCap` advanced the TestClock straight after the window opened. The
cap is a Task, so under a slow run (the address sanitizer) the advance could
land before the task reached `clock.sleep`; its deadline then stayed ahead of
virtual time and nothing ever woke it, failing `until` after 3 s. Wait on
`waitUntilSleeping(for:)` first, as the heartbeat tests do.

Seen failing ios-sanitizers (address) on #327, a Mac-only change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DS5B1WW4Gb71hVeS3gvFB4
@alexkroman
alexkroman added this pull request to the merge queue Nov 24, 2026
Merged via the queue into main with commit ba954e0 Nov 24, 2026
13 checks passed
@alexkroman
alexkroman deleted the claude/zealous-wozniak-7h56f1 branch November 24, 2026 21:31
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