Allow stepping into code in virtual environment
I add packages (some authored by myself) from GitHub directly into my virtual environment. When debugging calls to functions in those packages I want to step into the package code to see what happens. stepping into the code currently produces:
Source not available Frame not in module The current stack frame was not found in a loaded module. Source cannot be shown for this location.
All the .py files are in a folder in the env folder. Can we please be able to step into this?
maybe another checkbox similar to: tools > options > python > debugging > enable debugging of the Python standard library
That checkbox should enable it for you, and it is the intended use of it. Yes, you'll also get stdlib, as well as site-packages, but that's by design.
One alternative you could consider is to add a .pth file that points to the package source but outside of the environment folder. We do matching based on path prefix, so if it's outside of sys.prefix (and sys.base_prefix/orig_prefix) we'll just let you step through it without changing the stdlib option.