Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 23 additions & 19 deletions quest/m1/bun-efault.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,31 +2,35 @@

## Goal

oven-sh/bun has a report for `rmSync(file, { force: true })` throwing
`EFAULT` on Windows when two processes remove the same file at once. Node
throws `EPERM` there. Once a Bun release fixes it and Quest's pin includes
that release, `remove()` in `src/cli/gate.ts` stops tolerating `EFAULT`, and
this quest is deleted.
Bun no longer throws `EFAULT` from `rmSync(file, { force: true })` on Windows
when two processes remove the same file at once (Node throws `EPERM`). Once a
Bun release fixes it and Quest's pin includes that release, `remove()` in
`src/cli/gate.ts` stops tolerating `EFAULT`, and this quest is deleted.

## Plan

Decided 2026-10-28 (user, /quest-plan of the follow-ups from a 25-PR /quest-complete run). Posting the report to oven-sh/bun is approved.

- [moq-dev/quest#233](https://github.com/moq-dev/quest/pull/233) found the
race and worked around it. Its diagnostic runs have the minimal repro: two
processes `rmSync` the same file on `windows-11-arm` and `windows-2022`.
- Search existing Bun issues first, and comment on a match instead of opening
a duplicate. As of 2026-11-02 nobody from moq-dev has commented or opened
one. The closest reports are
[oven-sh/bun#39708](https://github.com/oven-sh/bun/issues/39708), the
recursive case, with its fix
[oven-sh/bun#39710](https://github.com/oven-sh/bun/pull/39710), and the
single-file fix
[oven-sh/bun#38550](https://github.com/oven-sh/bun/pull/38550); all three
are open.
- Reported upstream on 2026-11-14 (approved by the user, 2026-10-28) as a
[comment with the Windows repro and counts](https://github.com/oven-sh/bun/issues/48811#issuecomment-6882793150)
on [oven-sh/bun#48811](https://github.com/oven-sh/bun/issues/48811), the
report filed 2026-11-13 that matches this exactly but had no Windows run.
- The fix to wait for is
[oven-sh/bun#48816](https://github.com/oven-sh/bun/pull/48816), open: it makes
non-recursive `rm` report the errno `unlink` returned, so the losing caller
gets `EPERM` as in Node. `remove()` already tolerates `EPERM`, so only the
`EFAULT` entry goes.
- The recursive case is
[oven-sh/bun#39708](https://github.com/oven-sh/bun/issues/39708) with its fix
[oven-sh/bun#39710](https://github.com/oven-sh/bun/pull/39710), both open.
[oven-sh/bun#38550](https://github.com/oven-sh/bun/pull/38550), the earlier
single-file fix, closed unmerged on 2026-11-13.

## Waiting

- oven-sh/bun: a release fixes `rmSync` throwing `EFAULT` when two processes
remove one file on Windows, and Quest's pin includes it. Check the report
and the fix PRs above each time ready work is triaged.
- oven-sh/bun: a release carries a fix for
[oven-sh/bun#48811](https://github.com/oven-sh/bun/issues/48811) (likely
[oven-sh/bun#48816](https://github.com/oven-sh/bun/pull/48816)), and Quest's
pin includes it. Check the issue and the fix PR each time ready work is
triaged.
Loading