LearnNewsExamplesServices
Frontmatter
id14917
titleFleet app specs: cross-file bleed — healthSwatch fails in company
stateClosed
labels
bugaitesting
assigneesneo-fable
createdAt4:42 AM
updatedAt5:53 AM
githubUrlhttps://github.com/neomjs/neo/issues/14917
authorneo-fable
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAt5:53 AM

Fleet app specs: cross-file bleed — healthSwatch fails in company

Closed Backlog/active-chunk-4 bugaitesting
neo-fable
neo-fable commented on 4:42 AM

Context

Second documented datum (first: 2026-07-05, again 2026-07-10 during the PR #14910 review, reproduced on clean dev): test/playwright/unit/apps/agentos/view/fleet/healthSwatch.spec.mjs:42 ("renders a legend row (no count) — state dot + label, no count element") fails whenever the spec runs in ANY multi-file company, and passes 6/6 solo. In a larger 3-dir batch (ai/services/fleet + ai/graph + the fleet app dir, --workers=1), eventChip.spec.mjs:27 and fleetGrid.spec.mjs:103 ALSO fail — and pass when the batch shrinks to 3 files. Classic order-dependent cross-file state bleed.

The Problem

Local batch runs of the fleet app specs are untrustworthy: reviewers must attribute failures by isolation-matrix runs (as done twice now), which burns review time and hides real regressions behind known noise. CI's sharding happens to dodge the failing order, so the bleed is invisible on PRs — until a shard boundary moves.

The Architectural Reality

  • Neo's single-thread custom Playwright layout: specs in one worker process share module state; test/playwright/setup.mjs boots a Neo app context per file via setup({neoConfig, appConfig}).
  • Suspects (V-B-A at implementation, in order): shared/colliding appName across fleet specs; module-level mutable state in a shared import (e.g. registries/singletons imported by multiple specs — FleetControlBridge spec resets its injected fields in beforeEach, but other fleet-view specs may leak component/vdom state); Neo config bleeding between setup() calls in the same worker.
  • The failure signature (legend-row DOM assertion) suggests leaked mounted components or vdom state from a prior spec file.

The Fix

Root-cause via bisection (pair healthSwatch.spec with each other fleet spec until the poisoning file is found), then fix the leak at its source (per-file isolation by construction — unique appNames, teardown of mounted components, or module-state reset), NOT by masking (no test re-ordering, no .serial, no retry).

Acceptance Criteria

  • Poisoning interaction identified and named in the PR (which file leaks what state)
  • Fix lands at the leak source; no ordering/retry masks
  • Full fleet app-spec dir passes --workers=1 three consecutive runs
  • The 3-dir batch from the #14910 review matrix (ai/services/fleet + ai/graph + fleet app dir) passes clean
  • If the root cause is generic (setup.mjs-level), file the generalization follow-up instead of scope-creeping this fix

Out of Scope

Rewriting the fleet specs' assertions; CI sharding changes; the pre-existing WIRE_SOURCES block-alignment drift (noted in PR #14910's body as surfaced-not-caused).

Related

#14637 (healthSwatch), #14594 (eventChip), #14599 (fleetGrid) — the specs' origin tickets · PR #14910 (tonight's isolation matrix evidence).

Live latest-open sweep: checked latest 20 open issues at 2026-07-10T02:45Z; no equivalent found. A2A in-flight claim sweep: last-60-min claims checked; no scope overlap.

Origin Session ID: b956ba53-01ed-4ea6-a1e5-62969f887bc3

Retrieval Hint: query_raw_memories("healthSwatch cross-file bleed isolation matrix fleet app specs")

tobiu referenced in commit ef45d1e - "fix(tests): cross-file spec bleed - restore neoConfig overrides + scope AgentOS mock (#14917) (#14922) on 5:53 AM
tobiu closed this issue on 5:53 AM