Skip to content

A language server that a plugin starts doesn't look up its command in the environment of its working directory #1888

Closed

Description

@lagergren

#1693 makes a user-defined language server and a debug adapter look up their command in the PATH of the environment of their working directory (#1660), so that the tool which the directory selects, such as its node with mise, is the one that starts. A language server that a plugin starts with its own GeneralCommandLine, through OSProcessStreamConnectionProvider or ProcessStreamConnectionProvider, doesn't get that lookup. Since IntelliJ 2025.1 its process gets the directory's environment when it starts, but its command is still looked up in the PATH given to the command line, usually the IDE's.

Possible direction

Do the lookup where LSP4IJ starts every such process, in OSProcessStreamConnectionProvider.start() for a command line with a working directory, so that the servers of plugins get it without a change on their side. Exposing the lookup as public API would be the alternative, but then each plugin has to call it.

Activity

  1. added a commit that references this issue on Nov 10, 2026
    18f9d5e
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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions