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
[Windows] Crash on startup: Bun Canary v1.3.10 panic - Internal assertion failure: ThreadLock is locked by wrong thread #15010
When running opencode on Windows 11, the application crashes immediately on startup with a Bun internal panic error related to ThreadLock. The error indicates that a lock is held by one thread but accessed by another, suggesting a race condition or threading bug in the bundled Bun Canary version.
This happens consistently when running the command in any directory on the E: drive (and potentially other non-system drives).
Error Output
============================================================
Bun Canary v1.3.10-canary.100 (6b1d6c76) Windows x64 (baseline)
Windows v.win11_dt
CPU: sse42 avx avx2
Args: "D:\DevTools\npm-global\node_modules\opencode-ai\node_modules\opencode-windows-x64\bin\opencode.exe" "--user-agent=opencode/1.2.11" "--use-system-ca" "--"
...
panic(thread 16724): Internal assertion failure: `ThreadLock` is locked by thread 14356, not thread 16724
oh no: Bun has crashed. This indicates a bug in Bun, not your code.
### Plugins
_No response_
### OpenCode version
1.2.11
### Steps to reproduce
1. Install `opencode-ai` globally via npm: `npm install -g opencode-ai`
2. Navigate to any folder on a non-system drive (e.g., `E:\Fitness-ai-backend`)
3. Run the command: `opencode`
4. Observe immediate crash with the above panic message.
### Screenshot and/or share link
_No response_
### Operating System
Windows 11
### Terminal
Windows Terminal
Activity
github-actions commentedon Feb 25, 2026
This issue might be a duplicate of existing issues. Please check:
JingxuanZhang commentedon Feb 25, 2026
npm install -g opencode-ai@1.2.10, add env
OPENCODE_DISABLE_AUTOUPDATE=1until offical fix this bugAcidmoon commentedon Feb 25, 2026
OK,I will try it,thank u.
BenjaminAaron196 commentedon Feb 25, 2026
A very serious issue, hope the official can fix it as soon as possible, completely unable to start
ciihom commentedon Feb 25, 2026
Correct
razzh7 commentedon Feb 25, 2026
same issue in windows11
FJRG2007 commentedon Feb 25, 2026
I have the same problem. Since today, I haven't been able to access OpenCode on Windows 11, even after installing the latest version.
Is there any news about whether this is being worked on to resolve the issue as soon as possible?
oldiberezkoo commentedon Feb 25, 2026
temporary workaround: for powershell
Anyone who applies this workaround should set a reminder to remove this environment variable in three days in order to resume receiving updates.
Hona commentedon Feb 25, 2026
downgrade as others have mentioned.
I'm working on a minimal repro for the bun team and ideally I will submit a fix PR.
radoslawg commentedon Feb 25, 2026
I was puzzled why this happens for only one of my projects. I wiped my whole configuration to no avail.
The other workaround that works for me is to move
.envfile out of directory you starting opencode on.Hona commentedon Feb 25, 2026
I've created a minimal repro.
oven-sh/bun#27431
In theory if the runtime pwd doesnt contain a .env file we should be fine.
Seeing about a PR shortly
Hona commentedon Feb 26, 2026
please upgrade to latest OpenCode v1.2.15 - and try again.
There should be no more segfaults/crashes.
Can you confirm it works fine after the version is >v1.2.15 :)