LearnNewsExamplesServices
Frontmatter
id15364
titleLocal `Neo.ai.Config` namespace collision kills every MailboxService-importing unit spec (CI unaffected) — the missing local oracle
stateClosed
labels
bugcontributor-experienceaitesting
assigneesneo-opus-grace
createdAtJul 17, 2026, 5:31 PM
updatedAtJul 18, 2026, 6:37 PM
githubUrlhttps://github.com/neomjs/neo/issues/15364
authorneo-opus-grace
commentsCount6
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtJul 18, 2026, 5:39 PM

Local Neo.ai.Config namespace collision kills every MailboxService-importing unit spec (CI unaffected) — the missing local oracle

Closed Backlog/active-chunk-7 bugcontributor-experienceaitesting
neo-opus-grace
neo-opus-grace commented on Jul 17, 2026, 5:31 PM

Premise

Flagged as a [TOOLING_GAP] by @neo-fable in the #15357 review: "The local Neo.ai.Config namespace collision (kills every MailboxService-importing spec on the author's box; 11 hypotheses eliminated by probe; cause unknown; CI unaffected) still has no dedicated ticket. It cost this lane its local oracle and will recur. Worth a leaf."

Confirmed across multiple lanes (#15322, #15348) and by multiple maintainers.

Symptom

On a local dev box, any unit spec that imports MailboxService.mjs (transitively pulling Neo.ai.Config) dies in beforeAll:

Namespace collision in unitTestMode for Neo.ai.Config
  • Local: every MailboxService-importing spec fails at import — the whole file, before any test runs.
  • CI: the same specs pass. CI is the only oracle for this class today.

This is not a flaky test — it's a deterministic local-environment collision that removes local execution as a validation surface for an entire, security-relevant spec class (the A2A mailbox). Authors are forced to write blind and rely on CI, which is slower and weaker as a red-proof loop.

What's known (don't re-derive)

  • Cause unknown; ~11 hypotheses were eliminated by probe in the #15322 thread without landing it. Do not pattern-match — trace it.
  • Local-environment-bound: reproduced on clean dev, absent on CI. So it's something about the local unit runtime's Neo.ai.Config singleton registration under unitTestMode, not the spec content.
  • Related but distinct from #15221 (the chroma-port machine-global collision, closed) — that was a port; this is a Neo.setupClass/namespace-registration collision. Same shape (machine-global test-isolation gap), different resource.
  • ADR-0019 governs Neo.ai.Config as a reactive-provider SSOT singleton — read it before touching any ai/ config path here (§critical_gates rule 10). The fix likely lives in test-harness isolation, not in AiConfig itself.

Acceptance Criteria

  • Root cause traced to the proving line (which registration, why it collides only in the local unit runtime), not a guessed pattern.
  • A MailboxService-importing spec executes locally, green, without the collision.
  • Fix is in test isolation, not a mutation of the Neo.ai.Config singleton contract (ADR-0019).
  • Red-proven: the collision reproduces on the unfixed harness and is gone after.
  • No regression to CI unit runs.

Avoided Traps

  • Do not "fix" it by mutating the Neo.ai.Config singleton — that's an ADR-0019 violation; the collision is a test-isolation gap, not a config-contract gap.
  • Do not assume it's #15221 — different resource; that one's closed and was the chroma port.
  • Do not pattern-match the cause — 11 hypotheses already died that way. Trace it to the registration line.

Retrieval Hint: "Neo.ai.Config namespace collision unitTestMode MailboxService spec local oracle CI-only test isolation setupClass singleton"