Skip to content

flake: stale-running startup reconciliation test times out #1837

Closed

Description

@jbeda

Summary

TestBuildSettlesStaleRunningSnapshotAcrossRestart intermittently fails because the test's five-second wait expires before the real startup reconciliation goroutine changes its seeded stale session from running.

Evidence

The failure reproduced on both the mention-palette implementation branch and a detached current origin/main worktree:

--- FAIL: TestBuildSettlesStaleRunningSnapshotAcrossRestart
    stale_running_session_e2e_test.go:138: timed out after 5s waiting for Build's real startup sweep goroutine to settle "subagent-crash-orphan-475" (still "running")

A five-run focused invocation failed twice on each revision:

go test ./internal/app -run '^TestBuildSettlesStaleRunningSnapshotAcrossRestart$' -count=5

Expected behavior

The test should deterministically observe the startup sweep settling the seeded stale-running session, or use a deterministic synchronization seam that proves the same production behavior without timing sensitivity.

Scope

This was discovered while validating PR #1833. It is unrelated to the mecatui mention-palette change.

Activity

  1. added
    flake
    on Sep 24, 2026
  2. jbeda commented on Sep 24, 2026

    @jbeda
    ContributorAuthor

    Reopened: task test during typed-scrollback renderer validation still fails in TestBuildSettlesStaleRunningSnapshotAcrossRestart; a focused rerun also reproduces the five-second startup-reconciliation timeout. The failure is unrelated to the renderer change.

  3. reopened this on Sep 24, 2026
  4. jbeda commented on Sep 30, 2026

    @jbeda
    ContributorAuthor

    Already fixed by #1838: the original build now closes before stale fixture seeding. Verified on current origin/main with 20 focused runs and 5 race runs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    flake

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions