Skip to content

rope_autoimport doesn't initialize after workspace/didChangeConfiguration message #460

Closed
@tkrabel-db

Description

@tkrabel-db

It seems the supported way to change configurations as per the LSP is to send workspace/didChangeConfiguration, and that is what python-lsp-server supports (source).

The problem

rope_autoimport needs to create an index of the python modules, and it only does so when enabled at server startup. When enabling it dynamically at runtime, it doesn't do so. This is especially is an issue when using the memory = True setting.

One solution

I propose extending the hookspecs to add a hook pylsp_workspace_configuration_changed and to implement that hook in rope_autoimport, like this one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions