-
Notifications
You must be signed in to change notification settings - Fork 145
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
Debugger freezes in VSCode #108
Comments
@lothas can you try adding |
I tried your suggestion but it still crashed. |
I have the same problem. I'm a professional developer and work with Python all day. I LOVE VS Code but debugging Python code is filling me with frustration because of this reason. It really seems random as @lothas mentioned: sometimes it happens after you step 2-3 times after hitting a breakpoint, sometimes it freezes while running (after hitting continue - not stopped in the debugger) - it's very frustrating because you wait 5 minutes for your breakpoint to get hit you step once or a few times and then nothing, the only thing you can do is just kill and start again. It seems to have gotten worse in the last month, it went from annoying to where I can't debug anything anymore. Please, please fix this. Configuration: OSX 10.14.6 (18G4032) Extension Author (truncated) Version |
Same issue here since 2 days. I attached my debugger log files. No idea what causes it. It seams totaly random but it makes debugging almost impossible. debugpy.server-11592.log |
@TimotheusT @ftrofin @lothas Thank you for the logs. We are trying to narrow down this issue. Here is something you can do temporarily to unblock. Add this to your user settings. "python.experiments.optOutFrom": [
"PtvsdWheels37 - experiment"
], Re-load after adding this setting. This should get you unblocked. |
@karthiknadig Thank you for the prompt response! This is awesome! I can debug again! Thanks for providing such a quick workaround! ❤️ it! |
@karthiknadig Seems to work fine! Thank you very much! |
@karthiknadig thank you! Finally I can debug to my heart's content! |
This is also happening to me. @karthiknadig's workaround does work for me as well too. VSCode Info
Python Extension Version: |
Looking at the logs, the last thing that the adapter does in all cases is receive the result of an "evaluate" request from pydevd, which was failing. Normally, it should then follow by failing the corresponding request from the client, and logging it. Also, judging by all these logs, there are a lot of entries in Watch list, many of which produce errors routinely (because the stops happen in places where the variables they reference are missing). So the recurring pattern here is that every time the IDE pauses, it re-sends all those "evaluate" to the debug adapter, which produces those errors. Now, until recently, the adapter was logging all such failures to stderr, as well. However, VSCode was not actually reading from that stderr... so once the pipe gets filled up, the adapter is locked trying to write to it. This would explain why its logs are completely cut off at this point. If this theory is true, then that would make it the same root cause as in #83, and the fix for that one should also apply here. The most recent insiders build of the extension has this fix already - can you please try it and see if it makes any difference? |
Also, if you are still running into this bug, can you try this simplified repro: def error():
raise RuntimeError(":o" * 100000)
while True:
pass then add |
Okay, so this wasn't actually fixed by #83, because the log grabs sys.stderr before it is redirected to /dev/null. |
When talking DAP over stdio, disable stderr before logging anything to it.
How is about the the code to add for debugging julia code? |
Im currently having the same issue but in AL Extension Business Central. anyone can help me ? |
Same here please if you get solution pls pin me too |
anyone can help? |
Use older veersion of VS code fix my issue "VSCodeUserSetup-x64-1.74.3" |
This is still happening to me |
I'm trying to debug a piece of code and experiencing a weird bug:
I run my code up to a breakpoint and then start stepping through it (with F10/F11). I sometimes hover over some variables to check the content. At any (seemingly random) point, VSCode stops stepping over the code. No error is thrown. The only thing left for me to do is stop debugging (hit the stop button) and start the run again.
debugger.vscode_f0ea2b1b-f0b2-43e2-9596-a42593fe7528.log
The text was updated successfully, but these errors were encountered: