forked from lastmile-ai/aiconfig
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[2/n] Support Restarting Editor Server
# [2/n] Support Restarting Editor Server Add an "AIConfig: Restart Active Editor Server" command so that users can restart the server for the active (in-view) editor. As part of this, implement the restart functionality for the EditorServer so that the server process is killed and a new one is started, ensuring the associated extension/webview is properly updated to associate with the new server process. As best effort, also implement an `onDidChangeState` so that we can listen to the editor server status changing and show a progress notification that the server is starting. This logic will be leveraged in subsequent PR to handle restarting all editor servers when the workspace python interpreter changes. https://github.com/lastmile-ai/aiconfig/assets/5060851/39739008-abc7-4538-9087-42972c1400aa Note: The server heartbeat banner shows when restarting because of the existing server status request failing. This should be fixed by lastmile-ai#1325 ## Testing: - Restart server and ensure (via logging) that the old one is killed and new one is set up, ensuring prompts run in new one - Close webview and ensure the server is killed - Activate restart server command and toggle away then back to webview, ensure it's in readonly until it starts up and becomes editable again when toggle back
- Loading branch information
Ryan Holinshead
committed
Feb 23, 2024
1 parent
b395d22
commit e11e1a6
Showing
5 changed files
with
223 additions
and
82 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.