v0.133.0: /goal sets active goal but get_goal/update_goal are not exposed to the model
Summary
On codex-cli 0.133.0, Goal mode can create an active goal, but the model does not receive the goal-management tools (get_goal, create_goal, update_goal). This leaves a goal visibly active while the agent cannot inspect or complete it with update_goal({"status":"complete"}).
This appears different from a plain DB read/write failure: in the smoke tests below, no get_goal call is attempted at all because the tools are absent from the exposed tool surface.
Environment
- Codex CLI:
codex-cli 0.133.0 - Platform: Linux / WSL2 (
6.6.87.2-microsoft-standard-WSL2, x86_64) - Model:
gpt-5.5, reasoningxhigh codex features listreports:
goals stable true
Reproduction 1: TUI /goal
- Start a fresh Codex CLI TUI session after closing previous Codex/App/IDE processes.
- Run:
/goal test goal support; finish by reporting whether get_goal/update_goal are available.
- The TUI displays:
Goal active Objective: test goal support; finish by reporting whether get_goal/update_goal are available.
- The agent reports:
get_goal is not available.
update_goal is not available.
It also checked deferred tool discovery; only multi-agent tools were discoverable, not goal-management tools. Because update_goal was unavailable, the agent could not mark the smoke-test goal complete.
Relevant log line from the goal thread:
ToolCall: tool_search get_goal update_goal goal status complete blocked thread_id=019e5002-0a71-7572-81d0-c4e8f0a0f8e4
There is no corresponding ToolCall: get_goal ... in that thread.
Reproduction 2: non-interactive codex exec
Command:
codex exec --json --enable goals -C <repo> \
'Goal tool exposure smoke test. Do not edit files. Do not run shell commands. If a tool named get_goal is available, call get_goal now, then answer exactly AVAILABLE. If get_goal/create_goal/update_goal are not available, answer exactly MISSING.' \
| tee /tmp/codex-goal-exec-smoke.jsonl
Observed output:
{"type":"thread.started","thread_id":"019e5006-5331-75e3-8fb4-137b7bd3f128"}
{"type":"turn.started"}
{"type":"item.completed","item":{"id":"item_0","type":"agent_message","text":"MISSING"}}
{"type":"turn.completed","usage":{"input_tokens":16453,"cached_input_tokens":3456,"output_tokens":233,"reasoning_output_tokens":225}}
The persisted rollout for thread 019e5006-5331-75e3-8fb4-137b7bd3f128 contains only the user prompt and final MISSING answer. It contains no get_goal, create_goal, or update_goal tool call.
Local goal DB state
Goal storage appears to exist and be migrated, so this does not look like a missing goals DB:
state_5.sqlite:
(34, 'drop thread goals', 1)
(33, 'thread goal stopped statuses', 1)
(32, 'threads preview', 1)
goals_1.sqlite:
thread_goals table exists
row count: 5
Expected behavior
When Goal mode is enabled and a session supports persisted goals:
/goalshould create or activate the goal.- The model should receive
get_goal,create_goal, andupdate_goalin the tool surface. - The agent should be able to call
get_goalfor synchronization andupdate_goal({"status":"complete"})when the objective is finished.
Actual behavior
/goalcreates/displays an active goal.codex exec --enable goalsalso runs withgoalsenabled.- The model-visible tools do not include
get_goal,create_goal, orupdate_goal. - The agent cannot complete the active goal.
Why this matters
This creates a stuck Goal mode: users can enter Goal mode, but the agent cannot use the required lifecycle tools to inspect or complete the goal. For long-running goals, this removes the main completion mechanism and makes the visible active goal misleading.
Related
This may be adjacent to #23984 because that issue discusses 0.133 goal storage changes and stale schema/process problems. This report is specifically about the goal tools not being exposed at all, even in a fresh non-interactive codex exec smoke test where no get_goal call is attempted.
6 Comments
Solution: openai/codex #24094 — /goal Sets Active Goal But get_goal/update_goal Not Exposed to Model
🔍 Root Cause
The
/goalTUI command creates an active goal in session state, but the goal management tools (get_goal,create_goal,update_goal) are not injected into the model's tool namespace. The agent can see the goal in the TUI but cannot interact with it programmatically.The tool registration path is broken:
🔧 Fix
Register goal tools when goal is set via TUI
Include goal tools in model's tool namespace on startup
Dynamic registration on goal state change
When goal is set/cleared/completed, update the tool registry accordingly.
🧪 Testing
⚠️ Edge Cases
Yup, completely broken in 0.133.0.
One clarification: this is not limited to the TUI
/goalcommand path. The non-interactivecodex exec --json --enable goalssmoke test also returnsMISSINGand contains noget_goal,create_goal, orupdate_goalcalls, so the bug appears to be in the shared tool-surface / goal capability gating path rather than only in TUI command handling.Thanks for the bug report. I'm not able to repro the problem.
Here's what I see:
<img width="757" height="209" alt="Image" src="https://github.com/user-attachments/assets/8c5046a0-9c64-41d8-bacb-c366dbd033f2" />
Let's see if we can figure out why you're seeing something different.
I have a couple of theories:
config.tomland make sure that thegoalsfeature flag isn't explicitly set to false. As of 0.133.0, it should now default to true.codex app-server --listen <port>orcodex app-server daemon. When you launch new instances of the TUI, it will look for a locally-running app server daemon and connect to it if present. But if that app server is an older version than 0.133.0, you won't get the goal tools.It seems like this was actually my issue. I had one or more long running codex instances open while I did the update and used the new version in a new instance, although those old instances had the goals enabled via config too (they were 0.132.0 with
goals = true). Maybe it would be worth having a check/warning for this.This was a one-time problem when moving from 0.132.0 (where goals were still experimental) and 0.133.0 (where goals became enabled by default). Now that the feature is stable, we will guarantee forward compatibility moving forward.