Agent Host: Export debug logs for the active chat - #332067
Draft
roblourens wants to merge 5 commits into
Draft
Conversation
Skip unavailable supplementary log sources and remove the debug-log byte limit while retaining manifest and entry-count validation.\n\n(Written by Copilot)\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Route debug-log collection to the selected default, peer, side, or subagent chat while preserving session ownership and host-wide fallback behavior.\n\n(Written by Copilot)\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Routes Agent Host debug-log exports to the active chat while incorporating the stacked best-effort ZIP changes.
Changes:
- Propagates active chat identity through the debug-log protocol and services.
- Selects the correct Copilot SDK chat, including subagents.
- Removes size limits and skips unavailable supplementary files during ZIP creation.
Show a summary per file
| File | Description |
|---|---|
src/vs/workbench/services/agentHost/browser/editorRemoteAgentHostServiceClient.ts |
Forwards chat identity remotely. |
src/vs/workbench/contrib/chat/test/browser/exportAgentHostDebugLogs.test.ts |
Tests chat URI conversion. |
src/vs/workbench/contrib/chat/electron-browser/actions/exportAgentHostDebugLogsService.ts |
Enables best-effort, unbounded export. |
src/vs/workbench/contrib/chat/browser/actions/exportAgentHostDebugLogsAction.ts |
Selects the active chat for export. |
src/vs/sessions/contrib/providers/agentHost/browser/exportDebugLogsAction.ts |
Reads the active Sessions chat. |
src/vs/platform/native/electron-main/nativeHostMainService.ts |
Handles optional size limits and unavailable files. |
src/vs/platform/native/common/native.ts |
Extends native ZIP contracts. |
src/vs/platform/agentHost/test/node/protocolServerHandler.test.ts |
Tests protocol chat validation. |
src/vs/platform/agentHost/test/node/copilotAgent.test.ts |
Tests peer-chat log routing. |
src/vs/platform/agentHost/test/node/agentHostDebugLogs.test.ts |
Tests chat forwarding and large artifacts. |
src/vs/platform/agentHost/test/electron-browser/agentHostProtocolClient.test.ts |
Tests client requests and large manifests. |
src/vs/platform/agentHost/node/protocolServerHandler.ts |
Validates and forwards chat URIs. |
src/vs/platform/agentHost/node/copilot/copilotAgent.ts |
Targets the selected SDK chat. |
src/vs/platform/agentHost/node/agentService.ts |
Resolves provider chat routing. |
src/vs/platform/agentHost/node/agentHostManagementService.ts |
Forwards chat identity. |
src/vs/platform/agentHost/node/agentHostDebugLogs.ts |
Passes chat context to providers. |
src/vs/platform/agentHost/electron-browser/localAgentHostService.ts |
Forwards local chat identity. |
src/vs/platform/agentHost/common/state/sessionState.ts |
Adds chat-ID URI construction. |
src/vs/platform/agentHost/common/agentService.ts |
Extends debug-log service APIs. |
src/vs/platform/agentHost/common/agentHostExtensionProtocol.ts |
Adds the optional protocol chat field. |
src/vs/platform/agentHost/common/agent.ts |
Extends provider diagnostics API. |
src/vs/platform/agentHost/browser/nullAgentHostService.ts |
Updates the null implementation. |
src/vs/platform/agentHost/browser/agentHostProtocolClient.ts |
Sends chat identity and accepts large artifacts. |
src/vs/base/test/node/zip/zip.test.ts |
Tests best-effort ZIP behavior. |
src/vs/base/node/zip.ts |
Supports optional size validation and skipped sources. |
Review details
💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
- Files reviewed: 25/25 changed files
- Comments generated: 2
- Review effort level: Balanced
Use host-published chat resources and cover subagent-to-parent debug-log routing. (Written by Copilot) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Resolve the stacked branch after the prerequisite debug-log export PR merged.\n\n(Written by Copilot)\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Define the debug-log extension request with the shared validation library and leave semantic URI checks in the protocol handler.\n\n(Written by Copilot)\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Mohammad javad Dianat (dianatofficial)
left a comment
There was a problem hiding this comment.
Well done. The optimization reduces unnecessary allocations.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
events.jsonland shell logs from that selected SDK chat instead of always collecting the default chatStack
Builds on #332062, which has merged. The active-chat implementation is contained in commits
62bd134d683and6aa2662243c;d97fa5aebeemerges the updatedmain.Validation
npm run typecheck-client(Written by Copilot)