You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: Pi's injected T3 tool_call hook forces Full access and blocks Pi extensions from handling approvals in subagents #35609
I searched existing issues and did not find a duplicate.
I included enough detail to reproduce or investigate the problem.
Area
apps/server
Steps to reproduce
Configure a Pi extension that implements an auto permission/command-approval policy (Pi itself deliberately leaves permission policies to extensions).
Open a parent thread using Claude Code (or Codex) in Auto runtime mode.
Ask the parent thread to delegate a task that runs shell commands to Pi via delegate_task:
Leaving runtimeMode inherited ("inherit"), or
Explicitly requesting runtimeMode: "full-access" so Pi can bypass T3's tool_call confirmation hook and use the user's extension.
Expected behavior
A user running a parent agent in Auto should be able to delegate tasks to Pi without either:
prompting the human on every single shell/non-edit tool call, or
having to escalate the entire parent thread to Full access just so Pi can reach full-access and let the user's Pi extension enforce its own auto policy.
Actual behavior
In pi-t3-mcp-extension.ts (packages/provider-pi/src/server/mcpExtensionSource.ts), T3 Code's pi.on("tool_call", ...) listener only returns early when mode === "full-access". In auto-accept-edits (and approval-required), it calls ctx.ui.confirm(...) for every non-read-only, non-file-change tool (e.g. bash or custom tools), blocking/overriding user Pi extensions that try to implement auto approval.
When the parent thread is in Auto:
delegate_task(..., runtimeMode: "full-access") fails with runtime_mode_escalation_denied (Child runtime mode full-access is broader than parent mode auto.).
Inherited runtimeMode steps down to auto-accept-edits, which triggers manual confirmation prompts on every shell/tool call.
Because Pi does not offer an auto mode in PI_PRESENTATION (supportedRuntimeModes: ["approval-required", "auto-accept-edits", "full-access"]), Pi cannot be used unattended as a subagent from an Auto parent thread—even when the user installed a Pi extension specifically to provide auto approval.
(Note: #30538 / PR #30552 only step auto down to auto-accept-edits, which still prompts on every shell command and still prevents user extensions from running without full-access.)
Thanks for writing this up. It asks for new behaviour rather than reporting a defect, so it does not belong in the bug tracker and I'm closing it as not planned here. Feature ideas are discussed in Discussions: please post it there.
Activity
juliusmarminge commentedon Nov 12, 2026
Thanks for writing this up. It asks for new behaviour rather than reporting a defect, so it does not belong in the bug tracker and I'm closing it as not planned here. Feature ideas are discussed in Discussions: please post it there.