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

pylint reports E0401:import error for the mido library #556

Closed
ReddyKilowatt opened this issue May 19, 2024 · 4 comments
Closed

pylint reports E0401:import error for the mido library #556

ReddyKilowatt opened this issue May 19, 2024 · 4 comments
Labels
bug Issue identified by VS Code Team member as probable bug triage-needed Issue is not triaged.

Comments

@ReddyKilowatt
Copy link

pylint_bug.txt

@ReddyKilowatt ReddyKilowatt added the bug Issue identified by VS Code Team member as probable bug label May 19, 2024
@github-actions github-actions bot added the triage-needed Issue is not triaged. label May 19, 2024
@ReddyKilowatt
Copy link
Author

Why does this website ask for trace files that are too long to paste into bug reports???????????????????????????

@ReddyKilowatt
Copy link
Author

It looks like my venv was the problem.
Somehow, the packages I installed into the venv (yes, it was activated) were installed in the global python env.

@karthiknadig
Copy link
Member

karthiknadig commented May 20, 2024

Somehow, the packages I installed into the venv (yes, it was activated) were installed in the global python env.

This can happen if you run pip install vs python -m pip install. See here for more details: https://snarky.ca/why-you-should-use-python-m-pip/

@ReddyKilowatt
Copy link
Author

ReddyKilowatt commented May 20, 2024

@karthiknadig I know about python -m pip install xxx
After I discovered the problem, I had tried adding more packages to the venv, but they still went to the global python.
(the venv was activated, and I was using python -m pip install xxx).

I have never had this problem with Python on Windows until now. I ended up deleting the venv, and Python, and reinstalling Python for all users, so that it doesn't get installed in my user directory (Appdata ....)
Now, the venv seems to work much better, and vscode is able to resolve most python symbols/objects now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue identified by VS Code Team member as probable bug triage-needed Issue is not triaged.
Projects
None yet
Development

No branches or pull requests

2 participants