Skip to content

Tell agents the rerun waits for Codex - #6

Merged
kkkiio merged 2 commits into
mainfrom
agent-rerun-waits-for-codex
Oct 11, 2026
Merged

kkkiio merged 2 commits into
mainfrom
agent-rerun-waits-for-codex

Conversation

@kkkiio

@kkkiio kkkiio commented Oct 11, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • An observed agent session (deepseek v4.1 flash) read request a fresh review — then re-run as "wait for the review to appear, then re-run". After posting the Codex review request comment it wrote its own until gh api …/reviews …; sleep 15 loop, and only reran the check after being challenged.
  • Every failure annotation and job summary now prints the next steps as one chain in run order: the review request comment, then gh run rerun RUN_ID --failed && gh pr checks PR --watch. The message also says the rerun itself waits up to the configured review-timeout-seconds.
  • The guidance recommends rather than forbids: agents can still read Codex reviews or comments directly when the check result looks wrong.
  • review-timeout no longer says "Re-run after the review finishes"; it now tells the agent to rerun to keep waiting.
  • failureOutput / summaryMarkdown now take a MessageOptions record (run id, review hint, LGTM mode, review timeout).
  • The job summary uses the same single chain (Codex review finding).
  • AGENTS.md: never write a literal Codex mention in a PR description; the connector turns it into a Codex task and skips the automatic review.
  • ADR 0009 records the decision. README example and docs/CONFIGURATION.md reruns section are updated, and dist/ is rebuilt.

Test plan

  • npm run check (typecheck, tests, ncc build)
  • Message fixtures regenerated and wording diff reviewed
  • New test covers the timeout text (10 min / 90s)

Generated with Devin

An observed agent read "request a review — then re-run" as "wait for the
review, then re-run" and hand-wrote a polling loop. Failures now print one
chained command (review request, rerun, gh pr checks --watch) and state that
the rerun itself waits up to review-timeout-seconds.

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@chatgpt-codex-connector

Copy link
Copy Markdown

Summary

  • Fixed failure job summaries so the review request, workflow rerun, and check watcher are emitted as one executable && chain, matching the documented run order. src/messages.tsL275-L283
  • Added regression coverage that verifies the complete command chain and its ordering. test/messages.test.tsL282-L296
  • Regenerated the pinned message fixtures so the expected summary now contains the single chained command. test/fixtures/messages/review-missing.txtL14-L24
  • Rebuilt the committed GitHub Action distribution and committed all changes in commit e0986c0.
  • Created pull request metadata titled “Fix chained next steps in failure summaries.”

Testing

  • ✅ npm run fixtures:update
  • ✅ npm run check
  • ✅ git status --short (working tree clean)

View task →

@kkkiio

kkkiio commented Oct 11, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-11T11:47:29.486215Z f1b64bc Manual request
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@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: f1b64bcb57

ℹ️ 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".

Comment thread src/messages.ts Outdated
Also record in AGENTS.md that a literal Codex mention in a PR description
becomes a Codex task and skips the automatic review.

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@kkkiio
kkkiio merged commit fd9c653 into main Oct 11, 2026
2 checks passed
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