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

jumping outside of current virtualenv #249

Closed
kaldown opened this issue Jan 11, 2021 · 3 comments
Closed

jumping outside of current virtualenv #249

kaldown opened this issue Jan 11, 2021 · 3 comments

Comments

@kaldown
Copy link

kaldown commented Jan 11, 2021

I have my project with

cat .vim/coc-settings.json
{
        "python.venvPath": "/home/kaldown/.cache/pypoetry/virtualenvs",
        "python.formatting.provider": "black"
}

and a file with:

# application.py
from flask.json import JSONEncoder

trying to follow definition of a JSONEncoder class it opens:

1)  /home/kaldown/.config/coc/extensions/node_modules/coc-pyright/node_modules/pyright/dist/typeshed-fallback/third_party/2and3/flask/json/__init__.pyi |6 col 7| class JSONEncoder(_json.JSONEncoder):
2)  /home/kaldown/.cache/pypoetry/virtualenvs/api-ohFkNBde-py3.9/lib/python3.9/site-packages/flask/json/__init__.py |61 col 7| class JSONEncoder(_json.JSONEncoder):

which is outside of my current virtualenv created via poetry.

Ho to restrict usage withing my my virtualenv?

@fannheyward
Copy link
Owner

The first line is pyi file which provides by Pyright, the second line is source file.

@kaldown
Copy link
Author

kaldown commented Jan 11, 2021

The first line is pyi file which provides by Pyright, the second line is source file.

Sure thing.
But I don't want to mix my project with the tools being used outside of it.

I don't think this issue should be closed.
What do you think?

@fannheyward
Copy link
Owner

It's Pyright's behavior microsoft/pyright#795 (comment)

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