Skip to content
Advertisement

Tag: visual-studio-code

Is there a way to get VSCode to automatically use the closest Pipfile/pipenv?

E.g. for mono-repos with many python projects in them, it would be really nice if the linter, debugger, etc. would all look for packages specified in closest Pipfile. E.g. / foo-package Pipfile (Pipfile-A) Pipfile.lock script.py (when this file is open, use Pipfile-A for module resolution) bar-package Pipfile (Pipfile-B) Pipfile.lock script.py (when this file is open, use Pipfile-B for module resolution)

Can’t fully disable python linting Pylance VSCODE

I’ve been searching online for quite a while now and can’t seem to find a solution for my problem. I installed Pylance (the newest Microsoft interpreter for Python) and can’t seem to disable linting at all. I’ve tried a lot of options but none worked. Here’s a screenshot of how annoying linting is in my code now. Here’s how my

vscode python no output

Whatever I write in the python file, it only gives the current file path. How could I fix it? Answer I just ran this program in VS Code and it worked fine. Just right click and select ‘Run Python file in terminal’ options. It should work!

Advertisement