-
Notifications
You must be signed in to change notification settings - Fork 27.6k
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
Turbopack: Bun APIs don't work with next #75220
Comments
It seems there are many bugs with the new version. I had to go back to v15.1.5 |
it has always been a problem |
@luudv do have example |
I have the same problem with the
(ignore the unnecessary first code line) Environment:
|
Update: the problem seems to be turbopack. Omiting the |
Yes I think turbo pack and web pack need to also build for bun |
Thanks will try |
It could be napi-rs (turbo pack builder)producing node code and doesn't know about bun |
@samcx this turbopack error |
@LarsKumbier This is the right place for Turbopack issues! |
@samcx Thank you - any more information I can provide for the replication of the issue or debugging? |
Can't get my head around it and make it work... I was on NextJS 15.1.6 with turbopack on
|
@heymattiarighetti it definetly works for me without turbopack.
Just tested it again (successfully) with Next.JS 15.1.6. If it still doesn't work for you, please start the dev server and post a |
@LarsKumbier yes, I later realized it works with turbopack and the latest NextJS... What doesn't work instead is the built s3 object support, even when running it from bun instead of nodejs These are my processes:
but the error persists
I also tried it on a completely new NextJS project (with the correct @types/bun and everything) What's weird is that even a simple I'm losing my mind on this! |
A
But it absolutely does not work with
AFAIK, you must not use turbopack for the time being. |
Yep @samcx this 100% turbo pack anyone willing to work on this and possibly add deno support |
Next will need to import if they spot this |
I'm not sure what changed between my earlier tests and this, but now it works! FINALLY! This is how it ran:
More specifically, I have the Also, set up the custom script on Vercel and it works fine (waiting the Thanks a lot, @LarsKumbier!! |
Link to the code that reproduces this issue
https://github.com/brrock/buntestapis/
To Reproduce
Start the app with
bun run --bun dev --turbo pack
and use the form the api route should fail to compile even though I'm using bun and have bun types installedCurrent vs. Expected behavior
I expect this to just use the bun runtime and compile and work simply work but throws this error Error:
Provide environment information
Which area(s) are affected? (Select all that apply)
Runtime
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
No response
The text was updated successfully, but these errors were encountered: