-
Notifications
You must be signed in to change notification settings - Fork 752
Update vscode-languageclient to v10 #2049
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR updates the VS Code language client from v9 to v10.0.0-next.18 and introduces leveled logging to properly integrate with the new client version. The main motivation is that vscode-languageclient v10 treats all stderr output as errors, so the update includes adding Info/Warn/Error logging levels that map to LSP log message types.
Key Changes:
- Update vscode-languageclient to v10.0.0-next.18 (and VS Code engine to 1.106.0)
- Add leveled logging methods (Error, Warn, Info) to the Logger interface
- Create LSP-specific logger that sends log messages via LSP protocol
- Remove unused ServerOptions fields (Client, Logger)
Reviewed changes
Copilot reviewed 12 out of 13 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| package-lock.json | Updates vscode-languageclient and related dependencies to v10, adjusts dev dependency flags |
| _extension/package.json | Updates vscode-languageclient to v10.0.0-next.18 and VS Code engine to 1.106.0 |
| _extension/src/extension.ts | Changes output channels to use LogOutputChannel type with log: true option |
| _extension/src/client.ts | Updates to use LogOutputChannel and adds hint about trace log level |
| internal/project/logging/logger.go | Adds Error/Warn/Info leveled logging methods, removes Write() method |
| internal/project/logging/logtree.go | Adds Error/Warn/Info leveled logging methods, removes Write() method |
| internal/project/logging/logtree_test.go | Removes Write() from test interface |
| internal/lsp/logger.go | New LSP-specific logger that sends log messages via window/logMessage notifications |
| internal/lsp/server.go | Uses new logger, removes unused ServerOptions fields, replaces Log() calls with appropriate levels |
| internal/project/snapshot.go | Replaces Write() with Log() |
| internal/project/session.go | Replaces Write() with Log() |
| internal/lsp/lsproto/_generate/metaModelSchema.mts | Updates LSP meta model schema with new clientCapability and serverCapability fields |
| internal/lsp/lsproto/_generate/fetchModel.mts | Updates hash to fetch updated meta model from vscode-languageserver-node |
andrewbranch
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't love the changes that were pushed on us with this, but this implementation seems fairly non-disruptive
|
Alternatively, I can implement my own Probably best to acquiesce |
This has two negative effects:
But, fixes client bugs we've experienced.