Commit Graph

22744 Commits

Author SHA1 Message Date
Henning Dieterichs a9f0f574fc adds proposed createQuickDiffInformation API, adopts it in markdown editor. (#323470)
* adds proposed createQuickDiffInformation API, adopts it in markdown editor.

* Extends textEditorDiffInformation proposal instead of having new quickDiff proposal
2026-06-29 16:37:26 +00:00
Giuseppe Cianci 2deeac48d6 Merge pull request #323169 from microsoft/kimi-prompt
Add Kimi Prompt
2026-06-29 16:20:22 +02:00
Robo 4b6f5e55bb chore: bump electron@42.5.0 (#321629)
* chore: bump electron@42.4.0

* chore: apply temp dir workaround for short paths

* chore: use 24.15.x for CI node

* chore: update nodejs build

* chore: bump electron@42.5.0

* fix: unblock playwright install on node 24.17

Node 24.16+ made Readable pause()/resume() a no-op on destroyed streams
which makes yauzl 2.x / extract-zip 2.x and older playwright extraction
hang forever.

- extensions/copilot: add "yauzl": "^3.3.1" override (was missed by #318682)
  so electron and @vscode/vsce no longer resolve the broken yauzl 2.10, fixing the
  hung `npm ci` in the Copilot and Extract chat-lib pipelines.
- extensions/copilot: bump electron ^39.8.5 -> ^42.5.0 so its install
  script uses the native @electron-internal/extract-zip instead of extract-zip.
- bump @playwright/test ^1.56.1 -> ^1.61.1 so `playwright install`
  uses the fixed extractor, unblocking the "Download Electron and
  Playwright" step in all electron test pipelines.

* chore: update build

* agentHost: fix macOS sandbox smoke sentinel parsing

On macOS CI, the AgentHost sandbox smoke test resolves the shell to
/bin/sh, which uses the sentinel-based completion path. In that path, the
parser could consume the echoed sentinel command text
(`<<<COPILOT_SENTINEL_..._EXIT_$?>>>`) before the real numeric marker
arrived, causing a false `Exit code: -1` failure even though the command
later completed successfully.

Harden the sentinel parser to ignore echoed/non-numeric sentinel text
and use the latest complete numeric marker instead. Also force the
macOS AgentHost sandbox smoke test to use /bin/sh and assert that in the
suite log so local runs exercise the same path as CI.

Adds a regression test for echoed sentinel command text.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* chore: update screenshot baseline after playwright bump

* chore: bump distro

* chore: fix typecheck

* chore: bump distro

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-29 13:53:48 +00:00
vs-code-engineering[bot] 6387b615a0 Bump version to 1.128.0 (#323406)
* Bump version to 1.128.0

* signing commit

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Giuseppe Cianci <gcianci@microsoft.com>
2026-06-29 09:45:37 +00:00
Vijay Upadya e13c4c953d Update gemini3 prompt and tool call flags (#323364)
* Update gemini3 flags

* update package json default values
2026-06-28 21:07:45 +00:00
Ulugbek Abdullaev 4fc2b3348b NES: cache cross-file suggestions under the active document (#323150)
* NES: cache cross-file suggestions under the active document

When the model returns a Next Edit Suggestion for a document other than
the one being edited (cross-file NES), it was only cached under the target
document, so it could not be re-served until the user navigated there.
Also cache an `activeDoc (content + edit window) -> edit-in-target`
association so the suggestion can be re-served from cache while the cursor
is still in the active document.

A cross-file entry is served only while its target document is open and
byte-identical to the snapshot the edit's offsets index into; otherwise the
read path treats it as a cache miss and refetches, rather than serving a
misplaced edit or getting stuck re-serving a dead entry until the active
document changes. At stream end the active document is no longer cached as
"no edit" when a cross-file entry was just stored under the same key, which
would otherwise clobber it.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Dispose provider and documents in runCrossFileScenario

Tear down the NextEditProvider (which registers autoruns/watchers on
openDocuments) and both documents at the end of each cross-file scenario
run so the tests are self-contained and do not accumulate observers.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-27 17:02:55 +05:00
Zhichao Li e5ec5abcc6 fix: register otel protocol/serviceName/resourceAttributes/headers config keys to match package.json 2026-06-26 21:38:28 -07:00
Zhichao Li 7b0180b3c3 docs: update OTel user + agent-host docs for managed-settings precedence and new settings 2026-06-26 21:38:27 -07:00
Zhichao Li e9a25536d6 refactor: address PR review — policy precedence docs, grpc transport inference, prototype-pollution hardening 2026-06-26 21:38:26 -07:00
Zhichao Li 649467ab6d fix: align agentOTelEnv test config with widened otlpProtocol type 2026-06-26 21:38:25 -07:00
Zhichao Li 597760e9ba Merge remote-tracking branch 'origin/main' into zhichli/otelpolicy2 2026-06-26 21:38:24 -07:00
Zhichao Li 65bcc23a6d docs: remove internal OTel managed-settings planning notes 2026-06-26 16:58:47 -07:00
Zhichao Li 6410d9e8f5 docs: record serviceName/resourceAttributes/headers delivery in sprint 2026-06-26 16:04:32 -07:00
Zhichao Li bb524011b6 feat: deliver managed OTel headers to the Copilot Chat extension 2026-06-26 16:02:53 -07:00
Zhichao Li fce8c4fea1 feat: deliver managed OTel resourceAttributes to both surfaces 2026-06-26 15:54:59 -07:00
Zhichao Li ee15deed1c feat: deliver managed OTel serviceName to both surfaces 2026-06-26 15:44:01 -07:00
Zhichao Li 0fdb82fd27 docs: revise OTel managed-settings sprint plan for headers/resourceAttributes/serviceName
Records the runtime spike: the headless agent host resolves OTel from env only and
doesn't self-fetch managed telemetry, but build_resource reads OTEL_SERVICE_NAME /
OTEL_RESOURCE_ATTRIBUTES env. Revised plan delivers serviceName + resourceAttributes
to both surfaces (env for the host, programmatic for the extension) and headers to the
extension only; agent-host headers stay deferred (env would leak the token to tool
subprocesses).
2026-06-26 15:27:46 -07:00
Zhichao Li 4be6140abd docs: update OTel managed-settings plan/sprint for protocol parity 2026-06-26 13:39:17 -07:00
Zhichao Li bdbe1f0760 feat: honor managed OTLP protobuf wire protocol in copilot-chat extension 2026-06-26 13:38:08 -07:00
Paul 6d7542b870 Support subagent costs for local agent (#323175) 2026-06-26 20:18:27 +00:00
Osvaldo Ortega cbb3fec2b4 Show only cloud coding agent tasks in cloud sessions list (v2) (#323195)
* Show only cloud coding agent tasks in cloud sessions list (v2)

Two fixes to the Task API (v2) cloud sessions list, where local VS Code /
CLI / JetBrains sessions mirrored into Mission Control were leaking in and
settled tasks were stuck showing "In Progress".

- Filter the list to cloud coding agent tasks only. The owning surface is
  identified by the agent integration slug on a task's `agent_collaborators`
  (`copilot-developer` / `copilot-swe-agent` = cloud; `copilot-developer-cli`,
  `vscode-chat`, `jetbrains-chat` = local clients). Adds the exported pure
  helper `isCloudCodingAgentTask` and applies it in `fetchSessionList`.
  `agent_collaborators` is returned to first-party CAPI tokens but not yet
  modeled in `@vscode/copilot-api`, so a minimal local type is used.

- Carry the raw `AgentTaskState` across the backend seam and map it directly
  to `ChatSessionStatus` in the provider, so `idle` renders as Completed and
  `waiting_for_user` as NeedsInput instead of collapsing to InProgress.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Address review: guard malformed slugs and add status fallback

- isCloudCodingAgentTask: use a `typeof c.slug === 'string'` guard so null /
  non-string slugs in the untyped server payload can't reach `Set.has`.
- taskStateToChatSessionStatus: add a `default` branch returning InProgress so
  an unknown/forward-compat task state can't yield an invalid `undefined`
  status. Added tests for both.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-26 19:40:05 +00:00
Zhichao Li d0ba9fcdc4 docs: add OTel managed-settings sprint plan with completion notes 2026-06-26 11:43:03 -07:00
Zhichao Li 42a2f6b5b5 test: cover enterprise OTel policy precedence in resolveOTelConfig 2026-06-26 11:41:53 -07:00
Zhichao Li 74333cf4da feat: apply enterprise OTel policy precedence in copilot-chat extension 2026-06-26 11:39:43 -07:00
Vritant Bhardwaj 3c30cc5b03 Merge pull request #323176 from microsoft/agents/deprecate-ollama-byok-provider-b5806582
Deprecate internal Ollama BYOK provider in favor of the Offical Ollama extension
2026-06-26 11:31:09 -07:00
vs-code-engineering[bot] fc9a595992 fix: drop diagnostics with missing range at the language diagnostics boundary (fixes #323148) (#323153)
* fix: drop diagnostics with missing range at the language diagnostics boundary

Other extensions can publish vscode.Diagnostic entries whose `range` is
undefined (violating the non-nullable `range: Range` type via an `any` cast).
These reach copilot verbatim through `vscode.languages.getDiagnostics()` and
crash the many consumers that dereference `diagnostic.range` - notably the
`LintErrors.getData` telemetry path that scans every extension's diagnostics
via `getAllDiagnostics()`. Sanitize at the boundary service so every consumer
is protected once, and log dropped entries so the producer stays diagnosable.

Fixes microsoft/vscode#323148

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* fix: Copilot - Test lint — use strict equality for range null/undefined check

The eqeqeq ESLint rule (configured as 'warn', enforced with --max-warnings=0)
flagged `range != null` in _dropMalformedDiagnostics. Replace the loose
equality with an explicit strict check that preserves the original semantics
of dropping diagnostics whose range is either null or undefined.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: vs-code-engineering[bot] <122617954+vs-code-engineering[bot]@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-26 18:28:43 +00:00
Zhichao Li b2ca1ff9d5 docs: note policyReference type-match constraint and structured-encode location 2026-06-26 11:23:01 -07:00
Zhichao Li 1ae83f24a5 docs: add enterprise OTel managed-settings policy plan
High-level plan for VS Code enterprise control of Copilot agent-host OTel export via the cross-client telemetry managed-settings schema (matches CLI ManagedTelemetrySettings, copilot-agent-runtime #10735). Covers schema, ownership, precedence, security, delivery channels, suppressions, and touch points.
2026-06-26 11:07:36 -07:00
Vritant Bhardwaj 8482f9336c Merge branch 'main' into agents/deprecate-ollama-byok-provider-b5806582 2026-06-26 10:39:43 -07:00
Giuseppe Cianci 4ef42413b3 address ccr 2026-06-26 19:19:26 +02:00
Giuseppe Cianci e6ba4aaee8 use the right edit tool 2026-06-26 19:05:02 +02:00
Giuseppe Cianci a616d423c7 add kimi prompt 2026-06-26 18:46:53 +02:00
Ulugbek Abdullaev a97573159d Add Adhoc Request Sender Mode with Tag Highlighting (#323100)
* Agent Host changes for agents/adhoc-request-sender-mode-extension-55e2bb6f

* Remove unconfigured react-hooks/exhaustive-deps eslint directive

The eslint-disable directive referenced a rule that isn't registered in
this repo's ESLint config, which caused ESLint to error with
"Definition for rule 'react-hooks/exhaustive-deps' was not found" and
failed the Compile & Hygiene and Copilot - Test CI checks.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Coalesce adhoc tag-decoration rescans with requestAnimationFrame

Rescanning the whole editor text on every content change is wasteful for
bursty updates (e.g. a streamed response). Debounce the decoration update
to at most once per animation frame and cancel any pending frame during
cleanup so the callback can't run after the editor is disposed. The
initial scan stays synchronous so tags are highlighted immediately on mount.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Address PR feedback: dispose token source; validate adhoc request JSON

- adhocRequestSender: always dispose the per-send CancellationTokenSource
  in the finally block (separate from the current-send guard) so its
  cancellation listeners don't leak across repeated Send/Stop cycles.
- simulationMain: validate and normalize the adhoc request JSON before use
  so malformed input (missing/null/wrong-typed model/user/system) yields a
  focused error message instead of a thrown stack trace.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-26 20:36:56 +05:00
Christof Marti c0cc253a97 Sandbox only applies with default approvals (#317981) 2026-06-26 13:49:43 +00:00
Logan Ramos 6ae1b8eb97 If long context = default context. Show a single long context option in picker (#323116) 2026-06-26 12:44:45 +00:00
Christof Marti a91385696d Allow sandbox bypass in Copilot SDK (#317981) 2026-06-26 12:06:47 +02:00
Dmitriy Vasyura dd7a4b90b1 Show session types as disabled with Sign in button when user is offline (#321861) 2026-06-26 01:17:19 +02:00
Anthony Kim 8a9cd3dd36 Bump Copilot CLI package to 1.0.65 (#322747)
* Bump Copilot CLI package to stable 1.0.64

* Try to bump to 1.0.65 instead

* Remove stale Copilot sdk/worker materialization for 1.0.65

* Update Debian amd64 deps after excluding Copilot native executable

* Remove stale RPM x64 libstdc++ deps after Copilot CLI 1.0.65 packaging

* Prune Copilot SEA executable before CI packaging

* Exclude Copilot SEA executable from packaging stream

* SDK should be 1.0.4
2026-06-25 12:03:54 -07:00
Logan Ramos 0acd78faaf Hide long context for models which have the same cost regardless (#322950) 2026-06-25 14:22:00 +00:00
Ladislau Szomoru 1c80314e3b Engineering - update code owners (#322944) 2026-06-25 15:39:36 +02:00
Paul 4972ac9c09 Fix context size default + reload behaviour, add defensive fallbacks (#322882) 2026-06-25 01:34:40 -07:00
Benjamin Christopher Simmonds 4f77029409 Merge pull request #322831 from microsoft/benibenj/relieved-whippet
Fix context key references
2026-06-25 10:18:01 +02:00
Vijay Upadya 9b0c342101 Support Responses API in Azure BYOK (#322845)
* Support  Responses API in Azure BYOK

* feedback updates
2026-06-24 16:49:35 -07:00
BeniBenj 2aa9cbe581 context key fix 2026-06-24 23:38:04 +02:00
Martin Aeschlimann bd2db631aa Add ICustomizationItemProvider.provideSourceFolders functionality (#322740)
* provideSourceFolders

* simplify resolveTargetDirectoryWithPicker

* use provideSourceFolders

* update

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+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>

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* fix

* fix tests

* fix issues

* fix tests

* fix

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-06-24 19:36:48 +00:00
BeniBenj 479a4986c9 CONTEXT KEYS CLEANUP 2026-06-24 19:51:11 +02:00
vs-code-engineering[bot] d3e7ccc25f fix: AsyncIterableSource emit after resolve throws TypeError (fixes #322752) (#322759)
fix: keep AsyncIterableSource emit a no-op after resolve (fixes #322752)

Co-authored-by: vs-code-engineering[bot] <122617954+vs-code-engineering[bot]@users.noreply.github.com>
2026-06-24 17:20:40 +00:00
Anthony Kim 1c0b4bea4c Bump Copilot CLI SDK packages to 1.0.64-1 / 1.0.3 (#322645)
* Bump Copilot CLI packages to @github/copilot@1.0.64-1 and @github/copilot-sdk@1.0.3

* Resolve Agent Host Copilot CLI through @github/copilot/bin.copilot

* Materialize @github/copilot/sdk from @github/copilot-<platform> in extension postinstall

* Package @github/copilot-<platform>/copilot for Agent Host and linuxmusl

* Exclude Copilot optional native payloads from extension package

* Scan @github/copilot-*/copilot for Linux package dependencies

* Tighten Copilot SDK 1.0.64-1 attachment and RPC typings

* Increase Copilot SDK native binary scan test timeout

* Update amd64 deb deps for @github/copilot-linux-x64/copilot

* Update arm64 rpm deps for Copilot package layout

* Update x64 rpm deps for @github/copilot-linux-x64/copilot

* Try to fix windows smoke test

* Try to fix platform runtime files for agent host

* exclude copilot computer.node from agent host packaging

* Another attempt to try to get packaging right

* Should only try to load 1.0.64-1

* Try to fix packaing for windows, macos, deb deps

* Update armhf/arm64 deb and x64 rpm Copilot dependency baselines

* Copilot darwin ripgrep universal merge and arm64 rpm deps

* Restore target Copilot SDK prebuilds for built-in extension packaging

* see if changes to gulpfile.reh.ts would help

* dont mess with formatting

* Launch copilot cli from platform index.js and exclude SEA
2026-06-24 06:47:26 -07:00
Alexandru Dima de07516770 smoke: add remote server process exit diagnostics (#322697)
Remote smoke tests intermittently fail with "Cannot reconnect. Please reload
the window." The root cause is the remote server process exiting unexpectedly
shortly after a client connects; because the server logs nothing on the way out,
the client reconnects against a freshly spawned server with a new connection
token and hits "Unknown reconnection token (never seen)".

Add best-effort process exit diagnostics in server-main.ts that distinguish a
self-exit (beforeExit), an external kill (signal) and a crash
(uncaughtExceptionMonitor), and log the test resolver child's exit/close signal.
Gated behind the VSCODE_SERVER_EXIT_DIAGNOSTICS env var, which the remote smoke
launcher sets, so it adds no product noise.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-24 12:47:37 +02:00
Alexandru Dima 7219f045a9 Rename "GitHub Copilot Chat" extension to "GitHub Copilot" (#322683)
Agent Host changes for agents/rename-github-copilot-chat-12677b65
2026-06-24 12:18:57 +02:00