[pull] main from microsoft:main#1232
Merged
Merged
Conversation
…egistration (fixes #315290) When an extension walkthrough is unregistered, the onDidChange event fires updateCategoryProgress() before the DOM is rebuilt. DOM elements still reference the removed category ID, causing a throw. Replace the throw with a graceful skip since stale DOM elements are expected during this transition. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Adopts the agent-host protocol's MessageAttachment surface so user-attached images, file references, selections, paste, prompt text, and prompt files round-trip through the agent host and into the underlying agent SDK. - Expand `_convertVariableToAttachment` in the chat-side handler to cover image, symbol, paste, promptText, promptFile, and selection variants in addition to file/directory. - On the agent host, snapshot inline `EmbeddedResource` payloads and remote `Resource` attachments to disk under `<sessionDataDir>/attachments/<uuid>/<basename>` and rewrite the action to reference them via local `file:` URIs, keeping large blobs out of the in-memory state tree. - Read remote attachment bytes through `toAgentClientUri` so the existing `vscode-agent-client` filesystem provider routes the request to the originating client. - Auto-approve `read` permission requests for any path under the session's `attachments` directory in the Copilot agent's `handlePermissionRequest`. - Translate protocol attachments back to chat-layer `IChatRequestVariableEntry`s when building history (`turnsToHistory`), the active turn synthesis, the server-initiated turn (`startServerRequest`), and the pending/queued message sync, so attachments survive history replay and pending message round-trips. - Restore SDK-side attachments in `mapSessionEvents`'s `user.message` handling so resumed sessions retain their attachments. - Forward attachments from the workbench to the SDK in `_toSdkAttachment`, mapping Resource selections to `selection`, directories to `directory`, files to `file`, and `EmbeddedResource` blobs to `blob`. Fixes #315137 (Commit message generated by Copilot)
Addresses review feedback and CI failures on the agent-host attachment support change. - Restore the `Resource` branch in `_isRewritableAttachment` (and thus in `_needsAsyncRewrite`) so non-directory `Resource` attachments not already under the session attachments folder are snapshotted, matching the PR's stated intent and the new tests. - Restore the `isSelection` gate when converting `implicit` variable entries: a bare visible-document implicit attachment should not become a `selection` attachment. - Avoid emitting `attachments: undefined` and `variableData: undefined` fields on the synced pending message actions and synthesised history entries, so the existing deep-equal test assertions keep passing. (Commit message generated by Copilot)
The single-entry sidebar 'Customizations' button had `width: 100%` set on both the link-button container and the inner button. Combined with the inherited `margin: 0 10px` from the per-section rule, this overflowed the panel by 20px and was visible as a misaligned focus outline that extended past the panel edge. Drop the explicit widths and let the parent's default `align-items: stretch` plus the inherited margins size the entry, matching the per-section items. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Reverts the manual omission of undefined `attachments` / `variableData` fields in the pending message sync and history synthesis paths. Updates the corresponding deep-equal test assertions to expect the new shape instead. (Commit message generated by Copilot)
…#315319) The 'Bridged' badge that appeared next to MCP server names in the chat customizations editor has been removed. This badge was shown when the active harness was not Local, indicating the server was forwarded to agent sessions. It is no longer needed. - Remove the bridgedBadge DOM element, hover tooltip, and autorun from McpServerItemRenderer - Remove bridgedBadge from IMcpServerItemTemplateData - Remove ICustomizationHarnessService injection from McpServerItemRenderer - Simplify the accessibility aria label (no longer appends 'Bridged') - Remove unused ICustomizationHarnessService injection from McpListWidget - Remove unused derived and SessionType imports from mcpListWidget.ts - Update CSS comment referencing the Bridged badge - Update AI_CUSTOMIZATIONS.md to remove reference to the Bridged badge Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
On reload, the agents window now restores the last active session instead of showing the new-session view. - Add `restoreLastActiveSession()` to `ISessionsManagementService` and call it from `Workbench.restore()` during startup. - Switch away from the new-session view synchronously (before any await) to prevent `NewChatViewPane` from rendering and accidentally cancelling the restore token via `createNewSession`. - Wait for the session provider to register if the session isn't available immediately, then delegate to `_doOpenSession`. - Show a progress indicator on `ChatViewId` during restore (200ms delay to avoid flicker on fast restores); cancel it immediately if the user navigates to the new-session view. - `_startOpenSession` cancels any in-flight open/restore and returns a fresh token; all navigation paths (openSession, openChat, createNewSession, openNewSessionView, openNewChatInSession) now call it so concurrent operations are safely cancelled. - Fire `_onDidOpenNewSessionView` in `openNewSessionView` so the restore progress promise can race against it and dismiss early. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Items that come from the 'vscode-synced-customization' scheme are backed by a synthetic plugin that is purely an implementation detail of the sync mechanism. Showing 'Show Plugin' and 'Uninstall Plugin' context menu actions for those items is confusing because the plugin concept is not user-facing in that context. Tighten WHEN_ITEM_IS_PLUGIN to also require that the plugin URI does NOT start with the 'vscode-synced-customization:' scheme, so all three plugin-related menu items (inline trash icon, 'Uninstall Plugin', and 'Show Plugin') are suppressed for synced customization entries. Fixes: #314879 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add proposal for custom editor diff/merge priority
* agentHost: support image and blob user-message attachments Adopts the agent-host protocol's MessageAttachment surface so user-attached images, file references, selections, paste, prompt text, and prompt files round-trip through the agent host and into the underlying agent SDK. - Expand `_convertVariableToAttachment` in the chat-side handler to cover image, symbol, paste, promptText, promptFile, and selection variants in addition to file/directory. - On the agent host, snapshot inline `EmbeddedResource` payloads and remote `Resource` attachments to disk under `<sessionDataDir>/attachments/<uuid>/<basename>` and rewrite the action to reference them via local `file:` URIs, keeping large blobs out of the in-memory state tree. - Read remote attachment bytes through `toAgentClientUri` so the existing `vscode-agent-client` filesystem provider routes the request to the originating client. - Auto-approve `read` permission requests for any path under the session's `attachments` directory in the Copilot agent's `handlePermissionRequest`. - Translate protocol attachments back to chat-layer `IChatRequestVariableEntry`s when building history (`turnsToHistory`), the active turn synthesis, the server-initiated turn (`startServerRequest`), and the pending/queued message sync, so attachments survive history replay and pending message round-trips. - Restore SDK-side attachments in `mapSessionEvents`'s `user.message` handling so resumed sessions retain their attachments. - Forward attachments from the workbench to the SDK in `_toSdkAttachment`, mapping Resource selections to `selection`, directories to `directory`, files to `file`, and `EmbeddedResource` blobs to `blob`. Fixes #315137 (Commit message generated by Copilot) * agentHost: rewrite Resource attachments and omit undefined fields Addresses review feedback and CI failures on the agent-host attachment support change. - Restore the `Resource` branch in `_isRewritableAttachment` (and thus in `_needsAsyncRewrite`) so non-directory `Resource` attachments not already under the session attachments folder are snapshotted, matching the PR's stated intent and the new tests. - Restore the `isSelection` gate when converting `implicit` variable entries: a bare visible-document implicit attachment should not become a `selection` attachment. - Avoid emitting `attachments: undefined` and `variableData: undefined` fields on the synced pending message actions and synthesised history entries, so the existing deep-equal test assertions keep passing. (Commit message generated by Copilot) * agentHost: revert undefined-field omission, update tests instead Reverts the manual omission of undefined `attachments` / `variableData` fields in the pending message sync and history synthesis paths. Updates the corresponding deep-equal test assertions to expect the new shape instead. (Commit message generated by Copilot)
…he same ws (#315308) * broaden definition of effectively empty * allow other files when same ws is selected
Lets dashboards scope run_in_terminal invocation counts to sessions where chat.tools.compressOutput.enabled is on, so we can compute an accurate compression-rate (compressed / eligible invocations). Co-authored-by: Megan Rogge <meganrogge@Megans-MacBook-Pro.local>
* chat: gate agent host input completions on trigger characters Agent host completion providers were re-invoking `provideChatInputCompletions` on every keystroke, producing one RPC round-trip per character typed because Monaco still consults the provider for filtering / incomplete-result refresh even when the user isn't editing a trigger-led token. - Adds `isAtTriggerCharacterToken` helper in `chatInputCompletionUtils.ts` that returns true only when the cursor sits inside a non-empty token whose first char is one of the host-announced trigger characters. - Wires the gate into both agent host completion providers (workbench chat widget + sessions new-chat input) so the host RPC is only dispatched when the user is actively editing a `@`/`#`/... led token. - Extracts a small `AgentHostInputCompletionsBase` template-method base class that owns the shared plumbing (trigger-char gate, RPC dispatch, range computation, Monaco provider registration). Concrete subclasses now only supply `_resolveContext` (how to find the active session resource for a model) and `_buildItem` (how to build the Monaco completion item + accept command), keeping the registration lifecycle policy in each subclass. (Commit message generated by Copilot) * chat: address Copilot review on agent host completions - Restore the per-scheme match in `AgentHostInputCompletions._resolveContext` by threading the registered scheme through `_registerProvider` as a new `TRegData` generic on `AgentHostInputCompletionsBase`. Without this, multiple agent-host providers sharing trigger characters (e.g. both register `@`) would all fire on a single keystroke and produce duplicate RPCs / suggestions. - Mirror the same scheme-match in the sessions handler so a stale registration (active session changed during the host RPC handshake) silently no-ops instead of querying the wrong host. - Add focused unit tests for the new `isAtTriggerCharacterToken` helper covering start-of-line, mid-line, cursor-in-token, cursor-after-token, cursor-after-whitespace, non-trigger-led tokens, and the empty trigger-list case. (Commit message generated by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Add AHP transport JSONL logging Log AHP JSON-RPC frames at the transport boundary to per-connection JSONL files under the VS Code logs directory, with root-level metadata for direction, timestamp, connection id, transport, and byte length. Add focused tests for canonical JSONL shape and bounded rotation. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Address code review feedback - Truncate connectionId to 64 chars to avoid filesystem filename length limits - Memoize folder creation to avoid repeated filesystem calls per log line - Use specific transport labels: 'tunnel' for tunnel relay, 'ssh' for SSH relay Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Use IInstantiationService for WebSocketClientTransport - Inject IFileService and ILogService via @-decorators - Accept IAhpJsonlLoggerOptions instead of pre-built logger - Build the AHP logger internally inside the transport - Use createInstance at the call site - Drop now-unused IFileService dependency from RemoteAgentHostService Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Use IInstantiationService for AhpJsonlLogger Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Gate AHP JSONL logging on setting; export JSONL files instead of IPC traffic channel Adds the chat.agentHost.ahpJsonlLoggingEnabled setting (default on for non-stable builds) that controls whether the AHP transport writes JSONL logs for remote agent host connections. The export-debug-logs action now includes every <logsHome>/ahp/*.jsonl file in place of the per-connection `agenthost.<clientId>` IPC traffic output channel. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Fix RemoteAgentHostService tests after AHP logging refactor Stub IEnvironmentService and route the new createInstance(WebSocketClientTransport) call to a no-op MockTransport so createdClients only tracks RemoteAgentHostProtocolClient instances. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Server p95 is ~600ms; 1s timeout has no margin for network RTT and tail latency. Hydra rollout amplified ~6K -> 50K routerTimeouts/day. 2.5s gives ~4x headroom over server p95.
Fix build break: coerce IChatInputNotification.message to string for ARIA announce
…iles view (#315346) * Agents - add "Sync Changes" action to the new session screen in the Files view * Pull request feedback --------- Co-authored-by: Dmitriy Vasyura <dmitriv@microsoft.com>
* sessions: address Copilot review feedback on session restore - Call tryRestore() immediately after registering listeners to fix race condition where session becomes available between initial getSession check and listener registration - Use Event.toPromise() instead of manual listener in Promise.race to avoid stale subscription when restorePromise wins the race - Add void + .catch() on restoreLastActiveSession() call in workbench.ts to handle unhandled promise rejection at startup Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
* Refactor browser element selection to be event-based * comment Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Bump auto-mode router decision timeout from 1s to 2.5s
…und-315290-0c946c239ac8fc57 fix: skip stale category-progress DOM elements in welcome page (fixes #315290)
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )