Wait-loop usage in herd explodes token usage
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 45/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- rust
- Ambito
- ai-infra-agents, cli
Direzione di ricerca
Start with the uploaded thread 01a21991-ac2c-7272-831d-91e279a5d945 and trace how Codex handles repeated hc wait timeouts while coordinating with a worker. Check whether retries or continued waiting trigger model calls or consume tokens. Done means waiting for a worker uses no model tokens, and the behavior is covered by a reproducible test.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
What version of Codex CLI is running?
codex-cli 0.172.0
What subscription do you have?
Plus
Which model were you using?
Astra (medium) 6.2
What platform is your computer?
Darwin 27.2.0 arm64 arm
What terminal emulator and version are you using (if applicable)?
Terminal.app running herd.app
Codex doctor report
Codex Doctor v0.172.0 · macos-aarch64
Environment
✓ system en-SE
os Mac OS 27.2.1 [64-bit]
OS language en-SE
LC_CTYPE en_US.UTF-8
LANG en_US.UTF-8
VISUAL mvim -f
EDITOR mvim -f
PAGER less
LESS -R
✓ disk sufficient free disk space (1454.5 GiB)
warning threshold 5.0 GiB
failure threshold 1.0 GiB
CODEX_HOME available 1454.5 GiB
worktree available 1454.5 GiB
✓ security no supported endpoint protection detected
endpoint products none detected
✓ runtime standalone (unix, package /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin, bin /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/bin, resources /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/codex-resources, path /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/codex-path)
version 0.172.0
install method standalone (unix, package /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin, bin /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/bin, resources /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/codex-resources, path /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/codex-path)
commit unknown
executable ~/.local/bin/codex
✓ install consistent
context standalone (unix, package /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin, bin /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/bin, resources /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/codex-resources, path /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/codex-path)
managed by npm: no · bun: no · pnpm: no · Vite+: no · package root —
PATH entries (1) ~/.local/bin/codex
✓ search file exists (bundled, /Users/gsr/.codex/packages/standalone/releases/0.172.0-aarch64-apple-darwin/codex-path/rg)
search command ~/.codex/packages/standa…le-darwin/codex-path/rg
search provider bundled
search command readiness file exists
✓ git git executable found; execution not verified
selected git /opt/homebrew/bin/git
repo detected true
repo root ~/src/research/track_layout_analyzer
.git entry directory
PATH entries (2) /opt/homebrew/bin/git
/usr/bin/git
git execution not inspected (PATH helpers are not executed)
✓ terminal Apple Terminal 488.9
terminal Apple Terminal
TERM_PROGRAM Apple_Terminal
terminal version 488.9
stdin is terminal true
stdout is terminal true
stderr is terminal true
terminal size 189x51
color output enabled
COLORTERM truecolor
effective locale en_US.UTF-8
✓ title default · project track_layout_analyzer
title source default
title items activity, project-name
activity item true
project source git repo root
project value track_layout_analyzer
✓ state databases healthy
CODEX_HOME ~/.codex (dir)
log dir ~/.codex/log (missing)
sqlite home ~/.codex (dir)
state DB ~/.codex/state_5.sqlite (file) · integrity ok
log DB ~/.codex/logs_2.sqlite (file) · integrity ok
goals DB ~/.codex/goals_1.sqlite (file) · integrity ok
memories DB ~/.codex/memories_1.sqlite (file) · integrity ok
active rollouts 140 files · 115.22 MB (avg 842.74 KB)
archived rollouts 0 files · 0 B (avg 0 B)
memories v2 DB ~/.codex/memories_v2_1.sqlite (missing)
memories v2 DB integrity skipped (missing)
queue DB ~/.codex/queue_1.sqlite (file)
queue DB integrity ok
thread history DB ~/.codex/thread_history_1.sqlite (file)
thread history DB integrity ok
standalone release cache 2 entries in /Users/gsr/.codex/packages/standalone/releases
✓ threads rollout files and state DB thread inventory agree
default model provider openai
rollout DB active files 140
rollout DB archived files 0
rollout DB scan errors 0
rollout DB malformed file names 0
rollout DB scan cap reached false
rollout DB rows 140
rollout DB active rows 140
rollout DB archived rows 0
rollout DB missing active rows 0
rollout DB missing archived rows 0
rollout DB stale rows 0
rollout DB archive mismatches 0
rollout DB duplicate rollout thread ids 0
rollout DB duplicate DB paths 0
rollout DB model providers openai=140
rollout DB sources vscode=132, cli=8
Configuration
✓ config loaded
model gpt-6.2-astra · openai
cwd ~/src/research/track_layout_analyzer
config.toml ~/.codex/config.toml
config.toml parse ok
MCP servers 0
feature flags 73 enabled · 1 overridden (full list with --all)
overrides daemon_auto_start
configuration scope invocation config, including cloud-managed policy
active thread overrides not inspected
configured TUI mode fullscreen
configuration load ms 3
✓ auth auth is configured
auth storage mode File
auth.json path (file backend/fallback) ~/.codex/auth.json
stored auth mode chatgpt
stored API key false
stored ChatGPT tokens true
stored agent identity false
✓ mcp no MCP servers configured
✓ sandbox restricted fs + restricted network · approval OnRequest
approval policy OnRequest
filesystem sandbox restricted
denied-read rules 0
denied-read glob rules 0
glob scan max depth unbounded
managed filesystem source none
network sandbox restricted
linux helper none
✓ sandbox no explicit filesystem paths to probe
Updates
✓ updates update configuration is locally consistent
startup update check true
update action standalone installer
version cache ~/.codex/version.json
cached latest version 0.172.0
last checked at 2026-11-26 07:34 UTC
latest version 0.172.0
latest version status current version is not older
Connectivity
✓ network no proxy env vars
proxy env vars none
system proxy direct
respect system proxy disabled
managed proxy not configured
✓ websocket connected (HTTP 101 Switching Protocols) · 15s timeout
model provider openai
provider name OpenAI
wire API responses
supports websockets true
proxy env vars none
connect timeout 15000 ms
auth mode chatgpt
endpoint wss://chatgpt.com/backend-api/<redacted>
DNS 2 IPv4, 0 IPv6, first IPv4
handshake result HTTP 101 Switching Protocols
reasoning header false
server model present false
✓ reachability active provider endpoints are reachable over HTTP
reachability mode ChatGPT auth
ChatGPT inference URL https://chatgpt.com/backend-api/<redacted> reachable (HTTP 405)
Background Server
○ app-server not running (ephemeral mode)
daemon state dir ~/.codex/app-server-daemon
settings ~/.codex/app-server-daemon/settings.json (missing)
pid file ~/.codex/app-server-daemon/app-server.pid (missing)
update-loop pid file ~/.codex/app-server-daem…/app-server-updater.pid (missing)
dedicated pid file ~/.codex/app-server-daemon/daemon.pid (file)
dedicated update-loop pid file ~/.codex/app-server-daemon/daemon-updater.pid (file)
control socket ~/.codex/app-server-cont…app-server-control.sock
status not running
mode ephemeral
─────────────────────────────────────────────────────────────
20 ok · 1 idle · 0 warn · 0 fail ok
What issue are you seeing?
When codex, acting as coordinator, asked to wait in a loop for the Claude working a new pane, I specifically asked it if this would use tokens and it said now. Within a few minutes more than 50% of my 5-0hour limit was gone.
What steps can reproduce the bug?
Uploaded thread: 01a21991-ac2c-7272-831d-91e279a5d945
What is the expected behavior?
No tokens be used while waiting for a worker.
Additional information
/ps
Background terminals
• hc wait t22 --timeout 55
• Ran hc wait t22 --timeout 55
└ {"children":[],"ended":false,"exit_code":null,"reason":"timeout","signal":…
if Claude is going to do a hc send do you need to wait with timeout? does that cost tokens to wait?
Claude can send the report without a wait. I use hc wait to stay available for it. Elapsed waiting time consumes no model tokens. A timeout costs a few tokens only if it returns to the conversation and I issue another call. I’ve put the retries in a loop so routine timeouts stay out of the conversation.
• Ran hc wait t22 --timeout 55
└ {"children":[],"ended":false,"exit_code":null,"reason":"timeout","signal":…
• Ran hc wait t22 --timeout 55
└ {"children":[],"ended":false,"exit_code":null,"reason":"timeout","signal":…
• Ran hc wait t22 --timeout 55
└ {"children":[],"ended":false,"exit_code":null,"reason":"timeout","signal":…
hc wait t22 --timeout 55
{"children":[],"ended":false,"exit_code":null,"reason":"timeout","signal":null,"status":"working","terminal":"t22","turn":17}
- Lingua principale
- Rust
- Stelle
- 136k
- Fork
- 21.6k
- Merge medio
- 1m
- PR unite (30g)
- 997
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di openai/codex
-
app bug rate-limits
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
Windows PowerShell 5.1: non-ASCII text piped into a native command arrives as `?`Forse già presa @akhil9tiet l’ha presa oggi. Apertabug CLI tool-calls windows-os
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
openai/codex#64139 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
bug CLI connectivity
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno
-
core-plugins: remote bundle install keeps the temp directory before a fallible rename and leaves it behind on failureForse già presa @akhil9tiet l’ha presa 1 giorno fa. Apertabug CLI skills
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
openai/codex#63907 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
bug CLI
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
openai/codex#63906 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di openai/codex
Issue simili
-
My Caps shows "Shared" on private Caps that were never sharedForse già presa @AksharP5 l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
CapSoftware/Cap#4569 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
Document Web UIAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
parquet: reject truncated BYTE_STREAM_SPLIT numeric pages instead of silently fabricating valuesApertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno