Skip to content

native: SSH quit-while-starting test flakes under heavy load #172

Closed

Description

@rynfar

ssh::tests::quitting_stops_ssh_still_starting_the_server (apps/native/crates/client/src/ssh/tests.rs) failed once during intake #134 with launch.pid was never recorded: the fake ssh script did not record its PID within the bounded 200 x 25 ms poll in Fixture::recorded_pid (tests.rs:86-96). The machine's load average was 23-25 at the time (several native worktrees building). The test passed 3/3 in isolation (0.5-0.7 s) and the full t3-core/t3-client run passed 1,155/1,155 right after. Batch 8 also saw one SSH test flake once.

The poll is wall-clock bounded, so it races process start-up under load. Replace it with an event the test can await (for example the fake writing to a FIFO or the manager reporting the spawned PID), per the repo's no-wall-clock test rules, so the gate cannot go red on load alone.

Activity

  1. added this to the M2 Parity core milestone on Nov 3, 2026
  2. added
    native:bug
    on Nov 3, 2026
  3. rynfar commented on Nov 3, 2026

    @rynfar
    OwnerAuthor

    Second occurrence: the #139 worker's full workspace run for PR #173 (head 53da355429) failed this SSH fixture once, and it passed in isolation and in the final full run. Both sightings were under heavy parallel build load (several worker builds plus a gate). Treat it as a timing dependency in the fixture, not a retry candidate.

  4. added
    status:in-progress
    status:review
    and removed
    status:in-progress
    status:review
    on Nov 3, 2026
  5. rynfar commented on Nov 3, 2026

    @rynfar
    OwnerAuthor

    Fixed in #181 (squash a0a68b0f52), test-only. The SSH fixture's wall-clock PID polls are replaced by startup and EOF events that race their owning operation, so an early failure reports instead of hanging. Scratch directories clean up on failure. Under load: 200/200 suites (baseline 85/200), then 50/50 after the review changes. Production behaviour and the CN-SSH ledger row are unchanged.

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

    native:bug

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions