Skip to content

agentHost: migrate to Microsoft Copilot SDK v2 - #348894

Merged
Connor Peet (connor4312) merged 7 commits into
mainfrom
roblou/agents/update-copilot-sdk-to-v2
Nov 18, 2026
Merged

Connor Peet (connor4312) merged 7 commits into
mainfrom
roblou/agents/update-copilot-sdk-to-v2

Conversation

@roblourens

@roblourens roblourens commented Nov 17, 2026 •

Copy link
Copy Markdown
Member

Migrate Agent Host from @github/[email protected] / runtime 1.0.111-0 to @microsoft/[email protected] / runtime 1.0.113-1.

Latest conflict resolution: d3f13f2698e3aad26940115bd40186f5a9879831 merges main through c0b608a6e82bf47e202987c918913fd4a6deb748. It preserves upstream Canvas extension-data sandbox grants through SDK v2's grouped extension and permission options, with create/resume regressions for enabled and disabled extensions. The preceding merge also preserves upstream subagent chat links, the shared Connector fixture, and MCP diagnostics while retaining spawned SDK v2 clients. No SDK/runtime versions, permission assertions, or generated baselines changed. The older revision-specific results below remain historical. (Written by Copilot)

V2 defaults to hosting the native runtime in-process. VS Code deliberately retains a separate runtime process using runtime: RuntimeConnection.forSpawnedStdio(...), including scoped clients, certificate commands, and direct SDK tests. Storage-only clients remain in empty mode; ordinary coding clients explicitly select the renamed coding-agent mode.

Local tests, GitHub CI, and both Azure SDK Validation builds passed for 59323a1838e7e7ab34b4f08294c6b1ab74db01a2. The subsequent conflict-resolution merge is 0fcfcdff1cd4d7313bf7deef1c81e7c6e415a066; its client type-check, lint/hygiene, 3,358 owning unit tests (1 existing pending), and 2 native account/restart integration tests passed. GitHub CI for that new revision is pending; the earlier full GitHub/Azure results below are historical, not final-SHA results for the merge. Validation gap: the four full-app Linux DEB/RPM dependency-reference checks were not run. The SDK-only native dependency comparisons passed, but they are not a substitute for the full-app check.

The follow-up merge preserves main's missing-plugin-directory filtering in v2's plugins.directories, reopened Microsoft session sign-in, and read-only legacy history recovery. The newly added recovery helper uses the renamed SDK types and retains validated v1 parentToolCallId fields for old saved journals without treating them as current live-event fields. No SDK/runtime versions, permission assertions, or generated baselines changed during conflict resolution.

Change ledger

Files/surface Exact change Why necessary Assessment
Root/remote package.json, pnpm-lock.yaml, pnpm-workspace.yaml (6 files) Rename the SDK and its eight optional platform packages, pin SDK 2.0.0-preview.2 and runtime 1.0.113-1, and extend the existing Copilot release-age exception to the renamed SDK family. Both locks retain SHA-512 pins without explicit SDK tarball URLs. Desktop and remote must bundle the same release; the existing package-age exception must follow the package rename. Expected upgrade; unrelated dependency resolutions are preserved.
build/.moduleignore, build/darwin/create-universal-app.ts, build/lib/copilot.ts, build/lib/test/copilot.test.ts (4 files) Resolve/cross-copy SDK assets under @microsoft, retain the selected architecture's runtime, preserve optional-payload exclusions and standalone-CLI exclusions, and keep Koffi excluded because the runtime remains out-of-process. Renaming imports alone would omit the shipped runtime or break cross-architecture packaging. Expected packaging adaptation.
cglicenses.json Rename the SDK license override and point it to the new public Microsoft SDK repository's MIT license. The npm archive still omits the license file. Expected attribution adaptation.
copilotAccountService.ts, copilotAgent.ts, copilotAgentSession.ts, copilotGitHubCredentials.ts, copilotMcpSkillConsent.ts, copilotPromptAttribution.ts, copilotRuntimePaths.ts, copilotSandboxCertificateCli.ts, copilotSessionLauncher.ts, copilotSessionWrapper.ts, mapSessionEvents.ts (11 files under src/vs/platform/agentHost/node/copilot) Migrate client/session options and mutable RPC payloads into v2's groups; preserve nested siblings on create/resume/retry; retain credential exclusivity, policy injection, sandbox settings, tool filters, telemetry and callbacks. Use agentId for live subagent attribution and append-only tool.shell_output events instead of the removed cumulative event. Read legacy transcript attribution through the existing guarded property reader. V2 removes the old flat API and deprecated live events; saved v1 transcripts still need to restore correctly. Expected compatibility adaptation; no permission or approval assertions removed.
29 SDK-owning unit/direct-provider/E2E test and helper files under src/vs/platform/agentHost/test/node Update typed mocks, option projections, embedded extension programs, mandatory modes, canonical billing fields and explicit named BYOK routing. Assert spawned-stdio options at the test boundary. Migrate shell-output cases to sequenced chunks while retaining output, artifact, cleanup and duplicate-chunk assertions; migrate live child-usage cases to envelope attribution. Tests must exercise the real v2 API rather than silently pass retired option names through JavaScript or partial mocks. Expected test adaptations; existing credential/platform gates remain.
One generated snapshot: test/node/__snapshots__/Copilot_SDK_-_managed_settings_bundled_managedSettings_schema_matches_the_snapshot.schema.json Add features.browserUse and its deny-wins description; update the feature-map description to cover the new native MDM leaf. Generated with the supported tokenless update flag, then tested strictly. Runtime-owned managed-settings schema expansion. Reviewed expected schema addition; no broad baseline refresh.
src/vs/platform/agentHost/AGENTS.md, src/vs/platform/agentHost/node/copilot/copilotBuiltinSkills.ts (2 files) Document the new SDK identity/types and teach Agent Host troubleshooting to join envelope agentId to subagent.started.data.toolCallId, retaining the deprecated field only for old logs. Agent Host-owned guidance must describe the API and event attribution it actually runs. Expected documentation adaptation. The standalone CLI's create-canvas skill and its test are unchanged: that CLI bundles its own v1 SDK and its authoring skill does not target Agent Host sessions. Existing user-authored v1 Agent Host extensions may need import/options migration.
src/vs/platform/dialogs/test/electron-browser/dialog.test.ts Select both the standalone CLI and renamed SDK About-dialog lines explicitly. CI found that the old shared test selector discarded the correctly renamed SDK line before comparing version-formatting results. Expected test adaptation; all 12 owning cases pass, and the final GitHub workflow passes.
104 remaining files (listed below) Exact @github/copilot-sdk to @microsoft/copilot-sdk reference replacements only: imports/types, SDK paths, packaging/signing filters, canary configuration, documentation, and associated tests. All consumers must resolve the renamed package, including platform packaging and canary tooling. The standalone @github/copilot CLI name is unchanged. Mechanical identity migration only.

The full 24-case model prompt matrix passes without prompt baseline changes. No model-set or tool-inventory snapshot was regenerated. The separately maintained upgrade skill and portable-lock helper were also migrated locally; their helper tests pass, but those user-level files are not part of this repository diff.

Acceptance status

The detailed acceptance snapshot below applies to revision 59323a1838e7e7ab34b4f08294c6b1ab74db01a2, which merged main through fc08017c2e82db30a3196c86bcdb46a283e18b37. Affected types, owning unit suites, focused integrations, the complete deterministic runner, and supplemental acceptance were rerun after that merge. The documentation ownership correction was checked with the owning Agent Host and standalone CLI skill suites. The follow-up merge through 06bea887795fc42064969eb06b524ad0d02f2781 and its newer focused validation are described above. Local results below are macOS arm64 unless stated otherwise; counts from overlapping selections are not additive.

The pre-follow-up merge-base inventory accounts for 159 files: 104 exact package-reference-only replacements and 55 substantive/configuration/test/documentation files in the ledger above. The conflict-resolution merge additionally adapts the new upstream copilotSessionHistoryRecovery.ts helper as described above. Upstream changes brought in by either merge are not themselves SDK changes.

  • Root/remote frozen install and portable nine-package SDK resolution verification passed. Canonical npm was unreachable locally; lock generation used the configured mirror, preserving integrity verification and removing only SDK mirror URL overrides.
  • Client and build-tool type checks, layer checks, packaging/canary/universal-app helper tests (36), and commit hygiene passed.
  • All direct copilotSdk* integration entrypoints: 38 passed in the standalone batch. Initial discovery had four canvas failures caused by embedded extensions still using flat v1 options, plus the expected managed-schema difference; the complete strict batch subsequently passed. After the main merge, the combined SDK/prompt/native-account selection passed 62 tests. The explicit native-account restart selection also passed 2 tests, including the actual restart scenario.
  • Full Copilot prompt matrix: 24 passed, no baseline changes; included again in the post-merge combined selection.
  • SDK-owning lifecycle/adaptation unit batch: 3,372 passed, 1 existing pending before the merge. The first run exposed obsolete typed mock/expected option shapes; the complete batch passed after migration. The affected post-merge lifecycle/account/worktree selection passed 3,253 tests, 1 existing pending. The final Agent Host skill/launcher selection passed 251 tests, the unchanged standalone CLI skill selection passed 3 tests, and the About-dialog suite passed 12 tests.
  • Complete deterministic runner, Full profile: 1,001 passed, 106 existing pending. All 10 suite/shard summaries passed: Copilot, Conformance, Claude and Codex each have two shards, plus native Copilot OTel and managed settings. These are shards, not repeated executions. The actual default concurrency was 10 workers.
  • Remaining supplemental batch: 118 passed, 7 existing pending, covering every synthetic-provider entrypoint plus Entra transport and the gated live Codex entrypoint. Together with the separate SDK contracts and prompt matrix, this accounts for all 30 supplemental entrypoints discovered by the inventory.
  • Final-revision GitHub workflows passed: Code OSS, Component Fixtures, and CodeQL.
  • Native preflight: all 16 baseline/candidate platform archives match their committed SHA-512 pins; no paths were added or removed across the eight platform packages. Linux x64/arm64 ELF loader and symbol requirements and all 24 Windows x64/arm64 PE import/OS-header inspections are unchanged. All 20 inspected baseline/candidate macOS native signatures verify, with unchanged dylib imports and signing Team ID. The runtime/native macOS deployment floor decreases from 14.0 to 13.0; this is not the entire SDK's minimum because unchanged OneAuth libraries have their own deployment floors.
  • A separate native SDK probe, using an isolated synthetic local model and real loopback collector with default scheduling, verified actual session-correlated spans, disabled content capture, resource identity, and pre-batch shutdown draining. Observed first export was about 9.9 seconds after turn completion; the second session had no exported span before stop and its spans arrived on stop. This is native SDK evidence, not a packaged Agent Host production-latency claim. Existing packaged routing/warm-policy E2E assertions remain separate.
  • SDK Validation definition 720 passed, builds 498243 and 498244, both verified against the exact final revision with default architecture parameters and no SDK/runtime canary overrides. Both overall builds succeeded, all seven desktop architectures compiled, and the actual Agent Host E2E task succeeded on Windows x64, Linux x64, and macOS arm64 in both builds. This checkout has no E2E repeat support, so these are two fresh builds rather than checkpointed job retries. Superseded builds 498222, 498223, 498224, 498238, and 498239 were canceled as revisions changed and are not acceptance evidence.
  • Not run: all four full-app Linux dependency-reference checks (x64/arm64 × DEB/RPM). Final-source application-artifact downloads encountered repeated TLS resets and timeouts. Replacement streaming transfers were stopped before completion; no application assembly completed and none of these checks ran. The SDK-only native comparisons above passed, but no full-app dependency-reference result is claimed.
  • Targeted RPM reference check passed on x64 and arm64. Ran the repository's build/linux/rpm/calculate-deps.ts helper against the integrity-verified baseline and candidate SDK runtime.node and copilot-runtime files in a Linux Docker container, applying the full generator's bundled-library exclusions. Both architectures have no added or removed RPM requirements and none absent from build/linux/rpm/dep-lists.ts. The SDK upgrade therefore introduces no RPM reference-list additions. This uses actual RPM find-requires, not only a symbol-version scan; it does not establish full-app list equality or Debian dependency metadata.
  • Download retries: transient registry/API transport failures were retried without product changes. The container's VS Code sysroot downloads timed out; the exact official archives were fetched through the host, verified against the unchanged checked-in SHA-256 pins, and used to warm task-owned helper caches. The repository sysroot helpers then succeeded, but this was preparation, not execution of the full-app checks. Azure ArtifactTool retries failed; replacement authenticated streaming ZIP transfers were stopped before completion. No dependency-reference lists, comparison guards, or integrity checks were weakened.

Pipeline 720 covers Windows x64/arm64, Linux x64/arm64/armhf, macOS x64/arm64 compilation and Windows x64/Linux x64/macOS arm64 Agent Host E2E. macOS E2E uses a separate CI-mode build. It is not a full Product validation: distribution-package generation, signing, Alpine, Web, universal macOS, and full artifact-sanity coverage are excluded.

No new known-issue gates or assertion relaxations are introduced. Existing live-only, credentialed, provider/platform skips and accountable expected failures remain; see src/vs/platform/agentHost/test/node/e2e/KNOWN_ISSUES.md. Replay results are not live-model behavioral proof. The actual Azure E2E results are identical across the two fresh builds:

Platform Build 498243 Build 498244 Execution
Windows x64 967 passed, 140 existing pending 967 passed, 140 existing pending Full deterministic selection, all 10 suite/shard summaries passed.
Linux x64 1,019 passed, 106 existing pending 1,019 passed, 106 existing pending 1,001-test full tmpfs selection plus 18 required disk-backed persistence tests; both storage passes succeeded. The disk subset is not counted as another complete execution.
macOS arm64 1,001 passed, 106 existing pending 1,001 passed, 106 existing pending Separate CI-mode build, full deterministic selection, all 10 suite/shard summaries passed.

The local complete-runner command was AGENT_HOST_TEST_PROFILE=full pnpm run test-agent-host-e2e (passed, 1,001 tests / 106 existing pending). The four full-app Linux dependency checks were not run; no installer-build, installation, or signing results are claimed.

104 package-reference-only files
  • .github/skills/agent-host-e2e-tests/SKILL.md
  • .github/skills/flaky-smoke-tests/SKILL.md
  • .github/skills/otel/SKILL.md
  • .github/skills/smoke-tests/SKILL.md
  • build/azure-pipelines/common/apply-sdk-canary-override.ts
  • build/azure-pipelines/common/apply-sdk-canary.yml
  • build/azure-pipelines/linux/build-snap.sh
  • build/azure-pipelines/product-build-ado-ci.yml
  • build/azure-pipelines/product-build.yml
  • build/azure-pipelines/sdk-validation-build.yml
  • build/darwin/verify-macho.ts
  • build/gulpfile.vscode.ts
  • build/lib/test/applySdkCanaryOverride.test.ts
  • build/lib/test/universalApp.test.ts
  • eslint.config.js
  • resources/linux/snap/snapcraft.yaml
  • src/vs/platform/agentHost/common/otel/agentHostOTelService.ts
  • src/vs/platform/agentHost/node/agentHostGitHubTelemetryRouter.ts
  • src/vs/platform/agentHost/node/copilot/buildSessionEvents.ts
  • src/vs/platform/agentHost/node/copilot/copilotAccountModelCatalog.ts
  • src/vs/platform/agentHost/node/copilot/copilotApprovalPolicy.ts
  • src/vs/platform/agentHost/node/copilot/copilotBuiltinAgents.ts
  • src/vs/platform/agentHost/node/copilot/copilotComputerUseActivationTool.ts
  • src/vs/platform/agentHost/node/copilot/copilotComputerUsePermissionSetup.ts
  • src/vs/platform/agentHost/node/copilot/copilotConnectors.ts
  • src/vs/platform/agentHost/node/copilot/copilotCustomizationCommandDisplay.ts
  • src/vs/platform/agentHost/node/copilot/copilotEntraAuthentication.ts
  • src/vs/platform/agentHost/node/copilot/copilotExtensionTools.ts
  • src/vs/platform/agentHost/node/copilot/copilotFailureTelemetry.ts
  • src/vs/platform/agentHost/node/copilot/copilotFusionEventIdentity.ts
  • src/vs/platform/agentHost/node/copilot/copilotFusionMessageChunks.ts
  • src/vs/platform/agentHost/node/copilot/copilotFusionPhaseTelemetry.ts
  • src/vs/platform/agentHost/node/copilot/copilotFusionProgress.ts
  • src/vs/platform/agentHost/node/copilot/copilotFusionReplay.ts
  • src/vs/platform/agentHost/node/copilot/copilotGitHubTelemetryForwarder.ts
  • src/vs/platform/agentHost/node/copilot/copilotGrepSearchNudge.ts
  • src/vs/platform/agentHost/node/copilot/copilotManagedModelConfiguration.ts
  • src/vs/platform/agentHost/node/copilot/copilotManagedSettings.ts
  • src/vs/platform/agentHost/node/copilot/copilotMessageSource.ts
  • src/vs/platform/agentHost/node/copilot/copilotModelRouterTools.ts
  • src/vs/platform/agentHost/node/copilot/copilotPermissionAttribution.ts
  • src/vs/platform/agentHost/node/copilot/copilotPluginConverters.ts
  • src/vs/platform/agentHost/node/copilot/copilotSandboxCertificate.ts
  • src/vs/platform/agentHost/node/copilot/copilotSandboxDiagnostics.ts
  • src/vs/platform/agentHost/node/copilot/copilotSandboxPolicy.ts
  • src/vs/platform/agentHost/node/copilot/copilotSdkMeta.ts
  • src/vs/platform/agentHost/node/copilot/copilotSecondaryAssignmentContext.ts
  • src/vs/platform/agentHost/node/copilot/copilotSessionHistory.ts
  • src/vs/platform/agentHost/node/copilot/copilotSessionSandbox.ts
  • src/vs/platform/agentHost/node/copilot/copilotShellTools.ts
  • src/vs/platform/agentHost/node/copilot/copilotSlashCommand.ts
  • src/vs/platform/agentHost/node/copilot/copilotSystemNotification.ts
  • src/vs/platform/agentHost/node/copilot/copilotToolDisplay.ts
  • src/vs/platform/agentHost/node/copilot/copilotVirtualSearchTools.ts
  • src/vs/platform/agentHost/node/copilot/copilotVirtualSessionFs.ts
  • src/vs/platform/agentHost/node/copilot/customizations/copilotCustomizationInstallations.ts
  • src/vs/platform/agentHost/node/copilot/localModelBridge/localModelProvider.ts
  • src/vs/platform/agentHost/node/copilot/localModelBridge/shim/copilotRequestHandler.ts
  • src/vs/platform/agentHost/node/copilot/localModelBridge/shim/requestRouter.ts
  • src/vs/platform/agentHost/node/copilot/localModelBridge/shim/shimLocalModelProvider.ts
  • src/vs/platform/agentHost/node/copilot/prompts/anthropicPrompt.ts
  • src/vs/platform/agentHost/node/copilot/prompts/openaiPrompt.ts
  • src/vs/platform/agentHost/node/copilot/prompts/promptOverride.ts
  • src/vs/platform/agentHost/node/copilot/prompts/promptRegistry.ts
  • src/vs/platform/agentHost/node/copilot/prompts/systemMessage.ts
  • src/vs/platform/agentHost/node/copilot/prompts/toolInstructions.ts
  • src/vs/platform/agentHost/node/copilot/sessionCustomizationDiscovery.ts
  • src/vs/platform/agentHost/node/otel/agentHostOTelService.ts
  • src/vs/platform/agentHost/node/shared/editChunkExtractor.ts
  • src/vs/platform/agentHost/test/node/agentHostGitHubTelemetryRouter.test.ts
  • src/vs/platform/agentHost/test/node/agentHostPromptOverride.test.ts
  • src/vs/platform/agentHost/test/node/agentHostPromptRegistry.test.ts
  • src/vs/platform/agentHost/test/node/buildSessionEvents.test.ts
  • src/vs/platform/agentHost/test/node/copilotAccountService.test.ts
  • src/vs/platform/agentHost/test/node/copilotApprovalPolicy.test.ts
  • src/vs/platform/agentHost/test/node/copilotComputerUseActivationTool.test.ts
  • src/vs/platform/agentHost/test/node/copilotComputerUsePermissionSetup.test.ts
  • src/vs/platform/agentHost/test/node/copilotComputerUseTestUtils.ts
  • src/vs/platform/agentHost/test/node/copilotCustomizationInstallations.test.ts
  • src/vs/platform/agentHost/test/node/copilotEntraAuthentication.test.ts
  • src/vs/platform/agentHost/test/node/copilotExtensionTools.test.ts
  • src/vs/platform/agentHost/test/node/copilotFailureTelemetry.test.ts
  • src/vs/platform/agentHost/test/node/copilotFusionTestEvents.ts
  • src/vs/platform/agentHost/test/node/copilotGitHubTelemetryForwarder.test.ts
  • src/vs/platform/agentHost/test/node/copilotModelRouterTools.test.ts
  • src/vs/platform/agentHost/test/node/copilotPermissionAttribution.test.ts
  • src/vs/platform/agentHost/test/node/copilotSandboxCertificate.test.ts
  • src/vs/platform/agentHost/test/node/copilotSandboxCertificateCli.test.ts
  • src/vs/platform/agentHost/test/node/copilotSandboxCertificateDiagnostics.test.ts
  • src/vs/platform/agentHost/test/node/copilotSecondaryAssignmentContext.test.ts
  • src/vs/platform/agentHost/test/node/copilotShellTools.test.ts
  • src/vs/platform/agentHost/test/node/copilotTestEvents.ts
  • src/vs/platform/agentHost/test/node/copilotToolDisplay.test.ts
  • src/vs/platform/agentHost/test/node/copilotVirtualWorkspace.test.ts
  • src/vs/platform/agentHost/test/node/localModelBridge/copilotRequestHandler.test.ts
  • src/vs/platform/agentHost/test/node/localModelBridge/fakeLocalModelProvider.ts
  • src/vs/platform/agentHost/test/node/localModelBridge/shimLocalModelProvider.test.ts
  • src/vs/platform/agentHost/test/node/mapSessionEvents.perf.test.ts
  • src/vs/platform/agentHost/test/node/mapSessionEvents.test.ts
  • src/vs/platform/agentHost/test/node/sessionCustomizationDiscovery.test.ts
  • src/vs/platform/agentHost/test/node/toolInstructions.test.ts
  • src/vs/platform/dialogs/electron-browser/dialog.ts
  • src/vs/platform/product/common/product.ts
  • test/integration/agentHost/coverage.ts

(Written by Copilot)

Bundle @microsoft/[email protected] with runtime 1.0.113-1 on desktop and remote. Keep explicit spawned-stdio hosting, migrate client/session/RPC options and extension examples, and retain legacy transcript attribution. Update platform packaging, policy schema and focused regression tests.

Co-authored-by: Copilot <[email protected]>
Copilot AI balanced review requested due to automatic review settings November 17, 2026 18:18
@vs-code-engineering

This comment has been minimized.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The shared test helper excludes @microsoft/copilot-sdk, causing every updated Copilot version-formatting case to fail.

1 open issue
2 files not reviewed
  • pnpm-lock.yaml: Generated file
  • remote/pnpm-lock.yaml: Generated file
What changed in this PR

Migrates VS Code’s Agent Host to Microsoft Copilot SDK v2 while explicitly retaining a separate runtime process.

Changes:

  • Updates SDK dependencies, runtime versions, packaging paths, canary tooling, and license attribution.
  • Adapts client/session options, credentials, event handling, and extension registration to the v2 API.
  • Updates tests, managed-settings schema expectations, and documentation. Cross-platform acceptance remains pending as noted in the draft.
File Description
test/​integration/​agentHost/​coverage.ts Updates SDK coverage filtering.
src/​vs/​platform/​product/​common/​product.ts Reads the renamed SDK dependency version.
src/​vs/​platform/​dialogs/​test/​electron-browser/​dialog.test.ts Updates About dialog SDK expectations.
src/​vs/​platform/​dialogs/​electron-browser/​dialog.ts Displays the new SDK package name.
src/​vs/​platform/​agentHost/​test/​node/​toolInstructions.test.ts Updates SDK type imports.
src/​vs/​platform/​agentHost/​test/​node/​sessionCustomizationDiscovery.test.ts Updates SDK type imports.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotOtel.integrationTest.ts Migrates telemetry tests to v2 options.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotNativeExtensions.integrationTest.ts Migrates embedded extension registrations.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotMockLlm.integrationTest.ts Migrates embedded canvas registrations.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotManagedPermissions.integrationTest.ts Migrates managed-permission test configuration.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotManagedLimitTo.integrationTest.ts Migrates policy and sandbox test options.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotLocalModel.integrationTest.ts Migrates local-model client and inference options.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotExtensionEnvConsent.integrationTest.ts Updates canvas environment-consent fixtures.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotCustomizations.integrationTest.ts Migrates customization test client setup.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotCredentialSponsorship.integrationTest.ts Updates credential and environment assertions.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotConnectors.integrationTest.ts Migrates connector test configuration.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotByokSelectionIds.integrationTest.ts Migrates custom-model selection setup.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotByokResponses.integrationTest.ts Migrates provider routing and streaming options.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotBuiltinToolAllowlist.integrationTest.ts Migrates tool-inventory test options.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotAutoTier.integrationTest.ts Migrates managed-model and Auto-tier options.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotAgentIntegrationTestHarness.ts Asserts spawned transport and captures nested options.
src/​vs/​platform/​agentHost/​test/​node/​providerIntegration/​copilotAccountContext.integrationTest.ts Migrates account-context client setup.
src/​vs/​platform/​agentHost/​test/​node/​mapSessionEvents.test.ts Updates SDK event type imports.
src/​vs/​platform/​agentHost/​test/​node/​mapSessionEvents.perf.test.ts Updates SDK event type imports.
src/​vs/​platform/​agentHost/​test/​node/​localModelBridge/​shimLocalModelProvider.test.ts Updates request-context type imports.
src/​vs/​platform/​agentHost/​test/​node/​localModelBridge/​fakeLocalModelProvider.ts Updates fake provider SDK types.
src/​vs/​platform/​agentHost/​test/​node/​localModelBridge/​copilotRequestHandler.test.ts Updates request-handler SDK types.
src/​vs/​platform/​agentHost/​test/​node/​e2e/​providers/​copilotManagedSettingsAgentHostE2E.integrationTest.ts Migrates lockdown extension registration.
src/​vs/​platform/​agentHost/​test/​node/​copilotVirtualWorkspace.test.ts Updates tool-result type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotToolDisplay.test.ts Updates permission type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotTestEvents.ts Updates shared SDK fixture types.
src/​vs/​platform/​agentHost/​test/​node/​copilotShellTools.test.ts Updates shell-tool SDK types.
src/​vs/​platform/​agentHost/​test/​node/​copilotSessionLauncherTestHelpers.ts Uses nested sandbox update options.
src/​vs/​platform/​agentHost/​test/​node/​copilotSecondaryAssignmentContext.test.ts Updates telemetry type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotSdkNativeAgents.integrationTest.ts Migrates native-agent modes and session options.
src/​vs/​platform/​agentHost/​test/​node/​copilotSdkManagedSettings.integrationTest.ts Migrates managed-settings client setup.
src/​vs/​platform/​agentHost/​test/​node/​copilotSdkImportSession.integrationTest.ts Migrates imported-session client and resume options.
src/​vs/​platform/​agentHost/​test/​node/​copilotSdkCustomizationDiscovery.integrationTest.ts Migrates discovery client modes and transport.
src/​vs/​platform/​agentHost/​test/​node/​copilotSdkCanvas.integrationTest.ts Migrates canvas lifecycle clients and extensions.
src/​vs/​platform/​agentHost/​test/​node/​copilotSandboxCertificateDiagnostics.test.ts Updates SDK client type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotSandboxCertificateCli.test.ts Updates SDK client type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotSandboxCertificate.test.ts Updates SDK client type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotRuntimePaths.test.ts Tests renamed platform-package paths.
src/​vs/​platform/​agentHost/​test/​node/​copilotPermissionAttribution.test.ts Updates permission-result type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotModelRouterTools.test.ts Updates tool type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotGitHubTelemetryForwarder.test.ts Updates telemetry type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotGitHubCredentials.test.ts Updates nested credential field expectations.
src/​vs/​platform/​agentHost/​test/​node/​copilotFusionTestEvents.ts Updates event fixture type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotFailureTelemetry.test.ts Updates event type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotExtensionTools.test.ts Updates tool-invocation type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotEntraAuthentication.test.ts Updates authentication type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotEntraAuthentication.integrationTest.ts Migrates authentication transport and session options.
src/​vs/​platform/​agentHost/​test/​node/​copilotCustomizationInstallations.test.ts Updates installation SDK types.
src/​vs/​platform/​agentHost/​test/​node/​copilotComputerUseTestUtils.ts Updates elicitation fixture types.
src/​vs/​platform/​agentHost/​test/​node/​copilotComputerUsePermissionSetup.test.ts Updates elicitation type imports.
src/​vs/​platform/​agentHost/​test/​node/​copilotComputerUseActivationTool.test.ts Updates activation-tool SDK types.
src/​vs/​platform/​agentHost/​test/​node/​copilotApprovalPolicy.test.ts Updates approval-policy SDK types.
src/​vs/​platform/​agentHost/​test/​node/​copilotAccountService.test.ts Updates account-service SDK types.
src/​vs/​platform/​agentHost/​test/​node/​buildSessionEvents.test.ts Updates session-event type imports.
src/​vs/​platform/​agentHost/​test/​node/​agentHostPromptRegistry.test.ts Updates prompt SDK types.
src/​vs/​platform/​agentHost/​test/​node/​agentHostPromptOverride.test.ts Updates tool type imports.
src/​vs/​platform/​agentHost/​test/​node/​agentHostGitHubTelemetryRouter.test.ts Updates telemetry type imports.
src/​vs/​platform/​agentHost/​test/​node/​__snapshots__/​Copilot_SDK_-_managed_settings_bundled_managedSettings_schema_matches_the_snapshot.schema.json Records the runtime’s browser-use managed setting.
src/​vs/​platform/​agentHost/​node/​shared/​editChunkExtractor.ts Updates SDK naming in a comment only.
src/​vs/​platform/​agentHost/​node/​otel/​agentHostOTelService.ts Updates telemetry configuration type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​sessionCustomizationDiscovery.ts Updates discovery SDK imports.
src/​vs/​platform/​agentHost/​node/​copilot/​prompts/​toolInstructions.ts Updates prompt section type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​prompts/​systemMessage.ts Updates system-message SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​prompts/​promptRegistry.ts Updates prompt registry SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​prompts/​promptOverride.ts Updates tool type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​prompts/​openaiPrompt.ts Updates prompt section type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​prompts/​anthropicPrompt.ts Updates prompt section type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​mapSessionEvents.ts Preserves guarded legacy transcript attribution reads.
src/​vs/​platform/​agentHost/​node/​copilot/​localModelBridge/​shim/​shimLocalModelProvider.ts Updates provider configuration SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​localModelBridge/​shim/​requestRouter.ts Updates request-context type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​localModelBridge/​shim/​copilotRequestHandler.ts Uses the renamed request-handler package.
src/​vs/​platform/​agentHost/​node/​copilot/​localModelBridge/​localModelProvider.ts Updates local-model SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​customizations/​copilotCustomizationInstallations.ts Updates installation SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotVirtualSessionFs.ts Updates virtual-filesystem SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotVirtualSearchTools.ts Updates search-tool SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotToolDisplay.ts Updates SDK imports and explanatory naming.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSystemNotification.ts Updates notification SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSlashCommand.ts Updates session type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotShellTools.ts Updates shell-tool SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSessionWrapper.ts Updates trust typing and removes retired partial events.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSessionSandbox.ts Updates sandbox SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSessionHistory.ts Updates history SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSecondaryAssignmentContext.ts Updates telemetry type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSdkMeta.ts Updates SDK metadata types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSandboxPolicy.ts Updates session-event type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSandboxDiagnostics.ts Updates SDK client type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSandboxCertificateCli.ts Uses v2 spawned transport for certificate commands.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotSandboxCertificate.ts Updates SDK client type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotRuntimePaths.ts Resolves runtime packages under @microsoft.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotPromptAttribution.ts Reads callback types from nested interaction options.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotPluginConverters.ts Updates plugin configuration SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotPermissionAttribution.ts Uses renamed permission-attribution imports.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotModelRouterTools.ts Updates router-tool SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotMessageSource.ts Updates message-source SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotMcpSkillConsent.ts Reads user-input types from v2 interaction options.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotManagedSettings.ts Updates SDK client type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotManagedModelConfiguration.ts Updates managed-model SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotGrepSearchNudge.ts Updates session and hook SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotGitHubTelemetryForwarder.ts Updates telemetry type imports.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotGitHubCredentials.ts Renames credential fields for nested GitHub options.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotFusionReplay.ts Updates replay event types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotFusionProgress.ts Updates progress event types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotFusionPhaseTelemetry.ts Updates telemetry event types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotFusionMessageChunks.ts Updates message-chunk event types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotFusionEventIdentity.ts Updates event identity types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotFailureTelemetry.ts Updates failure event types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotExtensionTools.ts Updates extension-tool SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotEntraAuthentication.ts Updates authentication SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotCustomizationCommandDisplay.ts Updates customization SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotConnectors.ts Updates connector SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotComputerUsePermissionSetup.ts Updates elicitation SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotComputerUseActivationTool.ts Updates activation-tool SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotBuiltinSkills.ts Updates skill-provider SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotBuiltinAgents.ts Updates custom-agent SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotApprovalPolicy.ts Updates approval-policy SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotAgentSession.ts Migrates mutable options and live event handling.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotAgent.ts Groups client options and explicitly spawns the runtime.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotAccountService.ts Migrates account-session options to v2 groups.
src/​vs/​platform/​agentHost/​node/​copilot/​copilotAccountModelCatalog.ts Updates model-catalog SDK types.
src/​vs/​platform/​agentHost/​node/​copilot/​buildSessionEvents.ts Updates transcript construction SDK types.
src/​vs/​platform/​agentHost/​node/​agentHostGitHubTelemetryRouter.ts Updates telemetry notification types.
src/​vs/​platform/​agentHost/​common/​otel/​agentHostOTelService.ts Updates telemetry types and SDK documentation.
src/​vs/​platform/​agentHost/​AGENTS.md Updates documented SDK identity and option types.
resources/​linux/​snap/​snapcraft.yaml Updates runtime library patching paths.
remote/​pnpm-workspace.yaml Adds the renamed SDK release-age exception.
remote/​package.json Pins the remote SDK and runtime versions.
pnpm-workspace.yaml Adds the renamed SDK release-age exception.
package.json Pins the desktop SDK and runtime versions.
extensions/​copilot/​src/​platform/​promptFiles/​test/​node/​builtinSkills.spec.ts Updates canvas skill package expectations.
extensions/​copilot/​assets/​prompts/​skills/​create-canvas/​SKILL.md Documents nested v2 canvas and tool registration.
eslint.config.js Allows the renamed SDK imports.
cglicenses.json Updates the SDK license override and source.
build/​lib/​test/​universalApp.test.ts Updates architecture-specific SDK fixtures.
build/​lib/​test/​applySdkCanaryOverride.test.ts Targets the renamed SDK in canary tests.
build/​lib/​copilot.ts Updates runtime lookup and platform-package filtering.
build/​gulpfile.vscode.ts Updates version stamping and unpacking paths.
build/​darwin/​verify-macho.ts Updates single-architecture SDK exclusions.
build/​darwin/​create-universal-app.ts Updates SDK cross-copy and merge paths.
build/​azure-pipelines/​sdk-validation-build.yml Updates the SDK canary parameter label.
build/​azure-pipelines/​product-build.yml Updates the SDK canary parameter label.
build/​azure-pipelines/​product-build-ado-ci.yml Updates the SDK canary parameter label.
build/​azure-pipelines/​linux/​build-snap.sh Updates bundled OpenSSL destination paths.
build/​azure-pipelines/​common/​apply-sdk-canary.yml Updates the SDK name in a comment only.
build/​azure-pipelines/​common/​apply-sdk-canary-override.ts Resolves and overrides the renamed SDK package.
build/​.moduleignore Updates SDK exclusions while retaining Koffi removal.
.github/​skills/​smoke-tests/​SKILL.md Updates documented runtime package naming.
.github/​skills/​otel/​SKILL.md Updates documented SDK version lookup.
.github/​skills/​flaky-smoke-tests/​SKILL.md Updates documented runtime package naming.
.github/​skills/​agent-host-e2e-tests/​SKILL.md Updates documented runtime package naming.

Review effort: Balanced

Select the standalone CLI and renamed SDK version lines explicitly so the existing formatting assertions continue checking both packages.

Co-authored-by: Copilot <[email protected]>
@vs-code-engineering

This comment has been minimized.

@vs-code-engineering

This comment has been minimized.

@vs-code-engineering vs-code-engineering Bot added the pr-demo A PR demo was recorded for this pull request label Nov 17, 2026
Preserve the current Microsoft 365 account restoration and worktree cleanup fixes while keeping SDK v2's explicit spawned-stdio client factory and nested options.

Co-authored-by: Copilot <[email protected]>
@vs-code-engineering

This comment has been minimized.

@vs-code-engineering

This comment has been minimized.

Keep the standalone CLI's canvas authoring guide aligned with its independently bundled v1 SDK. Document envelope agentId and subagent.started attribution in the Agent Host v2 troubleshooting skill, including the fallback for older saved logs.

Co-authored-by: Copilot <[email protected]>
@vs-code-engineering

This comment has been minimized.

@vs-code-engineering

This comment has been minimized.

@roblourens
roblourens marked this pull request as ready for review November 17, 2026 20:30
@roblourens
roblourens enabled auto-merge November 17, 2026 20:30
@vs-code-engineering

vs-code-engineering Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

📬 CODENOTIFY

The following users are being notified based on files changed in this PR:

Ladislau Szomoru (@lszomoru)

Matched files:

  • build/azure-pipelines/common/apply-sdk-canary-override.ts
  • build/azure-pipelines/common/apply-sdk-canary.yml
  • build/azure-pipelines/linux/build-snap.sh
  • build/azure-pipelines/product-build-ado-ci.yml
  • build/azure-pipelines/product-build.yml
  • build/azure-pipelines/sdk-validation-build.yml

Keep main's plugin-directory validation and history recovery with the renamed SDK and nested session options.

Co-authored-by: Copilot <[email protected]>
@vs-code-engineering

This comment has been minimized.

@vs-code-engineering

This comment has been minimized.

TylerLeonhardt
TylerLeonhardt previously approved these changes Nov 17, 2026
@roblourens
roblourens added this pull request to the merge queue Nov 17, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Nov 17, 2026
Preserve subagent chat links and the shared Connector fixture while retaining spawned SDK v2 clients. Migrate upstream MCP diagnostics to the renamed SDK import and session options type.

Co-authored-by: Copilot <[email protected]>
@vs-code-engineering

This comment has been minimized.

@roblourens
roblourens added this pull request to the merge queue Nov 18, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Nov 18, 2026
Preserve upstream Canvas extension-data sandbox grants through the SDK v2 extensions and permissions options. Cover enabled and disabled extensions on both create and resume.

Co-authored-by: Copilot <[email protected]>
@vs-code-engineering

This comment has been minimized.

@vs-code-engineering

Copy link
Copy Markdown
Contributor

Demo of d3f13f2

About now lists @​microsoft/copilot-sdk 2.0.0-preview.2 instead of the GitHub SDK.

Bundled SDK in About

Before (main) After (this pull request)
About lists @​github/copilot-sdk:​ 1.0.33-preview.0.
About lists @​github/copilot-sdk:​ 1.0.33-preview.0.
About lists @​microsoft/copilot-sdk:​ 2.0.0-preview.2.
About lists @​microsoft/copilot-sdk:​ 2.0.0-preview.2.

The change, on this pull request's build:

after.mp4
The same steps on main
before.mp4

Recorded by an agent on a build of this pull request merged with main, signed out, with a mock model. It can be wrong. Workflow run

Tip

Was this useful? React to this comment with 👍 or 👎.
On the VS Code team? Say what was wrong or missing.

@roblourens
roblourens added this pull request to the merge queue Nov 18, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to no response for status checks Nov 18, 2026
@roblourens
roblourens added this pull request to the merge queue Nov 18, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to no response for status checks Nov 18, 2026
@connor4312
Connor Peet (connor4312) added this pull request to the merge queue Nov 18, 2026
Merged via the queue into main with commit 8757910 Nov 18, 2026
39 checks passed
@connor4312
Connor Peet (connor4312) deleted the roblou/agents/update-copilot-sdk-to-v2 branch November 18, 2026 16:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-demo A PR demo was recorded for this pull request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants