Copilot Chat: nested runSubagent calls rejected 3 levels deep even when target agent is in the calling agent's agents: allow-list
- Dominant language
- TypeScript
- Stars
- 193k
- Forks
- 42.4k
- PR merge metrics
- PR metrics pending
Description
Type: Bug
1. Create three custom chat modes (.agent.md) forming a nesting chain:
A (root) -> B -> C, where A's allow-list permits calling B, and
B's allow-list permits calling C.
2. Select A in the agent picker as the active chat mode.
3. Ask A to call B via the subagent tool. This succeeds (1 level deep).
4. Inside B, call C via the subagent tool (C is listed in B's own
allow-list). This fails with:
"Requested agent 'C' is not allowed by the current agent."
5. Confirm "Allow Invocations From Subagents" is enabled the whole
time - toggling it has no effect on the result.
6. Add C to A's (the root's) allow-list too, then repeat step 4.
Still fails with the same error, even though C is now listed in
both A's and B's allow-lists.
Result: any subagent call at nesting depth 3 or deeper is rejected,
regardless of which agent's allow-list contains the target. This
breaks coordinator -> worker -> specialist agent architectures, even
though nested subagent calls and per-agent allow-lists both appear to
be supported features.
I believe the issue started around the 1.136.1 build because it worked about a week or two ago.
VS Code version: Code 1.136.2 (88e44fa0e00b08f7758b4f6d05632e4fd5e4df6f, 2026-09-04T21:40:42Z)
OS version: Windows_NT x64 10.0.26200
Modes:
System Info
|Item|Value|
|---|---|
|CPUs|Intel(R) Core(TM) Ultra 7 265H (16 x 3686)|
|GPU Status|2d_canvas: enabled
GPU0: VENDOR= 0x8086, DEVICE=0x7d51 [Intel(R) Arc(TM) Pro 140T GPU (32GB)], DRIVER_VENDOR=Intel, DRIVER_VERSION=32.0.101.8517 *ACTIVE*
GPU1: VENDOR= 0x10de, DEVICE=0x2db9 [NVIDIA RTX PRO 500 Blackwell Generation Laptop GPU], DRIVER_VERSION=32.0.15.9658
GPU2: VENDOR= 0x1414, DEVICE=0x008c [Microsoft Basic Render Driver], DRIVER_VERSION=10.0.26100.8875
Machine model name:
Machine model version:
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
trees_in_viz: disabled_off
video_decode: enabled
video_encode: enabled
webgl: enabled
webgpu: enabled
webnn: disabled_off|
|Load (avg)|undefined|
|Memory (System)|63.43GB (30.71GB free)|
|Process Argv|--crash-reporter-id b822c74a-d5f9-4896-b1f6-099fc98c1dc5|
|Screen Reader|yes|
|VM|0%|
Extensions (12)
Name|Identifier|Author|Version
---|---|---|---
Claude Code for VS Code|anthropic.claude-code|Anthropic|2.1.266
Markdown Preview Github Styling|bierner.markdown-preview-github-styles|bierner|2.2.0
Rainbow CSV|mechatroner.rainbow-csv|mechatroner|3.24.1
C# Dev Kit|ms-dotnettools.csdevkit|ms-dotnettools|3.20.207
C#|ms-dotnettools.csharp|ms-dotnettools|2.140.9
.NET Install Tool|ms-dotnettools.vscode-dotnet-runtime|ms-dotnettools|3.1.0
Python Debugger|ms-python.debugpy|ms-python|2026.6.0
Python|ms-python.python|ms-python|2026.4.0
Pylance|ms-python.vscode-pylance|ms-python|2026.3.1
Python Environments|ms-python.vscode-python-envs|ms-python|1.36.0
PowerShell|ms-vscode.powershell|ms-vscode|2025.4.0
Markdown All in One|yzhang.markdown-all-in-one|yzhang|3.6.3
A/B Experiments
```
permission_prompt_control:1332567
ccr_pr_nudge_control:1319470
vsc_wsm_t:1340632
eh853263:1370294
1g5a5742:1379227
```
Contributor guide
Assessment
This issue has not been assessed yet.