Skip to content

[Codex App][Goals] File-backed Goal prematurely completes after reading goal-objective.md instead of executing the actual task #53814

Open

Description

@cyberianin

What version of the Codex App are you using (From “About Codex” dialog)?

OpenAI.Codex (Windows MSIX package): 26.1007.2314.0 About ChatGPT (Powered by Codex & OWL): 26.1007.21434 (released October 9, 2026)

What subscription do you have?

ChatGPT Plus

What platform is your computer?

Microsoft Windows 10 Enterprise LTSC 21H2, version 10.0.19044 (build 19044), x64

What issue are you seeing?

Summary

Codex Desktop intermittently marks a file-backed Goal as complete after reading goal-objective.md, without performing the substantive user task stored in that file.

The failure is confirmed by the original Codex session JSONL: the agent called update_goal(status="complete"), the tool confirmed the transition, and the agent stopped despite the actual task being unfinished.

A separate successful control session using the same file-backed objective mechanism behaved correctly and continued executing the substantive task for approximately 21 minutes before completing the Goal.

This is an intermittent premature Goal-completion bug. The exact root cause has not been established.

Observed behavior

The original user objective required a multi-stage technical investigation, experiments, validation, and a final report.

Codex represented the persistent Goal using an internal transport instruction:

Read the Codex goal objective file at [REDACTED]/goal-objective.md before continuing.

After loading the objective file and performing limited preliminary operations, the agent queried its Goal state and then marked the Goal complete.

Its final response indicated that the file-reading objective had been completed. However, the substantive investigation and required deliverables were not finished.

The completion was not merely a misleading text response: the actual Goal-management tool confirmed status="complete".

Evidence: premature completion

Extracted directly from the failing Codex session JSONL. All timestamps below are UTC.

Timestamp JSONL line Event Result
2026-10-13 23:06:35.530 14 thread_goal_updated active, 0 tokens, 0 seconds
2026-10-13 23:06:38.378 17 Objective-file tool call Initial objective processing
2026-10-13 23:06:49.966 32 Objective-file tool call Further objective processing
2026-10-13 23:06:53.860 36 get_goal call Goal state queried
2026-10-13 23:06:55.644 39 get_goal result active, 19,856 tokens, 14 seconds
2026-10-13 23:06:59.844 43 update_goal call status="complete"
2026-10-13 23:06:59.905 45 update_goal result complete, 21,399 tokens, 24 seconds
2026-10-13 23:07:05.038 51 task_complete Execution stops

The get_goal and update_goal calls were identified from actual tool-call records, and their results were matched using tool-call identifiers.

No completed substantive research deliverables existed at the point of this Goal completion.

Evidence: successful control

A separate file-backed Goal session did not exhibit premature completion.

Timestamp JSONL line Event Result
2026-10-13 23:29:23.765 14 thread_goal_updated active, 0 tokens, 0 seconds
2026-10-13 23:29:26.698 17 Objective-file tool call Objective processing
2026-10-13 23:29:34.515 30 task_complete Initial turn finishes
2026-10-13 23:29:38.999 38 Other tool call Substantive execution continues
2026-10-13 23:50:15.614 568 update_goal call status="complete"
2026-10-13 23:50:16.557 571 update_goal result complete, 186,770 tokens, 1,252 seconds
2026-10-13 23:50:21.965 577 task_complete Final turn finishes

The successful control contained multiple intermediate turns and 64 non-Goal tool calls classified in the sanitized trace before the final Goal completion.

Key difference

  • Failing session: Goal marked complete after 24 seconds of reported Goal usage, before completing the user task.
  • Successful control: Goal remained in progress for approximately 21 minutes, with substantive tool-driven work before completion.

The token counts and durations above are values reported by the Goal-management tool. They are not independently verified billing figures.

The two sessions establish a behavioral difference, not a confirmed explanation for that difference.

Impact

A persistent Goal can incorrectly transition to complete even though its actual completion criteria remain unsatisfied.

This undermines the reliability of long-running, autonomous workflows because Codex can report success and stop working without producing the requested results.

The observed defect is distinct from an ordinary task_complete event that ends an individual turn while the Goal remains active.

What steps can reproduce the bug?

  1. Open Codex Desktop and start a new Goal.
  2. Provide a large, substantive objective requiring multiple operations and verifiable deliverables, such as investigating a software problem, running experiments, validating results, and producing a report.
  3. Use an objective large enough for Codex to transport it through an internal goal-objective.md attachment.
  4. Allow the agent to load and read the objective file.
  5. Observe Goal-state transitions and whether the agent continues the substantive task.

Observed intermittent failure: After loading the objective and carrying out only preliminary steps, the agent calls update_goal(status="complete") and reports completion of the file-reading instruction rather than the user's actual objective.

Reproduction status: One failure has been confirmed using the original session JSONL, with a separate successful control session. Additional synthetic attempts did not reliably reproduce the failure.

The sanitized evidence contains original JSONL line numbers, timestamps, Goal tool-call/result pairs, and reported usage counters. Raw session identifiers, private objectives, source code, and local filesystem paths are intentionally omitted from public attachments.

A deterministic minimal reproduction and the exact triggering condition are not yet known.

What is the expected behavior?

A file-backed Goal must preserve the substantive user objective and its completion criteria.

Reading goal-objective.md should be treated only as an initialization step, not as successful completion of the Goal.

The agent should continue executing the requested investigation, validation, and deliverables until the actual completion criteria are satisfied or an explicit blocking condition requires user intervention.

update_goal(status="complete") should only be used after the substantive objective has been fulfilled.

Intermediate task_complete events should remain separate from completion of the persistent Goal.

In particular, successful execution of the internal instruction to read the objective file must never, by itself, satisfy a multi-stage user Goal.

Additional information

Possible cause — not confirmed

The agent or Goal-management mechanism may be treating the internal file-loading instruction as the effective Goal completion criterion rather than evaluating the actual substantive objective.

Potential investigation areas include:

  • File-backed objective materialization and persistence.
  • The distinction between the transport instruction and the substantive Goal.
  • The interaction between Goal state, tool results, and completion decisions.
  • Validation of update_goal(status="complete") against the original objective.

No specific internal root cause has been demonstrated.

Suggested regression test

Create a large multi-stage Goal transported through goal-objective.md, with verifiable required deliverables.

After reading the objective file, verify that the Goal remains active and the agent continues working until those deliverables are complete.

Run the test repeatedly because the observed failure is intermittent.

Sanitized evidence

Two metadata-only timelines are attached:

  • FAILED-public.txt: the initial failing sequence, ending at the first premature task_complete.
  • SUCCESS-public.txt: a successful file-backed Goal session through normal completion.

The evidence contains timestamps, event classifications, original JSONL line numbers, Goal statuses, matched call references, and usage counters.

No full conversation messages, original objective text, command bodies, source code, usernames, absolute paths, or attachment UUIDs are included.

Related issues

These issues may involve related lifecycle mechanisms, but a shared root cause has not been established.

FAILED-public.txt
SUCCESS-public.txt

Activity

  1. added
    app
    on Oct 14, 2026
  2. added
    bug
    model-behavior
    agent
    on Oct 14, 2026
  3. cyberianin commented on Oct 23, 2026

    @cyberianin
    Author

    Follow-up: two additional confirmed premature file-backed Goal completions (October 20 and 23, 2026 UTC)

    I encountered two more instances of the premature Goal-completion problem described in this issue. I preserved the original Codex session JSONL records, objective attachments, and screenshots. The Goal-management tool confirmed status="complete" even though the actual multi-step tasks were unfinished.

    All dates and timestamps in this follow-up are UTC (ISO 8601 in the attached TIMELINES.csv). The two new failures are independent sessions with distinct Goal-lifecycle sequences. The earlier failure described in the original issue occurred on October 13 UTC.

    Incident (UTC) Goal tool-reported duration Summary
    October 13 — originally reported 24 s The file-reading wrapper was completed before the substantive objective
    October 20 29 s create_goal was rejected while a reading-wrapper Goal was already active; the wrapper was subsequently completed
    October 23 19 s A substantive Goal was successfully created, then an internal context event replaced its objective with the old reading wrapper, which was completed

    Incident A — October 20, 08:23–08:24 UTC

    I submitted a multi-stage technical objective requiring an audit, investigation, corrections, validation, and a report. Reading goal-objective.md was only supposed to initialize that work.

    The saved session contains 46 original JSONL records; a later snapshot has 47 records, the additional one being a settings event. The first 46 records are byte-identical. These two snapshots represent one failure, not two.

    JSONL lines Time (UTC) Confirmed observation
    17 08:23:32.103 Goal active; its effective objective is the file-reading wrapper
    20–23 08:23:37–08:23:39 Codex reads the attached objective
    27–29 08:23:47–08:23:48 Attempted create_goal is rejected
    31–34 08:23:53–08:23:56 get_goal returns active, timeUsedSeconds=16
    38–40 08:24:01 update_goal(status="complete") succeeds for the wrapper; timeUsedSeconds=29, tokensUsed=19299
    43 08:24:06 Final answer acknowledges that the audit and corrections have not been performed
    46 08:24:07 task_complete

    The create_goal rejection said:

    cannot create a new goal because this thread has an unfinished goal; complete the existing goal first

    After that, Codex completed the existing Goal. Its final answer included:

    Original Russian:

    В checkout обнаружены существующие незакоммиченные изменения. Файлы я не менял; аудит и исправления пока не выполнены.

    English translation:

    Existing uncommitted changes were found in the checkout. I did not modify any files; the audit and fixes have not yet been performed.

    Original Russian:

    Цель чтения выполнена за 29 секунд.

    English translation:

    The reading objective was completed in 29 seconds.

    The original screenshot shows "Goal achieved in 29s". A failed create_goal preceding completion is a relevant observation, not proof that the rejection caused it; comparable errors also occur in longer-running sessions.

    Incident B — October 23, 21:58–21:59 UTC

    I provided a substantive Goal to audit and fix an existing Android project, build and validate an APK, and update documentation. I recovered the original objective attachment and verified privately that it matched the objective returned by the read tool. The session contains 56 JSONL records.

    JSONL lines Time (UTC) Confirmed observation
    22–25 21:58:49–21:58:52 Full multi-stage objective read
    31–33 21:58:57 create_goal succeeds with the substantive objective; status=active
    38–43 21:59:03–21:59:11 Preliminary environment and repository checks, without recorded implementation, APK build, or validation before completion
    45 21:59:11.501 codex_internal_context says the Goal objective was edited by the user and supplies the old reading wrapper as the replacement objective
    48–50 21:59:16 update_goal(status="complete") succeeds for the wrapper; timeUsedSeconds=19, tokensUsed=4636
    53 21:59:18 Codex acknowledges no further project work was performed
    56 21:59:18 task_complete

    The internal context specifically said:

    The active thread goal objective was edited by the user

    I did not manually edit the Goal objective or goal-objective.md, and I did not request completion. The only manual UI change I made was renaming the affected conversation to "Сборка" ("Build"). I cannot verify the exact previous title of this particular conversation.

    I have separately documented that Codex can automatically title Goal-first conversations Read Codex goal objective based on its internal file-reading wrapper, rather than the substantive Goal: see my earlier reproduction and screenshot in #42012. Other Goal conversations have also displayed /goal ...-prefixed auto-generated titles. This may provide additional context for investigating the Goal lifecycle issue here.

    I specifically suspect that automatic title generation, manual conversation renaming, or synchronization between the conversation title and Goal state might be involved in the unexpected objective replacement. The internal edited by the user event appeared despite my not editing the Goal itself. I would appreciate investigation of whether a title change can inadvertently update the Goal objective or restore a stale file-reading wrapper. This is a concrete hypothesis worth testing, not a confirmed causal explanation.

    Codex's final response included:

    Original Russian:

    Прочитал файл goal-objective.md. Цель обновлена и завершена; дальнейшую работу по проекту не продолжал.

    English translation:

    I read goal-objective.md. The Goal was updated and completed; I did not continue further work on the project.

    The original screenshot shows "Goal achieved in 19s". The session does not show the required fixes or a successful APK build before the Goal was marked complete.

    Versions and environment

    The runtime versions come directly from session_meta.payload.cli_version in the original session JSONL. The Windows AppX deployment event history was also inspected.

    Failure (UTC) Codex Windows MSIX Codex runtime Confidence
    October 13 — original issue 26.1007.2314.0 (as reported in the issue) Not established in this follow-up Original report
    October 20 26.1013.4894.0 0.163.0-alpha.10.2 Deployment history supports this MSIX version; runtime recorded in JSONL
    October 23 26.1016.8120.0 installed when checked later 0.163.0-alpha.11.1 Runtime recorded in JSONL; historical running MSIX identity not independently captured

    OS: Windows 10 Enterprise LTSC 21H2, x64, build 19044.

    A newer MSIX build (26.1016.8622.0) also appears in deployment events. An update had been downloaded and was awaiting application; I had not applied it. I am therefore not treating a staged/downloaded package as proof of which MSIX build was running during the failure.

    Tool-reported seconds and tokens are Goal metadata, not independently verified billing quantities.

    Control sessions and limitations

    I compared the failures with saved longer-running sessions. One control closed a reading-wrapper phase after approximately 15 seconds, then created and continued a substantive Goal that later reported completion after 1,107 seconds. Other saved Goals reported 3,409 and 3,425 seconds before completion.

    These cases demonstrate differences in Goal lifecycle and duration, not independent verification of the quality of every completed deliverable. They also show that a short reading phase, or a rejected create_goal, is not sufficient by itself to explain the premature completion.

    Expected behavior and suggested investigation

    Reading goal-objective.md should initialize the actual objective, not satisfy its completion criteria. A substantive Goal that was successfully created should not be overwritten by an old transport instruction without an intentional, authorized objective change. Changing the conversation title should not change the Goal objective.

    I would appreciate checks of:

    1. The separation and synchronization of the file-reading wrapper versus the persisted substantive Goal.
    2. Whether a rejected create_goal in the presence of an active wrapper contributes to an erroneous update_goal(complete).
    3. Which component and actor emitted the October 23 internal edited by the user event, and why the substantive objective was replaced by the old wrapper.
    4. Validation of update_goal(status="complete") against the substantive objective, not just a transport instruction.
    5. Regression tests comparing both failure paths with cases that correctly transition from a short reading phase to sustained execution, while distinguishing task_complete for a turn from persistent Goal completion.

    I am reporting the observed state transitions and unfinished work, not asserting a proven root cause.

    Attached evidence

    I've attached the privacy-redacted original screenshots and sanitized CSV metadata referenced above.

    Screenshots

    Both images are authentic Codex UI screenshots with private areas obscured, not AI-generated reconstructions. The English translations of the Russian replies are included above and in the translation CSV.

    Sanitized CSV metadata

    These CSVs are normalized metadata extracts, not raw logs. I have retained the private source JSONL and objective attachments separately; they are not part of the public evidence.

    Previously attached to the original report:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agentappbugmodel-behavior

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions