-
Notifications
You must be signed in to change notification settings - Fork 28.3k
Cannot debug Next15 using turbopack on windows #72789
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
Comments
Hi @leandroluk. I'm experiencing the same behavior on my machine with Windows 10, vscode 1.95.2 and npm. Could you consider adding the context that this issue occurs in VSCode and including the launch.json file in your example repo? I hope this helps to resolve the issue. Thanks! 👍 |
Yeah, if you could provide the launch config, we can take a closer look. |
Seeing essentially the same issue on Mac.
{
"version": "0.2.0",
"configurations": [
{
"name": "Attach to My App",
"type": "chrome",
"request": "attach",
"port": 9222,
"urlFilter": "http://localhost:3003/*",
"sourceMaps": true,
}
]
} |
Hello! Just rebumping this issue. Found a couple of things regarding the launch.json and turbopack. #74002 i.e () would equal to %28 and %29 respectively. I am currently using this as my launch.json config
I expect that the breakpoint be hit using the local files given the sourcemap is correct. Instead what i get is that the file being read/debugged/hit is under _next folder. Only when adding a And overriding the url-encoded path Note The "B%3A" is irrelevant here because that is my drive. BUT a part of the issue because of how turbopack handles the encoding of special characters when trying to map the sourcemaps to its local version. As of right now. In order for my to bypass the issue of not being able to use turbopack. I remove the line |
This problem happens even without special characters. In fact, I gave up, I'm going to use it without turbopack. Turbopack is fragile. |
Having issues using attach as well, not sure if it's related to windows or not. A few things I noticed NODE_OPTIONS='--inspect=9231' next dev --turbopack I get: Debugger listening on ws://127.0.0.1:9231/97faf0f0-34f0-4446-b55a-f0de7cb0f6d7
For help, see: https://nodejs.org/en/docs/inspector
Debugger listening on ws://127.0.0.1:9232/c418e274-cd72-4080-a9db-b5989111fad2
For help, see: https://nodejs.org/en/docs/inspector
the --inspect option was detected, the Next.js router server should be inspected at 9232. None of those debugging ports show up in vscode. However, a port scan shows they are open and listening. I don't know if this is an issue with next or vscode, but I don't normally have issues attaching to debugging ports in other projects. lsof -i :9231,9232 yields COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
node 19088 {REMOVED} 18u IPv4 {REMOVED} 0t0 TCP localhost:9231 (LISTEN)
node 19094 {REMOVED} 19u IPv4 {REMOVED} 0t0 TCP localhost:9232 (LISTEN) Running dev server without turbopack is painfully slow for me. |
Very simple projects, including official sample projects, will have this issue. |
:'( |
Related code: next.js/turbopack/crates/turbopack-core/src/source_map/utils.rs Lines 178 to 185 in 98e61ef
and next.js/turbopack/crates/turbo-tasks-fs/src/util.rs Lines 141 to 164 in 98e61ef
Fixing it would be trivial, but I need to figure out how to extend device space in UTM because I cannot build next.js on my Windows VM at the moment due to |
I'm trying to use it, but I'm not sure if those codes are really related. I'll report back after trying it on mac os, which is known to be work. |
Thank you also! Appreciate the big help here! |
Thank you so much for all your help. It really helped 😄 👍 |
Thank!Thank ! |
Link to the code that reproduces this issue
https://github.com/leandroluk/bug-next15-debug-with-turbopack
To Reproduce
Current vs. Expected behavior
Are expected to debug works like webpack.
Provide environment information
Which area(s) are affected? (Select all that apply)
Turbopack
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: