You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Bun process does not exit after Tinypool destroy() completes (worker threads remain alive) #29173
✅ Reproduced — worker.terminate() hangs because the worker is parked in Atomics.wait (tinypool's atomicsWaitLoop). Fix in #29179 — from the parent thread we set hasTerminationRequest on the child VM and notify its syncWaiter condition directly, so the wait loop exits and atomicsWaitImpl returns Terminated.
Core tinypool repro now exits cleanly; PR is pending a couple of residual test crashes in unrelated worker teardown paths that surface the termination-flag interaction.
For anyone landing here: this was closed by #37075, but builds from that change alone still hung on this report's root cause (worker.terminate() against a worker parked in Atomics.wait(), which is where Tinypool's idle workers sit). The part that fixes that landed in #38457 (merge commit 97a4363, via a WebKit bump), so the first build containing that commit is the one to test against. Verified with the bare Atomics.wait() repro against main at that commit, not with Tinypool itself.
Activity
github-actions commentedon Apr 11, 2026
Found 3 possible duplicate issues:
Worker.terminate()in Bun behaviorally different from Node #29077This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
robobun commentedon Apr 11, 2026
✅ Reproduced —
worker.terminate()hangs because the worker is parked inAtomics.wait(tinypool'satomicsWaitLoop). Fix in #29179 — from the parent thread we sethasTerminationRequeston the child VM and notify itssyncWaitercondition directly, so the wait loop exits andatomicsWaitImplreturnsTerminated.Core tinypool repro now exits cleanly; PR is pending a couple of residual test crashes in unrelated worker teardown paths that surface the termination-flag interaction.
fix(worker_threads): unblock worker.terminate() when parked in Atomic…
worker: make terminate() interrupt a worker blocked in Atomics.wait
Worker / worker_threads: WebCore-shaped lifetimes, joined threads, on…
Worker / worker_threads: WebCore-shaped lifetimes, joined threads, on…
robobun commentedon Aug 14, 2026
For anyone landing here: this was closed by #37075, but builds from that change alone still hung on this report's root cause (
worker.terminate()against a worker parked inAtomics.wait(), which is where Tinypool's idle workers sit). The part that fixes that landed in #38457 (merge commit 97a4363, via a WebKit bump), so the first build containing that commit is the one to test against. Verified with the bareAtomics.wait()repro against main at that commit, not with Tinypool itself.