Skip to content

Support dynamic changes of search paths in language server #2395

Closed

Description

Environment data

  • VS Code version: 1.27.0-insiders
  • Extension version (available under the Extensions sidebar): 2018.8.0-alpha
  • OS and version: 10.14
  • Python version (& distribution if applicable, e.g. Anaconda): 3.7.0
  • Type of virtual environment used (N/A | venv | virtualenv | conda | ...): N/A
  • Relevant/affected Python packages and their versions: N/A

Actual behavior

I have a list of Python packages that are not installed in site-packages under python.autoComplete.extraPaths. Jedi uses those paths to provide completions. The new LS does not seem to recognise them. I also get IntelliSense linter warnings when importing those packages, which doesn't happen with Jedi.

Expected behavior

The LS should treat the packages under python.autoComplete.extraPaths as if they were normally installed libraries.

Activity

  1. MikhailArkhipov commented on Aug 15, 2018

    @MikhailArkhipov

    Can you provide more details on repro and what is expected? Thanks

  2. albireox commented on Aug 15, 2018

    @albireox
    Author

    Sorry, I think I talked too fast. The path for one of the packages I keep in my python.autoComplete.extraPaths had changed and although I fixed it, it seems VSCode needed to be restarted for the change to register. The LS seems to be correctly autocompleting the packages in python.autoComplete.extraPaths.

    I think this can be closed, although it would be nice if changes to python.autoComplete.extraPaths don't require a restart to take effect.

  3. MikhailArkhipov commented on Aug 15, 2018

    @MikhailArkhipov

    Ah, that is true. LS needs to be restarted when search paths change (Reload Window command is sufficient). I will rename the issue instead.

  4. changed the title [-]New LS does not respect python.autoComplete.extraPaths[/-] [+]Support dynamic changes of search paths in language server[/+] on Aug 15, 2018
  5. agerhbour commented on Nov 3, 2018

    @agerhbour

    This is actually the behaviour I am currently seeing.
    Use Jedi - packages in python.autoComplete.extraPaths have completions provided
    Use LS without changing any other settings - packages referenced in extraPaths do not have completions provided.

  6. Honzys commented on Dec 8, 2018

    @Honzys

    Hello,

    Is it possible to make this dynamic behaviour not only for searching for paths in the settings, but also for checking for any changes in tha packages specified by python.autoComplete.extraPaths? So if I do some changes in the package, the intellisense/autocomplete would mirror these updates dynamically and suggest for example for newly added modules and basically correspond to the newest version?

    This behaviour is normal in the namespace of the project (it checks any changes in the current package and updates dynamically), is it possible to extend this functionality to the packages defined in the python.autoComplete.extraPaths?

    Or just have some command to "refresh" the informations for selected packages, since the reloading whole vscode takes too long?

    I hope I made myself clear, feel free to ask any additional questions if you didn't understand me what I've meant exactly.

    Thank you very much

  7. MikhailArkhipov commented on Sep 12, 2019

    @MikhailArkhipov
  8. DonJayamanne commented on Sep 13, 2019

    @DonJayamanne

    Closing as this has been resolved upstream.

  9. locked as resolved and limited conversation to collaborators on Sep 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-intellisenseLSP-related functionality: auto-complete, docstrings, navigation, refactoring, etc.feature-requestRequest for new features or functionality

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions