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

more detailed instructions #1

Open
russarr opened this issue Dec 12, 2023 · 4 comments
Open

more detailed instructions #1

russarr opened this issue Dec 12, 2023 · 4 comments

Comments

@russarr
Copy link

russarr commented Dec 12, 2023

Hi.
The plugin doesn't work for me.

There is Note in Readme

NOTE: In order for pyright to resolve an import, module containing it should be used in the workspace; otherwise import won't be found. Hence the auto-import feature works well in modules loaded with pre-loaded imports.

Can you give more detailed instructions how to use it? Or give link to some guides?

P.S. Pyright imports works from autocompletion menu, so somehow pyright works with imports
NVIM v0.10.0-dev-1816+g2d33a766a
OS: Windows 10 22H2

@stevanmilic
Copy link
Owner

Hi, can you provide a minimal reproducible example?

Can you give more detailed instructions how to use it? Or give link to some guides?

There's more info on microsoft/pyright#967 (comment), I can add that to the docs.

On the usage side, like noted it works well if you have a symbol you're trying to automatically import that's already imported somewhere else in the project workspace.

@russarr
Copy link
Author

russarr commented Dec 13, 2023

Pyright confugured with pyrightconfig.json

  1. I tried with the math module. Plugin message: "no unresolved import error"
math.sqrt()
  1. or select from sqlaclhemy.sql
    Plugin message: "no import found for select"
    but with authocomplete i can import it
    изображение

@stevanmilic
Copy link
Owner

@russarr that's strange, if the pyright provides an "Auto-import" option then the plugin should be able to resolve the import. Can you please post pyright version and nvim version you're using?

@UN-9BOT
Copy link

UN-9BOT commented Mar 31, 2024

image
image

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

3 participants