PR Operations

The openclaw/maintainers repo owns the queue and tracking layer for OpenClaw PR work. It decides what to review next, prepares handoff context, and records final decisions. It does not merge or close PRs on GitHub directly.

Daily Queue Flow

scripts/pr-plan
scripts/pr-next
scripts/pr-handoff --tool codex
  • scripts/pr-plan builds or refreshes the queue.
  • scripts/pr-next picks the next candidate and live-checks that the representative PR is still open.
  • scripts/pr-handoff emits copy/paste context for a steerable agent session.
  • The reviewer works in openclaw/openclaw using the normal review, prepare, and merge skills.
  • scripts/pr-decide records the final outcome back in maintainer state.

Decisions

scripts/pr-decide --decision merge --pr <pr>
scripts/pr-decide --decision merge --pr <pr> --auto-close-duplicates
scripts/pr-decide --decision close_duplicate --pr <origin_pr>
scripts/pr-decide --decision close_not_planned --pr <pr>
scripts/pr-decide --decision defer --pr <pr>
  • Record the decision after the GitHub action is complete.
  • Use --auto-close-duplicates only when the cluster semantics are correct.
  • Use defer when the item should remain visible but is not ready for action.

Cluster Behavior

  • Cluster origins represent related duplicate or overlapping PRs.
  • Handoff includes origin, cluster members, pending members, lane, policy flags, queue rationale, and dependencies.
  • merge applies only to the selected PR unless --auto-close-duplicates is used.
  • close_duplicate applies to duplicate members in the cluster, excluding the origin.
  • Manual overlap gates block sequencing without pretending two PRs are duplicates.

Parallel Maintainers

export PR_OPS_OWNER=codex-a
scripts/pr-next
scripts/pr-handoff --tool codex
  • Claims prevent two maintainers from unknowingly working the same queue item.
  • Claims are lease-based and expire.
  • Use owner names that are clear enough to debug later.
  • If a claim looks stale, inspect before overriding it.

Maintainer Boundary

  • Queue scripts choose and track work.
  • Review skills inspect, fix, gate, push, merge, or close in the target repo.
  • Contributor attribution belongs to the landing path, not the queue tracker.
  • Do not direct-land contributor work when the PR is viable and maintainers can edit the branch.