Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/codex-review-gate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:
permissions:
contents: read
issues: write
pull-requests: read
pull-requests: write
statuses: write

concurrency:
Expand Down
2 changes: 1 addition & 1 deletion docs/CODEX_REVIEW_GATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,4 @@ workflow 合入默认分支并至少运行一次后,把 `codex/review-gate`

不要在 workflow 还没进入受保护分支前提前要求 `codex/review-gate`,否则当前引入 PR 会被一个没有 runner 能创建的 required status 卡住。

workflow 使用 `GITHUB_TOKEN`,这样 marker comment 的作者会是 `github-actions[bot]`。为了让信号最干净,建议关闭 Codex automatic review-on-push,只让这个 gate comment 触发当前 head review。
workflow 使用 `GITHUB_TOKEN`,这样 marker comment 的作者会是 `github-actions[bot]`。实测创建 PR conversation comment 需要 workflow token 同时具备 `issues: write` 与 `pull-requests: write`。为了让信号最干净,建议关闭 Codex automatic review-on-push,只让这个 gate comment 触发当前 head review。
1 change: 1 addition & 0 deletions docs/PROJECT_STATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
- workflow 落到默认分支后,还需要把 `codex/review-gate` 加进远端 ruleset 的 required status checks。
- 2026-04-25 用临时非默认 base branch 测试过:PR 只触发普通 `pull_request` CI,没有触发 `Codex Review Gate`;真实 GitHub Actions bot 路径要等 workflow 进入 repository default branch 后再测。
- 2026-04-25 在默认分支首次实测时,`Codex Review Gate` 成功触发并写入 `codex/review-gate` status,但 marker comment 创建失败:workflow 选择了 `CODEX_REVIEW_GATE_TOKEN` secret,导致 `POST /issues/8/comments` 返回 `403 Resource not accessible by integration`。当前修正方向是强制使用 `github.token`,保证 marker 身份是 `github-actions[bot]`。
- 强制使用 `github.token` 后,`GITHUB_TOKEN` 日志显示 `Issues: write` / `PullRequests: read` 仍无法创建 PR conversation comment;下一步把 `pull-requests` 权限提升到 `write` 后复测。

## 当前架构方向

Expand Down
Loading