Commit Graph

1433 Commits

Author SHA1 Message Date
Alexandru Dima
ca117fbb4f Accept "Command produced no output" when shell integration is off (#303866)
Accept "Command produced no output" when shell integration is off (#303865)
2026-03-22 14:36:27 +00:00
Alex Dima
487646cee8 Attempt to cover up the run_in_terminal tool not being registered quickly 2026-03-22 10:50:35 +01:00
Alexandru Dima
5563927f89 Fix terminal output capture: prevent premature idle detection and handle partial command echoes
- setupRecreatingStartMarker returns IDisposable to stop marker recreation
  before sending commands (prevents marker jumping on PSReadLine re-renders)
- noneExecuteStrategy waits for cursor to move past start line after sendText
  before starting idle detection (prevents end marker at same line as start)
- findCommandEcho supports suffix matching for partial command echoes from
  wrapped getOutput() results (shell integration ON with long commands)
- Suffix matching requires mid-word split to avoid false positives on output
  that happens to be a suffix of the command (e.g. echo output)
- Integration tests: use ; separator on Windows, add && conversion test,
  handle Windows exit code quirks with cmd /c
2026-03-22 00:46:48 +01:00
Alex Dima
4ed68ee36f Fix slash history test 2026-03-21 23:23:32 +01:00
Alex Dima
436b09abc3 Fix sandbox tests for Linux: handle different shell path and error message
- Handle /usr/bin/bash (Linux) vs /bin/bash (macOS) in /tmp write test
- Handle 'Read-only file system' (Linux) vs 'Operation not permitted' (macOS)
- Add 'Read-only file system' to outputLooksSandboxBlocked heuristic
- Replace newlines with spaces (not empty) to handle terminal wrapping
- Extract outputLooksSandboxBlocked as exported function with unit tests
2026-03-21 22:36:04 +01:00
Alex Dima
f4644120bc Cover case where the command is duplicated in stripCommandEchoAndPrompt 2026-03-21 22:28:19 +01:00
Alex Dima
f4c042bfc8 Relax some tests when shell integration is off 2026-03-21 19:56:04 +01:00
Alex Dima
865568dbbc fix: Linux CI sandbox prereqs, platform-aware tests, broader prompt stripping
- Add bubblewrap and socat to Linux CI apt-get install
- Make sandbox test assertions platform-aware (macFileSystem vs linuxFileSystem)
- Make /etc/shells test accept both macOS and Linux first-line format
- Broaden wrapped prompt fragment regex to handle path chars (ts/testWorkspace$)
- Fix continuation pattern to match user@host:path wrapped lines
- Apply stripCommandEchoAndPrompt to getOutput() in BasicExecuteStrategy
  (basic shell integration lacks reliable 133;C markers so getOutput()
  can include command echo)
- Keep RichExecuteStrategy getOutput() unstripped (rich integration
  has reliable markers)
2026-03-21 19:06:50 +01:00
Alex Dima
34dd7810b7 fix: strip command echo and prompt from terminal output (#303531)
Prevent sandbox-wrapped command lines from leaking as output when

commands produce no actual output. Adds stripCommandEchoAndPrompt()

to isolate real output from marker-based terminal buffer captures.

Also adds configurable idle poll interval and shell integration

timeout=0 support for faster test execution.
2026-03-21 17:43:25 +01:00
Kyle Cutler
3f4f33b7da Fix close tracking in browser API (#303304) 2026-03-19 13:47:36 -07:00
Kyle Cutler
0bc4bad6ef Proposed browser API for debug support (#300577)
* Proposed browser API for debug support

* build, feedback

* Web stubs

* fix

* close guard

* fixes, add close()

* clean

* Fixes, tests

* lint

* Simplfiy

* feedback
2026-03-13 16:32:58 +01:00
Matt Bierner
e9b82791e6 Commit other npmrc files 2026-03-10 20:56:09 -07:00
Don Jayamanne
5b38f1d529 Update default model selection to prioritize 'copilot' vendor in ExtHostLanguageModels (#298903)
* Update default model selection to prioritize 'copilot' vendor in ExtHostLanguageModels

* Fix tests

* Fix tests
2026-03-06 21:48:45 +11:00
Don Jayamanne
284bd98ce3 Add support for custom chat agents in the API (#298227)
* Add support for custom chat agents in the API

- Introduced `chatCustomAgents` proposal in extensions API.
- Implemented methods to handle custom agents in `MainThreadChatAgents2`.
- Added `ICustomAgentDto` interface and related functionality in extHost.
- Created new type definitions for custom agents in `vscode.proposed.chatCustomAgents.d.ts`.

* Filter custom agents by visibility before pushing to the proxy

* Refactor onDidChangeCustomAgents to use direct event listener

* Update custom agent tools property to allow undefined values

* Add chatCustomAgents to enabledApiProposals in package.json

* update

* update

* support skills

* support instructions

* update

* update

---------

Co-authored-by: Martin Aeschlimann <martinae@microsoft.com>
2026-03-04 13:38:47 +00:00
Alex Ross
856ea291a5 No need to throw when an element with the same ID comes in (#299154)
* No need to throw when an element with the same ID comes in
Fixes microsoft/vscode-pull-request-github#8073

* Fix tests
2026-03-04 13:50:35 +01:00
Dmitriy Vasyura
e395fe2993 Finalize env.isAppPortalable API proposal (#297177) 2026-02-24 11:43:00 -08:00
Matt Bierner
2fedd2e043 Adopt esbuild for a few more extensions
- extension-editing
- terminal-suggest
- tunnel-forwarding
- php language features
2026-02-18 15:20:02 -08:00
Dmitriy Vasyura
fa6cfe12c6 Metered network connections support (#288919)
Includes public API, user setting, status bar icon and a new service to support metered network connections.
Updates code in various areas performing automated actions using network to delay/pause network operations while network connection is being metered.
2026-02-06 14:52:14 -08:00
Christof Marti
2fd6a33c04 Surface power API 2026-02-05 16:57:40 +01:00
Alex Ross
9519571a4a Skip flaky test " setTextDocumentLanguage for notebook cells" (#293072) 2026-02-05 11:04:16 +00:00
Matt Bierner
ee01088b74 Update roots 2026-01-30 13:12:58 -08:00
Matt Bierner
0d9a2ef2b0 Add explicit rootDirs 2026-01-30 11:07:53 -08:00
Alex Ross
f89c803449 Try once again to fix the element already registered bug (#290795)
Fixes microsoft/vscode-pull-request-github#8073
2026-01-27 18:11:33 +01:00
Sandeep Somavarapu
d4d37b83e0 Add proposed API support for agent sessions workspace (#290385)
* Add proposed API support for agent sessions workspace

* add access to agentSessionsWorkspace proposed api
2026-01-26 16:05:36 +00:00
Dmitriy Vasyura
aa19df565f Portable mode improvements and bug fixes (#287063)
Disabled protocol handlers and registry updates on Windows in portable mode.
Added API proposal to detect if VS Code is running in portable mode from extensions.
Skipped protocol redirect in GitHub authentication in portable mode.
2026-01-24 13:22:53 +01:00
Anthony Kim
acb22942b0 Remove winpty support (#289025)
* Bump node-pty to 1.2.0-beta.7

* Deprecate TerminalSettingId.WindowsEnableConpty setting

* Remove windowsEnableConpty instead of deprecating

* Remove WINPTY from ps.ts

* Remove winpty from appropriate comments

* Remove winpty from IProcessReadyWindowsPty

* Remove from classifier.json. TODO on resize for node-pty

* Try adding option to test

* Add reference to issue
2026-01-21 08:32:11 -08:00
Don Jayamanne
2fd8c70fa1 mcp: expose MCP server definitions to ext host (#288798)
* Expose MCP server definitions to ext host

* Fixes

* Update src/vs/workbench/api/common/extHostTypeConverters.ts

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

* Update src/vs/workbench/api/browser/mainThreadMcp.ts

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

* Address review comments

* address review comments

* Reuse McpServerDefinition.Serialized instead of custom DTOs (#289165)

* Initial plan

* Reuse McpServerDefinition.Serialized instead of custom DTO interfaces

Co-authored-by: DonJayamanne <1948812+DonJayamanne@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: DonJayamanne <1948812+DonJayamanne@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
2026-01-20 14:45:55 -08:00
Dmitriy Vasyura
fa6c146385 Finalize quickInputButtonLocation API proposal 2026-01-07 17:35:45 +01:00
Tyler James Leonhardt
cbc91ee43b Revert "Finalize quickPickButtonLocation API proposal" (#285984) 2026-01-05 11:29:58 -08:00
Dmitriy Vasyura
d9835cfa08 Finalize quickInputButtonLocation API proposal 2025-12-18 19:36:56 -08:00
Dmitriy Vasyura
56555a8bf1 Finalize quickPickItemResource API proposal (#283877) 2025-12-16 19:11:02 +00:00
Johannes Rieken
d13c32e27f disable flakly test again https://github.com/microsoft/vscode/issues/254042 (#283836) 2025-12-16 15:45:42 +00:00
Alex Ross
950ca05d5c Reapply element already registered race condition fix (#283079)
Fixes microsoft/vscode-pull-request-github#8073
2025-12-12 18:01:41 +01:00
dependabot[bot]
7971753268 Bump node-forge from 1.3.1 to 1.3.2 in /extensions/vscode-api-tests (#279673)
Bumps [node-forge](https://github.com/digitalbazaar/forge) from 1.3.1 to 1.3.2.
- [Changelog](https://github.com/digitalbazaar/forge/blob/main/CHANGELOG.md)
- [Commits](https://github.com/digitalbazaar/forge/compare/v1.3.1...v1.3.2)

---
updated-dependencies:
- dependency-name: node-forge
  dependency-version: 1.3.2
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-08 18:40:24 +00:00
Johannes Rieken
5d52b31d8d understand why tests fails (#282002)
https://github.com/microsoft/vscode/issues/254042
2025-12-08 17:18:19 +00:00
Alex Ross
653d30ab18 Revert "Fix element already registered (#281000)" (#281278)
* Revert "Fix element already registered (#281000)"

This reverts commit ca3f2212d1.

* skip test
2025-12-04 09:43:55 -08:00
Alex Ross
472dee5115 Another fix for "element with id not registered" error (#281269)
Fixes microsoft/vscode-pull-request-github#8073
2025-12-04 16:49:41 +00:00
Alex Ross
ca3f2212d1 Fix element already registered (#281000)
Fixes microsoft/vscode-pull-request-github#8073
2025-12-03 09:59:37 -08:00
Don Jayamanne
2ad979732c Remove unwanted console.logs (#277374) 2025-11-14 11:37:45 +01:00
Matt Bierner
723aa849c9 Convert gulpfiles to modules
Makes a pass through our top level gulpfiles to convert them to modules
2025-11-11 15:28:50 -08:00
Daniel Imms
0f2bcf765a Merge branch 'main' into tyriar/274723_platform_terminal__api 2025-11-10 06:57:41 -08:00
Daniel Imms
b2481854e8 Fix test expectations 2025-11-10 06:57:11 -08:00
Don Jayamanne
6644d4f0cb Ensure node-pty module is accessbile for chat extension (#276388)
* Ensure node-pty module is accessbile for chat extension

* Update extensions/vscode-api-tests/src/singlefolder-tests/chat.test.ts

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

* Update extensions/vscode-api-tests/src/singlefolder-tests/chat.test.ts

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

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-11-10 04:02:15 +01:00
Daniel Imms
80ebe13f31 Remove as any in vscode-api-tests
Part of #269213
2025-11-02 01:21:53 -07:00
Alexandru Dima
65b22997d7 Convert flaky API tests to unit tests (#273398)
Convert flaky API test to unit test (#253863 , #254041)

I maintain my conviction that there is an unrelated run-away API test which steals focus while these tests execute which then leads to these tests failing, since the undo command is sensitive to the current focused editor.
2025-10-26 15:11:46 +01:00
Benjamin Pasero
f77f4c50cd eng - disable start debugging test that is flaky (#242033) (#272273) 2025-10-20 15:24:28 +02:00
Dmitriy Vasyura
bfba6b040c Add toggle support for QuickInput/QuickPick, resourceUri support for QuickPickItem (#271598)
* Add quickPickItemResource API proposal

* Transfer resourceUri from extension host to main thread.

* Make proposed API checks consistent.

* Process resourceUri

* Fix up resourceUri mapping logic

* API proposal

* Transfer toggles from extension host to main thread

* Support Folder icon, refactor label/description derivation.

* Update

* Update API proposal per API review

* Update transfer logic per API changes

* Move toggles to the base input interface

* Handle toggle button type

* Fix up

* Updates

* Propagate checked state, dispose removed toggles.

* Nit

* Expand icons

* Feedback/updates

* Added comments, PR feedback

* Updates

* Revert some change, add typings and unit-tests to converters.

* Add a quick pick test for resourceUri

* Test updates
2025-10-18 15:57:07 -07:00
Rob Lourens
ec8586ef25 Add isModelProxyAvailable (#271872)
* Add isModelProxyAvailable

* tests
2025-10-16 21:11:11 -07:00
Matt Bierner
1c35a4d05c Enforce single quote string usage in extension tests
Single quoted string usage is already enforced everywhere except our tests. Having this inconsistent style can confuse contributors and code generation

Starting with converting over tests in the `extensions` dir
2025-10-15 01:51:43 -07:00
Matt Bierner
98b069c041 Work towards getting isolated built-in extension compiles
For #271167

This makes it so our built-in extensions can mostly be built using `tsc` on the command line. Previously the extensions were picking up a lot of typing info from the root `node_modules` that meant they weren't truly independent
2025-10-13 11:03:20 -07:00