Skip to content

tests/task-workstream-session-worker:804 — flaky non-timing 'TASK_FILE: not in stdout' is the CI failure, distinct from the timing budgets in #2731/#2801 #2805

Description

@sonichi

tests/task-workstream-session-worker.test.py is roughly a third of today's CI failures (7 of 20 by step-level attribution). Two open items already address timing assertions in that file — #2731 for the 1.0s budget at :465, and PR #2801 for the one at :953. The failure actually observed in CI is neither of those.

What fails in CI

tests/task-workstream-session-worker.test.py", line 1331, in <module>
  test_required_team_handler_shutdown_never_falls_through()
tests/task-workstream-session-worker.test.py", line 804, in test_required_team_handler_shutdown_never_falls_through
  assert "TASK_FILE:" not in stdout
AssertionError

Not a wall-clock budget — an assertion that the watcher emitted no TASK_FILE: line during a required-team-handler shutdown.

Observed directly in runs 31519127153 and 31457840538. A third sampled failing run (31416999062) had no frame for this file. So this is 2 of the 7 read, not all 7 — but no sampled run showed :465 or :953 failing in CI.

It is flaky, not deterministic

PR #2741 was green at head 5c6c4414 and red at 20976bda after nothing but a branch update — identical PR content, re-run CI, different outcome.

Blast radius is larger than one check

scripts/coverage-gate.sh refuses to compute with coverage-gate: suite must be green before coverage is meaningful, so this one test also turns diff coverage >= 95% (python) red. Two distinct-looking failure buckets are driven by the same test, which makes the failure set look more diverse than it is.

Reproduction status — not reproduced, and the negative is weak

  • Whole file at origin/main 3afc80c on macOS: EXIT=0, "task workstream session worker tests passed".
  • The single failing function called 8x in one process: 0/8 failures.

That negative should not be read as "the test is fine on macOS." CI runs a fresh process in which 23 module-level tests execute before this one, on a shared loaded runner; my repeat-call loop reproduces none of those conditions. The right next step is a repro under a fresh-process, full-file, loaded-machine condition — ideally on Linux — before proposing a fix, since a fix for a race you cannot trigger cannot be verified.

Why file it separately

#2731 and #2801 are both about hardware-speed assumptions. If they land, the timing budgets stop failing and this assertion still will. Filing so the CI-cost measurement is not read as already-addressed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions