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

relative imports not handled #58

Closed
klix2 opened this issue Apr 5, 2019 · 2 comments
Closed

relative imports not handled #58

klix2 opened this issue Apr 5, 2019 · 2 comments

Comments

@klix2
Copy link

klix2 commented Apr 5, 2019

relative imports within a package get flagged as import could not be resolved
from .test1 import a

to reproduce
you need:
a package directory containing 2 python files:
test2.py

a=1

test1.py

from .test2 import a

-> gets flagged as import could not be resolved by pyright

pyright 1.08 as extension of vscode

python 3.7 from anaconda distribution on windows 10
i have added the files to reproduce the issue

test.zip

@erictraut
Copy link
Collaborator

I think I've found and addressed this problem. The fix will be in the next published version (1.0.9).

@erictraut
Copy link
Collaborator

This is fixed in 1.0.9, which I just published. Thanks again for the bug report.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants