Skip to content

estack-drive-cli-agent: '-a never' no longer exists on codex exec (CLI 0.147.0), every recipe fails #24

Description

@ElliotDrel

What happened

SKILL.md prescribes -a never on every codex exec call, in both the "quick question" and "long or write-capable task" recipes:

codex exec --skip-git-repo-check -a never "<prompt>" < /dev/null

On codex-cli 0.147.0 that flag no longer exists on exec, and the call dies immediately:

Usage: codex exec [OPTIONS] [PROMPT]
       codex exec [OPTIONS] <COMMAND> [ARGS]

For more information, try '--help'.

Exit is non-zero with no explanation of which flag was wrong, so it reads like a malformed prompt rather than a stale flag. Dropping -a never makes the identical command work.

Why the flag is gone

codex exec --help on 0.147.0 lists no -a / --ask-for-approval. It has --approve-for-me and --dangerously-bypass-approvals-and-sandbox, but no way to spell "never". That is consistent with exec being non-interactive by definition, so there is nothing for the old flag to do and nothing is lost by removing it.

Suggested fix

Drop -a never from both recipes in SKILL.md. The working shapes are:

# read-only question
codex exec --skip-git-repo-check "<prompt>" < /dev/null

# write-capable
codex exec --skip-git-repo-check -C "<workdir>" --sandbox workspace-write \
  -o "<scratchpad>/codex-result-<taskname>.md" "<prompt>" < /dev/null

Both verified working on 0.147.0.

Worth checking references/codex-exec.md in the same pass, since it is cited as the place to read before anything non-trivial and may carry the same flag.

Two smaller things noticed while confirming this, both optional:

  1. Reasoning effort is worth calling out. ~/.codex/config.toml can set model_reasoning_effort globally (mine defaults to low), and nothing in the recipes overrides it, so a delegated task silently runs at whatever the config says. Passing -c model_reasoning_effort="medium" explicitly makes the call self-describing.
  2. -p, --profile <name> layers $CODEX_HOME/<name>.config.toml over the base config. That is a cleaner way to pin model plus effort per task type than repeating -c flags, and might be worth a mention.

The hard rules about closing stdin and running through Git Bash rather than PowerShell were both correct and both mattered.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions