codex icon indicating copy to clipboard operation
codex copied to clipboard

In codex CLI, strange tool usage keeps repeating.

Open ginishuh opened this issue 1 year ago • 7 comments

What version of Codex is running?

codex-cli 0.60.1

What subscription do you have?

Pro

Which model were you using?

gpt-5.1-codex-max

What platform is your computer?

Linux 6.6.87.2-microsoft-standard-WSL2 x86_64 x86_64

What issue are you seeing?

• Ran git status -sb • Ran echo "All set." └ All set.

• Ran true └ (no output)

• Ran echo 'Done again.' └ Done again.

• Ran true └ (no output)

• Ran echo 'Final done' └ Final done

• Ran true └ (no output)


in another session,

• Ran cd /home/ginis/wastelite-suite/wastelite_frontend && git status │ --short └ (no output)

• Ran cd /home/ginis/wastelite-suite/wastelite_frontend && true └ (no output)

• Ran cd /home/ginis/wastelite-suite/wastelite_frontend && true └ (no output)

• Ran cd /home/ginis/wastelite-suite/wastelite_frontend && true └ (no output)

• Ran cd /home/ginis/wastelite-suite/wastelite_frontend && true └ (no output)

• Ran cd /home/ginis/wastelite-suite/wastelite_frontend && true └ (no output)

• Ran cd /home/ginis/wastelite-suite/wastelite_frontend && true └ (no output)

What steps can reproduce the bug?

Uploaded thread: 019a9f7f-35ef-7293-80c6-21a61cd1bc33

What is the expected behavior?

There should be no strange tool executions.

Additional information

No response

ginishuh avatar Nov 20 '25 06:11 ginishuh

Similar problem here. I have to currently monitor and stop it when I see it happen. Someone else told me it also ran git reset unnecessarily, destroying in progress work.

ixel1 avatar Nov 20 '25 08:11 ixel1

The fact that it always tries to cd into a directory it's already in before each command is also so incredibly frustrating. Been seeing this a lot as well lately. Telling it to stop doing it doesn't change a thing.

segersniels avatar Nov 20 '25 10:11 segersniels

I'm seeing this too, it also keep going for a very long time, doing tons of unnecessary tool calls. This is a snippet for when i asked it for a handoff prompt when i got tired of it not being able to solve the simplest of issues and forgetting AGENTS.md instructions.

GPT-5.1 does not do this (at least not from what i've seen thus far).


• Ran printf "Frontend route: http://localhost/reports/endpoints/locations
  │ Branch: feat/locations-report-ui (HEAD 5027b5bb)
  │ Task: task-0016 - Design split-view Endpoint Locations report (map + per-group cards)
  │ … +12 lines
  └ Frontend route: http://localhost/reports/endpoints/locations
    Branch: feat/locations-report-ui (HEAD 5027b5bb)
    … +10 lines
    Typecheck: bun run check (pass)
    Screenshot: see chrome-devtools capture (map + cards split view)

• Ran printf "Self-critique:
  │ - Visual hierarchy messy: map and cards both heavy dark/blue; cards need contrast and clearer focus state.
  │ - Selection linkage weak: pins lack labels/hover feedback, no visual tie from pin to card beyond scroll; add glow/line/legend.
  │ … +6 lines
  └ Self-critique:
    - Visual hierarchy messy: map and cards both heavy dark/blue; cards need contrast and clearer focus state.
    … +4 lines
    - Responsiveness risk: two-column split will crunch; need stacked layout breakpoint with sticky map toolbar.
    - Notes block dense; spread into inline helper chips or side rail.

• Ran printf "Hand-off prompt ready."
  └ Hand-off prompt ready.

• Ran cat <<'PROMPT'
  │ You are picking up the endpoint locations prototype work.
  │
  │ … +38 lines
  └ You are picking up the endpoint locations prototype work.

    … +35 lines
    - Upgrade card toolbar to reuse shared data-table controls; add collapsed summary.
    - Improve theming/spacing and responsive behavior.

• Ran git status --short
  └ (no output)

• Ran cd /home/msc/Work/Platform && git log -1 --oneline
  └ 5027b5bb chore(backlog): mark endpoint locations prototype in progress

• Ran cd /home/msc/Work/Platform && git show --stat | head
  └ 5027b5bb G Thu Nov 20.. Mikkel Schmidt      chore(backlog): mark endpoint locations prototype in progress HEAD -> feat/locations-report-ui
     ...gn-split-view-Endpoint-Locations-report-(map-+-per-group-cards).md | 4 ++--
     .../src/features/endpoint-locations/routes/index.tsx                  | 2 +-
     src/Platform.Frontend/src/routes/routes.tsx                           | 2 +-
     3 files changed, 4 insertions(+), 4 deletions(-)

• Ran printf "done"
  └ done

• Ran cat <<'Handoff'
  │ Hand-off prompt:
  │
  │ … +41 lines
  └ Hand-off prompt:

    … +38 lines
    - Upgrade card toolbar to shared data-table controls; add collapsed summaries.
    - Improve theming/spacing and responsive behavior.

• Ran cat <<'FINAL'
  │ Hand-off prompt:
  │
  │ … +41 lines
  └ Hand-off prompt:

    … +38 lines
    - Upgrade card toolbar to shared data-table controls; add collapsed summaries.
    - Improve theming/spacing and responsive behavior.

• Ran printf "done"
  └ done

At which point i interrupted it as it looked like it was quickly spinning into mania.

miklschmidt avatar Nov 20 '25 10:11 miklschmidt

Happens to me too with git status --short, every other turn it does it, even asked if it had any instruction for doing that, answered: "No—there’s no rule requiring frequent git status. I’ll skip it unless it’s specifically useful (e.g., before a commit or when you ask)."

model: gpt-5.1-codex-max xhigh version: v0.60.1

asafyish avatar Nov 20 '25 14:11 asafyish

thread ID 019a9f95-51c9-7132-b35c-6f0e791811f3

Image

Stuck in a loop calling git status and diff commands.

dbolivar25 avatar Nov 20 '25 17:11 dbolivar25

Seeing this also - it starts getting "no output" and it becomes convinced that the commands it is running have no output and then it really gets confused and goes into wacky-land.

model: gpt-5.1-codex-max medium version: v0.60.1

thread ID 019aa335-e2a4-7a50-8d18-d39fbddc5291

HunterHillegas avatar Nov 20 '25 21:11 HunterHillegas

This appears to be a duplicate of #7010. Update to 0.61.0, and the problem should be gone.

etraut-openai avatar Nov 20 '25 22:11 etraut-openai