Skip to content

[Bug]: Claude provider turn fails with "turn/setPermissionMode failed" when permission mode is Auto #4495

Description

@abdellahjebar

Before submitting

  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.

Area

apps/web

Steps to reproduce

  1. Open a project in T3 Code with Claude Sonnet 4.6 selected as the model
  2. Set the permission mode dropdown (next to the model selector) to "Auto"
  3. Send any prompt
  4. Turn fails immediately
  5. Retry sending in the same thread — fails again with the same error

Expected behavior

The turn should start normally and Claude should respond, the same way it does under "Full access" permission mode.

Actual behavior

The turn fails immediately with a "Provider turn start failed" banner reading "turn/setPermissionMode failed". This happens consistently and only when permission mode is set to "Auto" — switching to "Full access" or "Build" works fine on the same model/thread.

Impact

Major degradation or frequent failure

Version or commit

0.0.29-nightly.20260724.896 (Nightly channel)

Environment

Windows 11, Claude Sonnet 4.6 via Claude Code adapter (@anthropic-ai/claude-agent-sdk@0.3.170 per pnpm-lock.yaml), local claude CLI v2.1.146, authenticated via claude.ai OAuth (Pro plan).

Logs or stack traces

Error tag "turn/setPermissionMode" traces to apps/server/src/provider/Layers/ClaudeAdapter.ts, toRequestError(input.threadId, "turn/setPermissionMode", cause) around line ~3759-3765, likely triggered via the runtimeModeToPermission mapping at ~line 3510-3515 which passes SDK permissionMode: "auto". That value is present in the pinned SDK version's own type declarations (0.3.170), so this doesn't look like a simple type/version mismatch — possibly rejected by the spawned `claude` CLI binary itself over the control protocol. Have not pulled the local diagnostics trace file to confirm the exact underlying `cause`.

Screenshots, recordings, or supporting files

No response

Workaround

Switching permission mode to "Full access" or "Build" before sending resolves it immediately on the same thread/model.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething is broken or behaving incorrectly.needs-triageIssue needs maintainer review and initial categorization.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions