Skip to content

Add support for workspace read requests#1825

Open
msujew wants to merge 1 commit into
microsoft:mainfrom
msujew:workspace-read-feature
Open

Add support for workspace read requests#1825
msujew wants to merge 1 commit into
microsoft:mainfrom
msujew:workspace-read-feature

Conversation

@msujew

@msujew msujew commented Jul 22, 2026

Copy link
Copy Markdown

Related to microsoft/language-server-protocol#1264 (does not fully resolve it, since this PR does not include features to write into a file system - only read from it).

Adds support for the server to read files/directories/stat info from the client. Allows servers to "see" any registered remote/virtual file system files/directories via means of the LSP.

As indicated by microsoft/language-server-protocol#1264 (comment), I also thought it'd be best to start with read-only access to the file system. However, the new interfaces/types should be extendable enough to also add write requests if required later on.

Some questions/considerations:

  • Right now, if the read/stat fails, the LSP returns null. Should it return a response error instead?
  • I'm not entirely sure about the properties in FileSystemClientCapabilities. Does it make sense to expose each individual request type as an opt-in flag? Or is it enough to provide a read?: boolean flag (maybe extend this with a write?: boolean flag later on)?
  • The FileType.unknown value results from the fact that vscode offers vscode.FileType.unknown as a possible value to return for FileStat.type. Should this be included in the protocol, or should stats/directory entries with this type simply be omitted?
  • The LSP has been using folder instead of directory for the most part. Should this change align to this? I've simply used the same nomenclature as vscode does.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@msujew

msujew commented Jul 22, 2026

Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

@msujew
msujew force-pushed the workspace-read-feature branch from a97888f to d0e4f81 Compare July 22, 2026 10:10
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

Successfully merging this pull request may close these issues.

1 participant