Commit Graph
23150 Commits
Author SHA1 Message Date
Bhavya UandCopilot d02bfbbc5c Show Anthropic refusals correctly (#331315)
* Fix Anthropic refusal error handling

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

* Handle refusal edge cases

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

* Simplify refusal error handling

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

* Avoid logging refusal explanations

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

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-17 14:11:41 -07:00
vritant24andCopilot bd96693dc6 chat: localize BYOK failure descriptions and drop unrelated coverage
Route both synthesized failure descriptions through @vscode/l10n with
placeholders for the provider code and diagnostic details, matching the
localized endpoint error pattern in imageLimits.ts. These strings reach the
user as the BYOK failure reason, so a non-English install should not receive
untranslated text. The bracketed identifiers stay verbatim so they remain
greppable and pasteable into a provider support request.

Revert the Agent Host integration test expansion. It exercised parameterless
tool schemas and tool-call continuations, which ruled out two alternative
causes while investigating, but no production tool handling changes here and
that coverage does not validate this fix.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-17 11:56:07 -07:00
vritant24andCopilot 90dde50c2f chat: describe BYOK Responses failures that omit error details
A provider can end a Responses stream with a terminal event whose error
object omits the code and message the API contract requires. Serializing
that object produced {"code":0,"message":"","metadata":{}}, which the BYOK
endpoint promotes to the entire user-facing reason, so an outage and a
malformed request looked identical and neither users nor maintainers could
tell them apart.

Describe such failures instead, naming the terminal event, response status,
and response id so the failure stays correlatable with the provider, and
omit absent metadata keys so serialization cannot collapse them to an empty
object. Keep the fetcher's original reason when a stream error carries no
message, so a hollow struct never replaces an actionable one.

The mapping predates the reports; the Agent Host BYOK proxy moving from
Chat Completions to Responses in 1.132.0 is what first exposed it in the
Agents Window. This restores diagnosability rather than stopping the
upstream failure, so it does not close the report on its own.

Related to #330408

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-17 11:42:20 -07:00
vs-code-engineering[bot]andgithub-actions[bot] 64a666e787 Bump version to 1.135.0 (#331156)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-08-17 08:34:56 +00:00
yzxcj797 2ccee5f24a docs: fix dead nes-video.gif link in copilot extension README (#330992) 2026-08-16 17:23:15 +00:00
Martin Check 09b07fe400 chat: avoid splitting surrogate pairs in read_file (#331005) 2026-08-16 07:59:52 +00:00
Joaquín Ruales f764694f93 Add regression tests for thenable RPC proxies (#330966) 2026-08-14 21:56:36 +00:00
Henning DieterichsandCopilot d6abb42654 Implements rich link rendering in chat (#330925)
* implements rich link presentation in chats

* Allows settings to be set by experiments

* Fix rich link CI configuration

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

Copilot-Session: b8949987-7bbf-43c2-a7bb-ee6450ac74c7

---------

Copilot-Session: b8949987-7bbf-43c2-a7bb-ee6450ac74c7
2026-08-14 21:17:51 +00:00
Justin Chen 8715d6263b fix md resize causing wrong calculated position (#330930) 2026-08-14 19:54:41 +00:00
Joaquín Ruales f59e07449b Guard RPC proxies against becoming thenables (#330923) 2026-08-14 19:35:25 +00:00
Bhavya UandCopilot 79c2382913 Revert to showing all context size options (#330737)
* Revert to showing all context size options

Removes the `github.copilot.chat.preferLongContext.enabled` setting and
reverts to always showing both the default and long-context options in the
model picker. Also removes the now-dead `freeLongContext` plumbing that the
setting gated.

Reverts:
- https://github.com/microsoft/vscode/pull/322950
- https://github.com/microsoft/vscode/pull/323116
- https://github.com/microsoft/vscode/pull/324650
- https://github.com/microsoft/vscode/pull/328628

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

* Add context-size picker coverage for both surfaces

Addresses PR review: cover the reverted "always show both context options"
behavior for each independently implemented picker surface.

- languageModelAccess.test.ts: a free/no-surcharge endpoint publishes both
  the default and full windows, with the smaller window as the default.
- copilotCliModels.spec.ts: a CLI model with defaultContextMax < maxInputTokens
  and no long-context surcharge exposes both sizes, smaller as default.

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

* Default to the longer window for free long-context models

Keeps both context-size options in every picker, but when the long-context
tier has no surcharge (free long context) the default selection — and the
no-selection behavioral fallback — is the full window rather than the smaller
default tier. Models with a long-context surcharge still default to the
smaller tier so users opt into the extra cost.

Applied consistently across all four surfaces:
- Main chat picker: getContextSizeOptions default + applyContextSizeOverride fallback
- Copilot CLI picker: buildConfigurationSchema default + resolveContextTier fallback
- Agent host: _createContextSizeConfigSchemaProperty default + getCopilotContextTier
  via the restored freeLongContext flag (and hasLongContextSurcharge helper)

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

* Shorten context-size comments

Condense the free-long-context comments added across the picker surfaces to
concise one-liners; no behavior change.

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

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-14 11:00:17 -07:00
dependabot[bot]andRaymond Zhao da166b949c build(deps): bump nanoid from 3.3.12 to 3.3.18 in /extensions/mermaid-markdown-features (#330691)
build(deps): bump nanoid in /extensions/mermaid-markdown-features

Bumps [nanoid](https://github.com/ai/nanoid) from 3.3.12 to 3.3.18.
- [Release notes](https://github.com/ai/nanoid/releases)
- [Changelog](https://github.com/ai/nanoid/blob/3.3.18/CHANGELOG.md)
- [Commits](https://github.com/ai/nanoid/compare/3.3.12...3.3.18)

---
updated-dependencies:
- dependency-name: nanoid
  dependency-version: 3.3.18
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
2026-08-14 10:48:19 -07:00
0971bd5d66 Update agent panel border colors across themes (#330864)
* theme: update agent panel border colors and styles across themes

* theme: update border colors for agents in various themes

* Potential fix for pull request finding

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

* fix(theme): update agentsPanel.border to transparent

* fix(theme): set agentsPanel.border to transparent

* fix(screenshots): update image links for agent host and user data migration

---------

Co-authored-by: mrleemurray <mrleemurray@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-08-14 17:13:06 +00:00
Dirk Bäumer 6ebcc0a377 Fixes #319956: Enable editor.showUnused for .js files (#330867)
Fixes #319956: editor.showUnused in .js is not working
2026-08-14 14:50:13 +00:00
Christof MartiandCopilot be7d2fa5a9 Fix observable cache state during event delivery
Preserve the cleared cache state when the last observer removes itself during event notification, and cover re-observation with a regression test.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-14 15:02:57 +02:00
979e48cec5 Add authSessionAccountIcon proposed API and account avatar support (#308654)
* Add authSessionAccountIcon proposed API and account avatar support

Introduces a new proposed API `authSessionAccountIcon` that allows authentication
providers to supply an icon URL (typically a profile avatar) for authentication
session accounts.

Changes:
- New proposed API: `AuthenticationSessionAccountInformation.iconUrl`
- GitHub authentication extension updated to fetch and provide user avatar URLs
- Activity bar and global composite bar updated to display account avatars
- Authentication service extended to propagate icon information

* Address Copilot review feedback

- Use removeAttribute('src') instead of empty string to avoid spurious requests
- Add alt='', aria-hidden='true', draggable=false to avatar img for accessibility
- Update iconUrl in addOrUpdateAccount when provider supplies/changes it
- Fetch avatarUrl for existing sessions that are missing iconUrl

* Address review feedback: account icon as Uri, avatar setting, Agents window consolidation

- Change AuthenticationSessionAccountInformation.iconUrl (string) to icon (Uri)
  per review feedback, and use URI in the internal workbench type
- Revive the icon URI at the RPC boundaries (MainThread/ExtHost), typing the
  proxies as Proxied<T>
- Persist the fetched avatar in stored GitHub auth sessions so it is not
  refetched on every read
- Add workbench.accounts.showAvatar setting to show/hide account avatars
- Agents window: prefer the authentication session's account icon over the
  hardcoded github.com avatar URL pattern and honor the new setting

* Fix Compile & Hygiene: tab indentation in extensionsApiProposals and remove unused import

* Fix DynamicAuthProvider test mock to match Proxied proxy typing

* auth - improve account avatar support

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

---------

Co-authored-by: Dmitriy Vasyura <dmitriv@microsoft.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-14 06:47:04 +00:00
Justin Chen 8a17bf51a5 vision: fix enterprise block (#330776) 2026-08-14 01:04:24 +00:00
Logan Ramos fe7e476752 Delete Auto V1 (#330771)
* Delete Auto V1

* Missed a few
2026-08-14 00:15:47 +00:00
Vritant Bhardwaj f0f3e9cdfe Merge pull request #330763 from microsoft/agents/vscode-issue-330712-investigation 2026-08-13 17:03:30 -07:00
vritant24andCopilot 0d4262ebcd chat: support custom endpoint thinking modes
Forward adaptive and budget-based thinking capabilities from custom model
configuration into endpoint metadata. Preserve the per-request thinking flag
across the extension-contributed language model boundary so Messages requests
can activate the configured mode.

Refs #330712

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-13 15:42:27 -07:00
Simon SiefkeandDmitriy Vasyura 3c95df8b70 fix: memory leak in references view (#330191)
* fix: memory leak in references view

* refactor: register references decoration for disposal

* simplify code

* simplify code

* simplify code

* simplify code

* simplify code

* fix: add missing semicolon

---------

Co-authored-by: Dmitriy Vasyura <dmitriv@microsoft.com>
2026-08-13 21:39:57 +00:00
dependabot[bot]andRaymond Zhao af1bb12927 build(deps): bump hono from 4.12.31 to 4.12.34 in /extensions/copilot (#328855)
Bumps [hono](https://github.com/honojs/hono) from 4.12.31 to 4.12.34.
- [Release notes](https://github.com/honojs/hono/releases)
- [Commits](https://github.com/honojs/hono/compare/v4.12.31...v4.12.34)

---
updated-dependencies:
- dependency-name: hono
  dependency-version: 4.12.34
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
2026-08-13 18:33:20 +00:00
Henning DieterichsandCopilot 2e8330a1b3 Add reactive rich links to the Markdown editor
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 478c4f91-5974-4fd3-a41e-24f5b6f6443d
2026-08-13 19:03:50 +02:00
Vritant Bhardwaj d2d9911ba8 Merge pull request #330662 from microsoft/agents/vscode-issue-330610-investigation
chat: fix empty Responses tool schemas
2026-08-13 09:53:30 -07:00
Logan Ramos 3d952f83c2 Read the renamed CAPI token price fields (#330661)
CAPI now returns `max_prompt_tokens` and `cache_read_price` inside
`billing.token_prices.<tier>`, replacing `context_max` and `cache_price`.
`normalizeTokenPrices` only read the old names, so
`tokenPricing.default.contextMax` came back undefined and
`getContextSizeOptions` bailed on its first guard, dropping the Context Size
control from the model picker entirely.

The budget side of that contract kept working, which turned a missing dropdown
into a billing problem: `modelMetadataFetcher` still raises the prompt budget to
the full context window whenever a `long_context` tier is present, on the stated
assumption that `defaultContextMax` holds users at the default tier. With
`contextMax` undefined, requests ran unclamped against the full window and
`applyContextSizeOverride` had nothing to clamp to.

Since this is a server-side rename, older clients are affected too, which is why
rolling back did not help. The agent host normalizer in `agentModelPricing.ts`
already accepts both spellings, which is why the Copilot harness kept the control
while the in-editor path lost it. Accept both here as well: this normalizer is
shared by CAPI `/models`, the `@github/copilot` SDK and the cloud agents
endpoint, which move on independent cadences.

Fixes #330481
2026-08-13 12:49:47 -04:00
vritant24andCopilot 2f7f56e135 Fix empty Responses tool schemas
Emit an explicit object schema for parameterless function tools so strict
OpenAI-compatible Responses endpoints accept the request.

Fixes #330610

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-13 08:29:01 -07:00
Ulugbek AbdullaevandCopilot 65a921abc4 markdown: refactor: delegate task checkbox toggles to setTaskCheckboxChecked (#330441)
* markdown: refactor: use setTaskCheckboxChecked for task toggles

The webview hand-rolled the task checkbox source edit: it looked up the list
item offset, computed the '[ ]' range and applied a StringEdit itself. That
logic now lives in EditorModel.setTaskCheckboxChecked, so delegate to it.

This also fixes toggling in read-only mode. The old handler bailed out on
model.readonlyMode and then routed through applyEdit, which is itself
read-only gated, so clicking a rendered checkbox in read-only mode did
nothing. Read-only in this editor means markers hidden and no text editing
while selection and copy still work - a rendering and interaction mode
rather than a document permission - so setTaskCheckboxChecked deliberately
bypasses that gate while applyEdit, applyEditForSelection and
materializePendingParagraph stay gated.

Requires a @vscode/markdown-editor release containing
setTaskCheckboxChecked (microsoft/vscode-packages#253).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: e9ec8741-eb31-42f3-9e0c-13e2add8e02d

* markdown: chore: update @vscode/markdown-editor to 0.0.2-70

Picks up `EditorModel.setTaskCheckboxChecked`, which the task checkbox
handler in `markdown-editor-src/editor.ts` delegates to.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: e9ec8741-eb31-42f3-9e0c-13e2add8e02d

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: e9ec8741-eb31-42f3-9e0c-13e2add8e02d
2026-08-13 14:10:10 +05:00
Vijay Upadya 8bed878286 Re enablenew TAS assignments endpoint with proxy-aware transport fix (#330389)
* Revert "Revert new TAS endpoint changes (#330175)"

This reverts commit f30e3f3600.

* Re-land new TAS assignments endpoint with proxy-aware transport + tas-call telemetry

* bump remote + remote/web to tas-client 0.4.3

* Add tests and feedback update
2026-08-13 05:37:11 +00:00
Dileep Yavanmandha e779b1fe20 Fix missing tool outputs when reusing Responses API state (#330510)
Investigation#1
2026-08-12 23:21:55 +00:00
8b5471c4c8 Enhance modern UI theming and improve tab styles (#330428)
* feat: add modern tab colors and update styles for improved UI theming

Co-authored-by: Copilot <copilot@github.com>

* feat: enhance modern UI with updated tab backgrounds and improved activity indicators

Co-authored-by: Copilot <copilot@github.com>

* feat: add modern activity bar colors and update styles for improved UI theming

Co-authored-by: Copilot <copilot@github.com>

* feat: enhance modern UI with new foreground colors for activity bar and tabs

Co-authored-by: Copilot <copilot@github.com>

* feat: update modern activity bar colors for improved UI consistency

* feat: enhance modern UI theming with updated color definitions and improved tab styles

Co-authored-by: Copilot <copilot@github.com>

* feat: add modern tab action background colors for improved UI theming

Co-authored-by: Copilot <copilot@github.com>

* feat: update modern activity bar colors across themes for improved UI consistency

* feat: enhance modern UI theming with new selected action background for tabs and session view

Co-authored-by: Copilot <copilot@github.com>

* fix: add missing newline at end of sessionBarStyles test file

---------

Co-authored-by: mrleemurray <mrleemurray@users.noreply.github.com>
Co-authored-by: Copilot <copilot@github.com>
2026-08-12 12:50:15 +00:00
Vritant Bhardwaj 5aa9070bc9 Merge pull request #330294 from microsoft/fix/copilot-git-non-file-uri
copilot: skip Git fallback for virtual resources
2026-08-11 10:27:57 -07:00
vritant24andCopilot f107b98244 Copilot: skip Git fallback for virtual resources
Avoid treating unmatched virtual resources as local filesystem paths when
looking up repository remotes.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-11 09:47:47 -07:00
Vritant Bhardwaj e8875a9361 Merge pull request #330279 from microsoft/agents/investigate-reproducible-tests
agentHost: combine streamed BYOK reasoning chunks
2026-08-11 09:14:41 -07:00
Ulugbek AbdullaevandCopilot 1d7fd7f6ff nes: fix: allow configuring Xtab context lines (#330269)
Remove the team-only value restriction from the hidden advanced Xtab nLinesAbove and nLinesBelow settings. Extend external-user coverage with the requested 0 and 7 values.

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

Copilot-Session: 97f1135d-4a33-4139-ab2c-9cb8045ece70
2026-08-11 16:04:38 +00:00
vritant24 3ee07c3b43 agentHost: preserve BYOK reasoning summary boundaries
Propagate Responses summary-part completion markers through the language model thinking stream so transport chunks remain combined without merging distinct semantic summaries.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-11 08:48:37 -07:00
vritant24 8a1af313e6 agentHost: combine streamed BYOK reasoning chunks
Keep transport-level thinking deltas in one reasoning summary entry while preserving explicit multi-part summaries. This prevents Copilot CLI from rendering each DeepSeek reasoning chunk as a separate line.\n\nFixes #329873\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-11 08:35:23 -07:00
Dirk Bäumer 8a531921d0 Merge pull request #330197 from microsoft/dbaeumer/eslint-10
Update to ESLint 10
2026-08-11 17:06:12 +02:00
Ulugbek AbdullaevandCopilot a3d4092eef nes: fix: allow external users to configure inline edit settings (#330256)
copilot: fix: allow external users to configure inline edit settings

Remove the team-only value restriction from selected hidden advanced inline edit settings while preserving their keys, defaults, validators, and experiment behavior. Add coverage that verifies an external user can configure all ten settings.

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

Copilot-Session: 97f1135d-4a33-4139-ab2c-9cb8045ece70
2026-08-11 14:29:23 +00:00
Dirk Baeumer 53a329772b Merge branch 'main' into dbaeumer/eslint-10 2026-08-11 15:59:08 +02:00
Lee Murrayandmrleemurray e85b5d14ba Add surface.border property to various color themes for modern UI support (#330216)
Co-authored-by: mrleemurray <mrleemurray@users.noreply.github.com>
2026-08-11 10:54:46 +00:00
Ulugbek Abdullaev f64589a9d5 update md editor to latest (#330194) 2026-08-11 10:29:30 +00:00
Dirk Baeumer 0edf2a0693 Merge branch 'main' into dbaeumer/eslint-10 2026-08-11 11:50:01 +02:00
Alex Ross af600487b1 Update grammars (#330193) 2026-08-11 09:10:49 +00:00
Dmitriy VasyuraandCopilot b4a4fb42bb Enable Mermaid Legacy Tool Reference Proposal (#330189)
Enable Mermaid legacy tool reference proposal

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-11 09:01:47 +00:00
Vijay Upadya f30e3f3600 Revert new TAS endpoint changes (#330175)
* Revert "New TAS assignments endpoint updates (lifecycle, readiness, disposal) (#329736)"

This reverts commit c780ea9613.

* Revert "Add new exp TAS assignments endpoint (/api/v1/assignments) alongside legacy TAS (#329653)"

This reverts commit 58dc612992.

* Fix lockfile: add MIT license fields to reverted tas-client entries
2026-08-11 06:42:09 +00:00
Osvaldo OrtegaandCopilot cd5814553e Remove all backend v1 code for Copilot cloud sessions provider (#330007)
* Agent Host changes for osortega/agents/remove-all-the-code-for-backend-v1-of

* Preserve pending cloud tasks until workspace opens

Only consume cross-window task deep links after Git reports the matching repository, preventing the source window from clearing shared pending state.

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

* Migrate cloud session state from pull request URIs

PR-backed cloud tasks are listed under a stable /task/<id> resource and report the /<prNumber> URI they were previously listed under, so archived, pinned and read state migrates forward instead of being orphaned.

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

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-10 18:36:38 -07:00
Connor Peet a11e4a544c Remove remaining deprecated URL parsing
Migrate the server, remote CLI, browser integration harness, and Seti update script from url.parse() to the WHATWG URL API while preserving repeated-query handling and rejecting malformed request targets.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-10 13:52:11 -07:00
Logan Ramos b30dc6c77e Remove fake prompt discount probe (#330058)
* Remove fake prompt discount probe

* fix package lock
2026-08-10 20:24:44 +00:00
Vritant Bhardwaj 2748e2bdf3 Merge pull request #330038 from microsoft/agents/unit-test-vscode-issue-329963
chat: preserve streamed response text when tool_calls delta is empty
2026-08-10 11:37:30 -07:00
vritant24andCopilot ba6b3cd6e1 chat: preserve streamed content when tool_calls delta is empty
An empty `tool_calls: []` array in a chat-completions SSE delta is truthy, so SSEProcessor entered the tool-call branch and skipped the content path, silently dropping the assistant text. Backends like vLLM attach an empty array to every content delta, which lost the entire response.

Guard the branch on `tool_calls?.length` so empty arrays fall through to normal content handling.

Fixes #329963

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-10 10:56:46 -07:00