-
Notifications
You must be signed in to change notification settings - Fork 393
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
fix: call language client stop during deactivation #5217
Conversation
@@ -284,6 +284,7 @@ async function registerTestView(): Promise<vscode.Disposable> { | |||
} | |||
|
|||
export async function deactivate() { | |||
await languageClient?.stop(); |
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.
sweet. We already have a unit test suite for this class. Mind adding a unit test for the deactivate function? I'll QE in the mean time.
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.
Will do.
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.
Thanks for the quick fix!
QE passed.
Test Cases
- Verify when run via a vsix the Apex LSP exits when VSCode is shut down via the X ✅
- Verify when run via a vsix the Apex LSP exits when VSCode is shut down via quit Visual Studio Code ✅
- Verify when run via a vsix the Apex LSP exits when VSCode is shut down when running in dev mode ✅
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.
one q about the test. Good to go.
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.
🚢
This PR fixes the issue of language servers being orphaned.
This change adds a call to the language client stop function during the apex extension deactivate call.
@W-14446753@