Debugger not working properly.
See original GitHub issueEnvironment data
- VS Code version: 1.27.0 and 1.28.0
- Extension version (available under the Extensions sidebar): 2018.9.0
- OS and version: Debian x86-64 Linux Kernal: 4.17.0
- Python version (& distribution if applicable, e.g. Anaconda): 2.73
- Type of virtual environment used (N/A | venv | virtualenv | conda | …): N/A
- Relevant/affected Python packages and their versions: None
Actual behavior
Breakpoint pauses execution, but provides no debugger functionality
Expected behavior
I’m expecting the debugger to stop at the breakpoint and present me with the various variables and call stack.
Steps to reproduce:
- Previous VS code uninstalled, ~/.config/Code deleted, ~/.vscode deleted. Clean VS Code installed, python extension installed.
- Construct a very simple Hello.py: msg = “Hello” print(msg)
- Place breakpoint on print line.
- Start debugger.
4a. For vscode 1.27.0, the debugger toolbar comes up with Continue, Step Over, Step Into, Step Out, Restart, and Stop all enabled - breakpoint appears to be hit and Call Stack says “Paused on breakpoint”, but no variables or call stack information presented. If I click on Continue, Step Over, Step Into, Step Out then ‘Hello’ is printed and the program finishes it’s run (this is true even if I place the break point on the msg definition line).
4b. For vscode 1.28.0, the debugger toolbar comes up with Pause, Restart, and Stop enabled - breakpoint appears to be hit but none of the other buttons are enabled. Call Stack says “Paused on breakpoint”, but no variables or call stack information presented. Unable to do anything meaningful at this point other than Stop - Pause does nothing.
4c. If the breakpoint was not set then ‘Hello’ is printed out in the terminal, the process finishes, and the prompt shows.
Logs
Output for Python
in the Output
panel (View
→Output
, change the drop-down the upper-right of the Output
panel to Python
)
##########Linting Output - pylint##########
Your code has been rated at 10.00/10 (previous run: 10.00/10, +0.00)
Output from Console
under the Developer Tools
panel (toggle Developer Tools on under Help
)
INFO no standard startup: not a new window
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:57 (14 by maintainers)
Top Results From Across the Web
visual studio - Why the debugger doesn't work - Stack Overflow
There could be a logical error in your code that is causing your breakpoint to not be hit (i.e. the method you are...
Read more >Troubleshoot Breakpoints in the Visual Studio Debugger
If you're debugging optimized code, make sure the function where your breakpoint is set isn't being inlined into another function. The Debugger.
Read more >Visual Studio Community 2017 Debugger not working correctly
The application I am not getting the debuger to work on is an older Visual Studio 2008 program that was upgraded to Visual...
Read more >Debugger Not Working - A Possible Solution | OutSystems
A Possible Cause ... During a debug session, the IDE contacts the environment where your app is deployed using HTTPS or HTTP if...
Read more >What to do if debugger doesn't work as expected?
go to Help | Diagnostic Tools | Debug Log Settings · add #com. · reproduce the problem (mind, this step should happen after...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@JasonWorks, @Verkurkie Can you try this with
"debugStdLib": true
in launch json? @DonJayamanne I suspect this might be a an issue with where we remove debugger and std lib frames.@pranav08 This occurs because when debugStdLib=false we try to skip any frames that are not in the standard library or site-packages. The issue occurs when the venv directory is a sub-directory of the project or workspace directory.