-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bun napi panic #13253
Comments
Does this still occur in Bun v1.1.27? |
I think it v1.1.27 fixed the issue both on windows and linux. Nice! |
Sorry, for the confusion. It actually still happens. Just this time it is a bit delayed, so in my quick testing the issue did not occur (middle of the night). |
I have a similar problem with the following sample project, which uses Astro & lightningcss. https://github.com/haxibami/bun-sample When I remove
|
i use lightning css too, so that may be a good starting point |
#13771 (pure Vite + lightningcss) looks similar, but the error seems to be caused by adding |
What version of Bun is running?
1.1.22
What platform is your computer?
Microsoft Windows NT 10.0.22631.0 x64 (also linux on fedora 40)
What steps can reproduce the bug?
Run my vite dev server with bunx --bun vite dev. After that the dev server starts and displays initial message normally but after opening the link in the browser it crashes.
Unfortunately the bug is not reproducible with bun's vite demo.
What is the expected behavior?
Dev server serves requests.
What do you see instead?
thread '' panicked at napi\src\threadsafe_function.rs:235:57:
called
Result::unwrap()
on anErr
value: Error { status: InvalidArg, reason: "expect Function, got: Object", maybe_raw: 0x0 }stack backtrace:
0: 0x7ffc5fd383dd - napi_register_module_v1
1: 0x7ffc5f558fad -
2: 0x7ffc5fd2dbb1 - napi_register_module_v1
3: 0x7ffc5fd3a1ca - napi_register_module_v1
4: 0x7ffc5fd39a99 - napi_register_module_v1
5: 0x7ffc5fd3a900 - napi_register_module_v1
6: 0x7ffc5fd3a3f9 - napi_register_module_v1
7: 0x7ffc5fd3a339 - napi_register_module_v1
8: 0x7ffc5fd3a322 - napi_register_module_v1
9: 0x7ffc5fd3c367 - napi_register_module_v1
10: 0x7ffc5fd3c8b3 - napi_register_module_v1
11: 0x7ffc5fcffba1 -
12: 0x7ff7688f58c8 - napi_remove_async_cleanup_hook
13: 0x7ff7688f2cfb - napi_remove_async_cleanup_hook
14: 0x7ff768497174 -
15: 0x7ff7683c75d5 -
16: 0x7ff76aa8d77b - uv_getnameinfo
17: 0x7ff76834a975 -
18: 0x7ff7684b0573 -
19: 0x7ff76834e242 -
20: 0x7ff768303aba -
21: 0x7ff768302da0 -
22: 0x7ff7680621bc -
23: 0x7ff76806117b -
24: 0x7ff76ad7e74c - node::RemoveEnvironmentCleanupHook
25: 0x7ffd3408257d - BaseThreadInitThunk
26: 0x7ffd3500af28 - RtlUserThreadStart
error: script "dev" exited with code 9
Additional information
The behavior on my linux machine is the same.
I upgraded from Bun 1.1.17, which had no issues.
The text was updated successfully, but these errors were encountered: