You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 1d010d5
Browse filesBrowse the repository at this point in the historyBrowse files
or release-generation mechanics, not a correctness finding.
356
356
- If bot review conversations exist on your PR, address them and resolve them yourself once fixed.
357
357
- Leave a review conversation unresolved only when reviewer or maintainer judgment is still needed.
358
-
- Interpret CODEOWNERS as ownership routing, not an automatic independent-approval gate. Before calling an owner review missing, resolve the authenticated GitHub writer and check whether that login is an active member/maintainer of every matched owner team (or is the directly listed owner). An owner-authored change plus the lead's completed review satisfies a plain "owner ask/review" requirement. A pending team review request, empty `reviewDecision`, or `mergeStateStatus=UNSTABLE` alone does not prove that a second party is required.
359
-
- Require independent approval only when an explicit source says so: branch/ruleset protection, a SHA-bound dependency/security guard, a named security policy, or the user's instruction. The dependency and security-sensitive guards already classify a PR author who is a repository admin or active secops member as trusted; do not invent an additional self-approval requirement after those exact-head checks pass. If an explicit independent gate really remains and the author cannot self-approve, state the distinction once and ask whether to wait or use an available maintainer/admin override—never create a repetitive polling loop.
358
+
- Separate repository authorization from GitHub merge enforcement. `CODEOWNERS` routes review requests; a pending request or zero submitted reviews does not prove that approval is mandatory. Restricted/security paths require listed-owner authorship, review, or direction. For governance changes to ownership/review policy itself, explicit direction from an organization owner also satisfies repository policy only when live `GET /orgs/{org}/memberships/{username}` evidence shows `state: active` and `role: admin`. Repository `ADMIN`, `viewerCanAdminister`, and bypass permission do not establish organization ownership. Neither route waives a live GitHub-enforced review rule.
359
+
- Before reporting a mandatory approval blocker, inspect live branch protection and every matching ruleset, the PR review decision/requests, and the authenticated actor's permission and bypass state. If using the organization-owner governance route, record the live organization-membership result separately. Name the exact enforced rule and whether it is satisfied. Bypass state is evidence about the likely server outcome, never authorization. If no review rule is enforced, do not stop before native prepare/merge solely because a requested team has not reviewed.
360
+
- Explicit user direction resolves this repository-policy question only from the applicable listed owner or through the verified organization-owner governance route; it cannot override server enforcement. If GitHub requires an independent approval and it remains unsatisfied, stop with the exact blocker even when the actor has bypass permission. Otherwise continue through the native landing flow and let its verified merge command exercise the live rule.
360
361
- Before landing any PR with non-trivial code changes, run fresh `$autoreview` until no accepted/actionable findings remain; prior CI, ClawSweeper, or manual review is not a substitute. Skip only for truly trivial/docs-only changes or when the user explicitly opts out.
361
362
- When an agent is landing or merging a PR targeting `main`, use only the repo-native `scripts/pr` wrapper: run `scripts/pr review-init <PR>`, follow its emitted checkout/guard guidance, initialize and complete review artifacts with `scripts/pr review-artifacts-init <PR>`, validate them with `scripts/pr review-validate-artifacts <PR>`, then run `OPENCLAW_TESTBOX=1 scripts/pr prepare-run <PR>` and `scripts/pr merge-run <PR>`. The Testbox flag is mandatory for agents: it verifies hosted CI/Testbox on the current head or reuses a patch-identical pre-rebase run green within 24 hours instead of running full `pnpm` gates locally. `prepare-run` fails fast; invoke only after exact-head CI is complete and green, and do not idle on `auto-response` or `check-docs`. For owner-approved reviewed fork code without hosted Testbox, use `OPENCLAW_PR_GATES_REMOTE=testbox` instead. Do not rebase only because `main` advanced; behind-main drift is advisory unless strict drift is explicitly enabled, while GitHub still blocks conflicts.
362
363
-`scripts/pr` gotchas: subcommands require a PR number (no subcommand `--help` placeholder). Artifacts preserve template enum values with evidence detail in summaries; validate before prepare, from PR-head mode (moving main invalidates the main-baseline guard). Review flow: checkout main baseline, then PR, before artifact validation. After every PR push, rerun `scripts/pr review-init`; checkout alone leaves a stale guard SHA. Locally unset `GITHUB_TOKEN`, `GH_TOKEN`, `HOMEBREW_GITHUB_API_TOKEN`; ambient tokens can select an exhausted or wrong identity. Review JSON: land-ready recommendation `READY FOR /prepare-pr`, `issueValidation.status=valid`; never `APPROVE`. After `scripts/pr merge-run` removes its worktree, `cd` to a persistent repo before follow-up commands.
0 commit comments