Repository navigation
Description
Client or integration
Other
Area
Other
Summary
On clean dev commit e6c6e13a22e465812f509a423990e9f09e32b1d0, tests/routing/combo-management-api.test.ts reproducibly reports 37 pass / 2 fail / 1 error under Bun 1.4.0.
PUT renames atomically, migrates public references, and clears both ids reaches provider model discovery, logs DestinationDnsResolutionError, and exceeds its default 5000ms timeout. Its async work then continues into the next test, producing an unhandled assertion (new-public expected, stable-public received). PUT rename migrates canonical references when the public alias stays unchanged subsequently reads a missing config file (ENOENT).
Expected: these existing local-fixture tests complete without depending on external DNS/model discovery, and one timed-out test cannot mutate or remove another test's fixture. This report does not establish that combo rename is broken in production; the reproducible defect may be missing test dependency isolation plus timeout cleanup.
The failures reproduce both in a worktree with an unrelated /v1/messages header patch and in a pristine git archive HEAD extraction with no source modifications. The separate reproducible native Codex toggle failure is tracked in #6776.
Reproduction
- Use a clean checkout of dev at
e6c6e13a22e465812f509a423990e9f09e32b1d0, with dependencies installed. - Start Bun with a fresh fake HOME to avoid the separate [Bug]: bare
bun testprunes the real ~/.claude/agents/ocx-*.md (Bun homedir() ignores the preload's HOME sandbox) #6775 test-home hazard:
FH=$(mktemp -d)
mkdir -p "$FH/.claude"
env -u HTTPS_PROXY -u NODE_EXTRA_CA_CERTS HOME="$FH" CLAUDE_CONFIG_DIR="$FH/.claude" \
"$BUN_BIN" test --cwd "$CHECKOUT" tests/routing/combo-management-api.test.ts
BUN_BIN is the absolute Bun executable; CHECKOUT is the repository directory.
- Observe the timeout at the case starting on line 1028, the unhandled assertion at line 1105, and the next test's missing fixture at line 1139.
- Repeat against a pristine archive of the same commit with the same dependencies. Both isolated focused runs yield 37 pass / 2 fail / 1 error, around 6 seconds. An import-connected suite also exhibits the same failures.
No real user home, installed package, or running service was modified. There are no paid provider calls in the reproduction; the unexpected discovery path fails DNS.
Version
2.82.0-dev, commit e6c6e13
Operating system
Linux x86_64, kernel 7.0.0-38-generic; Bun 1.4.0 (34cbb9a40)
Provider and model
Synthetic test providers a/b/c, models m1/m2; not a real provider-specific report.
Logs or error output
[opencodex] Provider model discovery for "a" threw DestinationDnsResolutionError [urlClass=provider-models, fallback=configured].
[opencodex] Provider model discovery for "b" threw DestinationDnsResolutionError [urlClass=provider-models, fallback=configured].
(fail) combo management API > PUT renames atomically, migrates public references, and clears both ids [5000.40ms]
^ this test timed out after 5000ms.
# Unhandled error between tests
error: expect(received).toBe(expected)
Expected: "new-public"
Received: "stable-public"
at tests/routing/combo-management-api.test.ts:1105:44
ENOENT: no such file or directory, open '<isolated-test-home>/.opencodex/config.json'
at tests/routing/combo-management-api.test.ts:1139:36
(fail) combo management API > PUT rename migrates canonical references when the public alias stays unchanged
37 pass
2 fail
1 error
Ran 39 tests across 1 file.
Screenshots and supporting files
No screenshots; existing committed tests reproduce the problem without extra files.
Redacted configuration
The reproduction uses the synthetic baseConfig and withTempHome fixtures already committed in tests/routing/combo-management-api.test.ts; no production configuration is required.
Checks
- I searched existing issues and documentation.
- I removed secrets, tokens, account details, request credentials, and personal data.
Activity
fix(test): keep test processes out of the real Claude config directory (
lidge-jun commentedon Oct 9, 2026
Fixed on
devby #6833 (merge commit 6d7e5f4).It was test isolation, as you suspected. The fixture's synthetic providers had live discovery on, so the rename route's awaited Claude agent sync reached provider DNS, which the request's abort signal does not bound. A slow lookup pushed the case past 5 s, and Bun started the next case while the first was still running. The fixture now uses
liveModels: false,withTempHomeowners are serialized and drained (bounded) inafterEach, and a stuck owner poisons the helper instead of sharing its environment. Regressions cover zero discovery calls on rename, overlapping owners, and the poison path. The route's await is unchanged. Thanks for the clean reproduction.docs(devlog): close the N3 test-infra unit (#6840)