Skip to content

Claude Code harness: AskUserQuestion and plan approval never reach the user #4766

Description

@Sayt-0

Overview

On a claude-code harness agent, Claude Code cannot ask the user anything mid-turn. The harness runs the CLI with --print, where AskUserQuestion, EnterPlanMode and ExitPlanMode are disabled: Claude Code asks in plain text and ends the turn.

CLI arguments (Claude Code 2.1.312) AskUserQuestion available Result
harness arguments today no question asked in plain text
plus --permission-prompt-tool mcp__<server>__<tool> yes question sent to the permission tool, answer accepted

Proposed solution

  • Serve a permission prompt tool from a loopback MCP server for each turn (--mcp-config, --permission-prompt-tool). Only AskUserQuestion and ExitPlanMode reach it; other tools still run without asking.
  • Turn them into elicitation forms, and keep plain text questions when nobody can answer.
  • TUI: support multi-select enums (type: array) and titled choices (oneOf), MCP spec shapes the ACP bridge already accepts.

A fix is ready; a PR can follow if the approach suits.

Activity

  1. added
    area/agentFor work that has to do with the general agent loop/agentic features of the app
    area/mcpMCP protocol, MCP tool servers, integration
    area/tuiFor features/issues/fixes related to the TUI
    on Oct 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/agentFor work that has to do with the general agent loop/agentic features of the apparea/mcpMCP protocol, MCP tool servers, integrationarea/tuiFor features/issues/fixes related to the TUI

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions