-
Notifications
You must be signed in to change notification settings - Fork 770
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
local imports not working #284
Comments
The |
Well. I renamed it to When renamed to If I change it to Also: with |
I think that this is covered by #253, then. With MPLS and Pylance, the solutions for scripts are to use extraPaths to give us hints as to where imports should be rooted. Something else would be needed in order to figure this out automatically without incurring false negatives in import resolution. |
Environment data
Problem
Given this 2 files
folder/secrets.py
folder/themain.py
It gives error on the
themain.py
because instead of using thefolder/secrets.py
, it uses a library stub.This is the error displayed on the import line:
When I go to the definition of the
secrets
module in the import line, it opens the file/home/user/.vscode/extensions/ms-python.vscode-pylance-2020.8.2/server/typeshed-fallback/stdlib/3.6/secrets.pyi
.The file runs ok, i.e., when I run
themain.py
it imports the correct file (the one in the same folder asthemain.py
.Logs
(Some paths were renamed to not expose private data)
The text was updated successfully, but these errors were encountered: