-
Notifications
You must be signed in to change notification settings - Fork 155
feat(tui): show MCP server summary in welcome panel and update /mcp hints #223
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| "@moonshot-ai/kimi-code": patch | ||
| --- | ||
|
|
||
| Show MCP server summary in the welcome panel and add configuration hints in the /mcp command output. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -173,6 +173,7 @@ function createInitialAppState(input: KimiTUIStartupInput): AppState { | |
| availableModels: {}, | ||
| availableProviders: {}, | ||
| sessionTitle: null, | ||
| mcpServersSummary: null, | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
This summary is stored in shared Useful? React with 👍 / 👎. |
||
| }; | ||
| } | ||
|
|
||
|
|
@@ -1081,6 +1082,7 @@ export class KimiTUI { | |
| this.state.footer.setBackgroundCounts({ bashTasks: 0, agentTasks: 0 }); | ||
| this.streamingUI.setTodoList([]); | ||
| this.streamingUI.setTurnId(undefined); | ||
| this.setAppState({ mcpServersSummary: null }); | ||
| this.streamingUI.setStep(0); | ||
| this.streamingUI.resetLiveText(); | ||
| this.updateQueueDisplay(); | ||
|
|
||
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.
When
listMcpServers()is still in flight, a livemcp.server.statusevent can already callrenderMcpServerStatus()and populatethis.mcpServerswith the current state. This block then unconditionally clears that map and rebuilds it from the older snapshot before publishingmcpServersSummary, so the welcome panel can regress to stale counts/statuses (for example, showing a failed server after a later connected event), even though the transcript path intentionally skips rendering stale visible rows. Merge only snapshot entries that have not received a newer event, or avoid clearing live state here.Useful? React with 👍 / 👎.