Skip to content

Archive completed stop-gate review threads - #568

Open
bogdan0dzuba wants to merge 1 commit into
openai:mainfrom
bogdan0dzuba:codex/companion-autoarchive
Open

Archive completed stop-gate review threads#568
bogdan0dzuba wants to merge 1 commit into
openai:mainfrom
bogdan0dzuba:codex/companion-autoarchive

Conversation

@bogdan0dzuba

Copy link
Copy Markdown

Summary

  • archive persisted stop-gate review threads after a recognized ALLOW: or BLOCK: result is durably stored
  • classify stop-gate jobs separately so --resume-last continues the latest user rescue task
  • preserve failed, interrupted, empty, and unrecognized review threads for inspection
  • retry archive operations directly when a shared broker endpoint is stale or busy

Root cause

The stop hook launched reviews as persistent app-server task threads and saved their results, but never called thread/archive. Successful internal review tasks therefore accumulated in the Codex task list.

Validation

  • npm run build
  • npm run check-version
  • node --test tests/runtime.test.mjs - 66 passed
  • remaining unit suites - 30 passed
  • installed-plugin smoke test confirmed that the stop-gate thread is archived while the user rescue thread remains resumable

@bogdan0dzuba
bogdan0dzuba marked this pull request as ready for review July 28, 2026 16:17
@bogdan0dzuba
bogdan0dzuba requested a review from a team July 28, 2026 16:17

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: daba6afb93

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

title: "Codex Stop Gate Review",
summary: "Stop-gate review of previous Claude turn"
summary: "Stop-gate review of previous Claude turn",
jobClass: "stop-review"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Avoid classifying user prompts by marker text

When a normal /codex:rescue prompt happens to quote Run a stop-gate review of the previous Claude turn.—for example, while editing or discussing the gate prompt—it is now stored with jobClass: "stop-review". Both findLatestResumableTaskJob and the active-task check only consider jobClass === "task", so --resume-last and task-resume-candidate silently omit that user's rescue thread. Pass an explicit internal stop-review flag from the hook instead of deriving resumability from user-controlled prompt content.

Useful? React with 👍 / 👎.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant