Skip to content

Paused Goal still receives automatic continuation turns until marked blocked #37869

Open

Description

@harryshawk

What version of Codex are you using?

Codex Desktop/current connected runtime; the exact app build was not discoverable from this session.

Platform

macOS 26.5.2 (25F84), Apple Silicon arm64.

What issue are you seeing?

A Goal whose persisted status was confirmed as paused continued to receive automatic internal Goal-continuation turns.

This is not the case where a user merely says "pause" in chat while the persisted Goal remains active. The Goal service returned status: "paused" before the unwanted continuations began.

Observed sequence:

  1. The user paused the active Goal to discuss progress.
  2. get_goal() returned the same thread Goal with status: "paused".
  3. The runtime nevertheless injected:
    <codex_internal_context source="goal">Continue working toward the active thread goal...</codex_internal_context>
  4. The agent declined to work and stated that it was honoring the explicit pause.
  5. The runtime injected the same Goal continuation again.
  6. After three consecutive unwanted continuations, the agent had to call update_goal(status: "blocked") merely to stop the loop.

No user request resumed the Goal between the paused-state observation and these continuation turns.

Expected behavior

  • A persisted paused Goal must not schedule or inject any automatic continuation turn.
  • It should resume only through an explicit supported user resume action.
  • A user should not have to mark a healthy paused Goal blocked to suppress automatic continuation.
  • The scheduler should re-check persisted Goal status immediately before enqueueing and immediately before injecting a continuation.
  • If an already-enqueued continuation races with a pause, it should be cancelled or discarded when it observes paused.

Impact

  • Consumes tokens while the user is intentionally discussing or waiting.
  • Can cause unintended work after the user paused execution.
  • Corrupts lifecycle semantics because blocked must be used as a workaround for paused.
  • Makes long-running Goal work difficult to review safely.

Suggested acceptance criteria

  1. Start an active Goal.
  2. Pause it and verify its persisted status is paused.
  3. Leave the thread idle across multiple continuation scheduling intervals.
  4. Confirm no internal Goal-continuation turn is injected.
  5. Resume explicitly and confirm continuation restarts normally.
  6. Add a race test where pause occurs after continuation scheduling but before injection; the queued continuation must be dropped.
  7. Keep paused and blocked semantically distinct.

Related issues

Activity

  1. added
    bug
    app
    on Aug 10, 2026
  2. nicholasr-itsulu commented on Sep 3, 2026

    @nicholasr-itsulu

    Reproduced on Linux/VSCodium with semantic no-op repetitions

    I reproduced this Goal lifecycle failure using Codex in VSCodium on Garuda Linux (x86_64). The exact Codex extension/runtime build was not captured during the incident.

    An active infrastructure Goal reached two component-level conditions that could not currently be remediated: one service required unavailable write authority, and one offline node required physical console/power recovery. The prompt explicitly required the agent to park blocked components, avoid polling, and never repeat an unchanged blocked/paused status.

    Observed sequence:

    1. The agent completed useful independent validation.
    2. It emitted: Paused pending a new resume trigger.
    3. No new user input or material external-state change occurred.
    4. Automatic Goal continuations nevertheless ran repeatedly for about five minutes.
    5. The visible replies included more than 60 semantically equivalent no-op messages, including:
      • The goal remains blocked and no new resume trigger is present.
      • No new resume trigger is present. The goal remains paused.
      • No execution was performed on this unchanged continuation.
      • Waiting for a new user instruction or genuine resume trigger.
      • No action.
    6. Some exact messages repeated many times; later turns shortened to Acknowledged or No action.
    7. The agent eventually reported that the Goal had been marked BLOCKED to suppress further automatic audits.

    This confirms that prompt-level instructions and model-level no-op handling cannot reliably stop the product-side continuation loop. It also shows that literal-output deduplication alone would be insufficient because the agent varied the wording while preserving the same no-progress intent.

    This appears to be the Linux/VSCodium counterpart of the persisted-paused behavior in this issue and overlaps with #34248's unbounded no-progress auto-continuation loop.

    Requested safeguards:

    • Re-check persisted Goal status immediately before enqueue and immediately before continuation injection.
    • Invalidate queued continuation leases when a Goal becomes paused or blocked.
    • Do not automatically enqueue another turn after a completion with no tool calls, no state change, and no new user/material trigger.
    • Detect semantically equivalent no-progress outputs, not only byte-identical replies.
    • Apply a hard circuit breaker and exponential backoff after consecutive no-progress continuations.
    • Keep component-level blockers from causing an active scheduler loop while awaiting an external event.

    Private infrastructure names, addresses, credentials, and repository details are intentionally omitted.

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

    appautomationsbug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions