Skip to content

[pull] main from microsoft:main#1059

Merged
pull[bot] merged 18 commits intocode:mainfrom
microsoft:main
Mar 22, 2026
Merged

[pull] main from microsoft:main#1059
pull[bot] merged 18 commits intocode:mainfrom
microsoft:main

Conversation

@pull
Copy link

@pull pull bot commented Mar 21, 2026

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

osortega and others added 17 commits March 19, 2026 17:27
* Re-register run_in_terminal tool when sandbox settings change

When the terminal sandbox setting is toggled at runtime, the
run_in_terminal tool's schema and description were not updated because
the tool data was only computed once at startup. This meant the model
never learned about requestUnsandboxedExecution when sandbox was
enabled after startup.

Fix by using a MutableDisposable to manage the tool registration and
re-registering whenever sandbox-related settings, network domains, or
trusted domains change.

Fixes #303714

* Fix race condition in run_in_terminal tool re-registration and add refresh tests

Guard _registerRunInTerminalTool against stale async resolutions using a monotonically increasing version counter. Export ChatAgentToolsContribution for testability. Add integration tests verifying tool data refreshes on config and trusted domain changes.
Add per-invocation icon support to tool invocations via
`IPreparedToolInvocation.icon` and `IChatToolInvocation.icon`.
The terminal tool sets the icon to `terminal-secure` when sandbox
is active, or `terminal` otherwise. The thinking content part and
subagent content part use this icon when rendering, falling back
to the existing heuristic for tools without a registered icon.

Also removes the $(lock) theme icon prefix from sandbox invocation
messages since the icon now communicates the sandbox state.
* Adopt new codicons version

* terminal: use terminal-secure codicon for sandboxed commands

Add per-invocation icon support to tool invocations via
`IPreparedToolInvocation.icon` and `IChatToolInvocation.icon`.
The terminal tool sets the icon to `terminal-secure` when sandbox
is active, or `terminal` otherwise. The thinking content part and
subagent content part use this icon when rendering, falling back
to the existing heuristic for tools without a registered icon.

Also removes the $(lock) theme icon prefix from sandbox invocation
messages since the icon now communicates the sandbox state.

* Fix unit test

* Review feedback
@pull pull bot added the ⤵️ pull label Mar 21, 2026
@pull pull bot merged commit e428f03 into code:main Mar 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants