-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Description
What version of Bun is running?
1.3.5
What platform is your computer?
darwin arm64 (Apple Silicon, macOS 14.5)
What steps can reproduce the bug?
- Clone https://github.com/hasesho05/bun-test-hang-repro?target=https://github.com
bun installbun test→ hangs, never exits- Each file individually passes fine:
bun test tests/parse-01.test.ts
What is the expected behavior?
bun test finishes and exits.
What do you see instead?
Test output appears, but the process never terminates. CPU stays low — not a busy loop, just stuck.
Additional information
Narrowed it down to three conditions that all need to be present:
- At least one test file using
@svgr/core(async transform) @xmldom/xmldomDOMParser called without a customonError— so it writes[xmldom fatalError]to stderr on parse errors- 7 or more test files — 6 is fine, 7 hangs every time
The stderr noise from xmldom (triggered by fast-check feeding random strings into DOMParser) seems to be the trigger when combined with the async svgr transform in a separate file.
Passing a custom onError to suppress the stderr output works around it. Migrated to vitest which runs everything in ~1.6s with no issues.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels