Skip to content
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

justMyCode stopped working after version 2024.10.0 #1785

Open
musateduard opened this issue Dec 17, 2024 · 5 comments
Open

justMyCode stopped working after version 2024.10.0 #1785

musateduard opened this issue Dec 17, 2024 · 5 comments
Assignees
Labels
bug Something isn't working Fixed in next release This issue has been fixed, but won't be available to customers until the next release.

Comments

@musateduard
Copy link

hi,

i'm using vs code with the python debugger extension and i noticed that recently stepping into 3rd party libraries stopped working. the version that i noticed this happening on is 2024.14.0 and the last version where i could get it to work is 2024.10.0 which is the one that i currently switched to. can someone have a look into this?

thanks

python version: 3.12.0
os version: windows 10 10.0.19045
vs code version: 1.96.0
current debugger version: 2024.14.0
last working version: 2024.10.0

launch.json config

{
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python: Current File",
            "type": "debugpy",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal",
            "justMyCode": false
        },
        {
            "name": "Python: Tests",
            "type": "debugpy",
            "request": "launch",
            "program": "${file}",
            "purpose": ["debug-test"],
            "console": "integratedTerminal",
            "justMyCode": false
        }
    ]
}
@hanlsin
Copy link

hanlsin commented Dec 17, 2024

I also got the same issue.

  • OS: maxOS Sonoma 14.6.1
  • Python: 3.12.3
  • Python Debugger: 2024.14.0

And I faced the same message "Frame skipped from debugging during step-in." like as @Real-Gecko commented: microsoft/vscode-python-debugger#139 (comment)

@karthiknadig karthiknadig transferred this issue from microsoft/vscode-python-debugger Dec 17, 2024
@github-actions github-actions bot added the needs repro Issue has not been reproduced yet label Dec 17, 2024
@rchiodo
Copy link
Contributor

rchiodo commented Dec 17, 2024

This only seems to reproduce with test debugging. Not sure why at the moment.

If you use this for debugging a file, stepping into 3rd party libraries works fine:

        {
            "name": "Python Debugger: Current File",
            "type": "debugpy",
            "request": "launch",
            "program": "${file}",
            "purpose": ["debug-in-terminal"],
            "console": "integratedTerminal",
            "justMyCode": false,
            "logToFile": true
        },

But this won't (when debugging tests)

        {
            "name": "Python: Debug Tests",
            "type": "debugpy",
            "request": "launch",
            "program": "${file}",
            "purpose": [
                "debug-test"
            ],
            "console": "integratedTerminal",
            "justMyCode": false,
            "logToFile": true
        }

The only difference I see in the launch is the 'rules' section of the launch args.

        "rules": [
            {
                "include": false,
                "path": "c:\\Users\\rchiodo\\.vscode-insiders\\extensions\\ms-python.python-2024.23.2024121701-win32-x64\\python_files"
            }
        ],

The normal debug launch doesn't include those rules, the test debug launch does. I don't think that should be interfering though, but maybe there's a bug in the include matching.

@rchiodo
Copy link
Contributor

rchiodo commented Dec 17, 2024

Here's the example test I used:

import pytest

def test_debugstepinto():
    pytest.approx(1.0, 1.2) # Try stepping into this line. 
    print("after")

@rchiodo rchiodo assigned rchiodo and unassigned KacieKK Dec 17, 2024
@rchiodo rchiodo added bug Something isn't working and removed needs repro Issue has not been reproduced yet labels Dec 17, 2024
@rchiodo
Copy link
Contributor

rchiodo commented Dec 18, 2024

It also works for 3.11 or earlier. Must be a bug in the sys.monitoring code

@rchiodo
Copy link
Contributor

rchiodo commented Dec 18, 2024

Found the location. We're not using the 'justMyCode' setting in the sys.monitoring to code to check if we should filter things not in the project scope.

@rchiodo rchiodo added the Fixed in next release This issue has been fixed, but won't be available to customers until the next release. label Dec 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Fixed in next release This issue has been fixed, but won't be available to customers until the next release.
Projects
None yet
Development

No branches or pull requests

4 participants