question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add configuration debugpyPath

See original GitHub issue

When developping my project in specific environments, I want to use a specific executable of debugpy, like I can for formatting (e.g. black) or linting (e.g. flake8).

Or maybe just be able to let python pickup the available debugpy.

Current behavior: VS Code Python only use its own .vscode-server-insiders/extensions/ms-python.python-2020.10.332292344/pythonFiles/lib/python/debugpy/launcher

For now I have to use this setup to debug my projects:

{
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Start debug (Nix)",
            "request": "launch",
            "type": "node-terminal",
            "command": "nix-shell --run 'python -m debugpy --listen localhost:5678 --wait-for-client -m myproject'",
            "env": {}
        },
        {
            "name": "Connect debug (Nix)",
            "type": "python",
            "request": "attach",
            "port": 5678,
        }
    ]
}

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
karthiknadigcommented, Nov 5, 2020

This is available, via debugAdapterPath.

        {
            "name": "Launch: program",
            "type": "python",
            "request": "launch",
            "console": "integratedTerminal",
            "program": "${file}",
            "debugAdapterPath": "<path-to-installed-libraries>/debugpy/adapter",
        },

You will see squiggles, since this is not exposed via launch.json schema. But it should work.

0reactions
karthiknadigcommented, Jan 14, 2021
Read more comments on GitHub >

github_iconTop Results From Across the Web

Debugging configurations for Python apps in Visual Studio Code
Specifies a path to an existing directory for saving logs. --log-to-stderr, none, Optional. Enables debugpy to write logs directly to stderr. --pid, <pid> ......
Read more >
Debug configuration settings · microsoft/debugpy Wiki - GitHub
Property Type Configuration django Boolean Launch/Attach gevent Boolean Launch/Attach jinja Boolean Launch/Attach
Read more >
Remote debugging with debugpy works from code but not ...
Everything works fine. I can put breakpoints, jump around the code, perfect. Now, if instead of adding the code at top, I do:...
Read more >
Configuration | Vimspector Documentation
Project and global configurations; Ad-hoc configurations; Configuration selection ... and build-time paths, and to parameterise the debug configuration.
Read more >
Remote Debugging with PyCharm - JetBrains
on the toolbar, and from the list of available configurations, select Python Debug Server. Adding a Python remote debug configuration. Enter the ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found