Skip to content

/planmode command works in non-Claude engine chats with Claude-specific output #216

@nathanschram

Description

Bug

/planmode and /planmode off work in Codex (and presumably other non-Claude) engine chats, producing Claude-specific output referencing --permission-mode plan and --permission-mode acceptEdits flags that don't apply to Codex.

Reproduction

  1. Open the Codex engine chat (ut-dev: codex)
  2. Send /planmode
  3. Response: plan mode on for this chat. new sessions will use --permission-mode plan.
  4. Send /planmode off
  5. Response: plan mode off for this chat. new sessions will use --permission-mode acceptEdits.

Expected

Either:

  • a) /planmode is disabled for non-Claude engines and responds with "Plan mode is only available for Claude Code" or similar
  • b) The command is engine-aware and shows the equivalent for each engine (e.g. for Codex: approval policy full auto/safe)

Context

  • The /config home page correctly shows "Approval policy" instead of "Plan mode" for Codex
  • But the standalone /planmode command doesn't check the current engine — it always applies Claude Code permission mode logic
  • --permission-mode plan and --permission-mode acceptEdits are Claude Code CLI flags; Codex uses --ask-for-approval never|untrusted instead
  • Setting plan mode in a Codex chat could silently pass invalid flags to the Codex CLI, or be silently ignored — either way it's confusing

Affected files

  • src/untether/telegram/commands/planmode.pyPlanModeCommand doesn't check engine type
  • The /config UI correctly gates this (shows "Approval policy" for Codex), but the standalone command bypasses that gate

Version

v0.35.0rc11 — found during Codex integration testing

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions