Command Palette

Search for a command to run...

Назад к скиллам
скилл № 49983

pr-verify

Verification phase of the PR review pipeline. Reads .claude/pr-{number}-execute.json, re-checks mergeability as a hard gate, spot-checks each claimed fix…

БесплатноБез исполняемых скриптов
CERTCCот CERTCC★ 22 звезды на GitHub

Установить pr-verify в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Об этом скилле

Skill: PR Verify

Purpose

Verify closes the loop. It checks what execute claimed to do against what actually exists at HEAD, posts a verdict, and cleans up the session artifacts. It does not fix anything — if gaps are found, they are flagged for the user to re-run /pr-execute or fix manually.

Verify is also the last and authoritative mergeability check. Because it runs after every mutation in the pipeline, its merge-state reading is the only one that can be trusted at verdict time. READY-TO-MERGE is impossible without a live MERGEABLE result — a PR that cannot merge is never ready to merge, regardless of how many findings were confirmed.

Quick Start

# Verify the current branch's open PR
/pr-verify

# Verify a specific PR
/pr-verify 1234

Prerequisites

.claude/pr-{number}-execute.json must exist. If absent, stop immediately:

❌ No execute artifact found for PR #N.
Run /pr-execute first (or /pr-ship to run the full pipeline).

Also requires .claude/pr-{number}-triage.json for finding descriptions. If the triage artifact is missing but the execute artifact exists, proceed using only the execute artifact data — but note the missing triage artifact in the comment.

Workflow

Phase 1 — Load Artifacts

  1. Detect PR number (current branch or explicit argument).

  2. Check .claude/pr-{number}-execute.json against its schema, pr-execute/REFERENCE.md § "Execute Artifact Schema". This skill reads the artifact by that section and does not restate it:

    PYTHONPATH= uv run execute-artifact check .claude/pr-<number>-execute.json
    

    On exit 1, flag MALFORMED-EXECUTE and quote the fields the check names. The artifact cannot be read, so do not read any value from it. Skip every step that reads it: steps 4 and 5 below, Phase 3b steps 2 and 3, Phases 4–5, and Phase 6 steps 1 and 4. Run Phase 2 with --check-markers, the strict choice. Run Phase 3 without --integration, and say in the comment that whether integration tests were owed is unknown: with the flag, a green PR that ran no integration workflow reads as failing. In the comment, the check's error list takes the place of the per-finding table. The overall verdict is GAPS-FOUND. The remedy is a re-run of /pr-execute, which writes a new artifact. Do not re-derive what the artifact should have said: execute owns that record.

    Exit 2 means the file cannot be read: stop as for an absent artifact (§ "Prerequisites").

  3. Read .claude/pr-{number}-triage.json if present.

  4. Integrity check: verify len(execute.results) == len(triage.findings). If counts diverge, flag INCOMPLETE-EXECUTE and continue to Phase 2 (merge state and CI must still be checked). After Phase 3, skip Phases 4–5 and go directly to Phase 6 with an overall verdict of GAPS-FOUND.

  5. Merge-state block check: flag UNSYNCED-EXECUTE if merge_state.conflict_free is not true, or if merge_state.merge_required is true with a null sync_commit_ref (PAD-18-004 called for a merge that never happened). A valid artifact always carries the block (step 2), so the flag is about what execute recorded, never about a missing block. merge_reason: "deferred" with merge_required: false and a null sync_commit_ref is not that: execute found an overlap and, by design, left it to the merger's gh pr update-branch (PAD-18-019, ADR-0221). Do not flag it. Continue to Phase 2 — the live check there is what decides the verdict — but this flag alone blocks READY-TO-MERGE, because it means execute never established the branch was conflict-free.

    This check reads the artifact and nothing else. Do not compare the branch to the base tip (git merge-base --is-ancestor, rev-list counts, or similar): a branch behind its base that does not conflict is conflict-free, overlapping files or not, and execute was right not to merge (PAD-18-005). Whether being behind blocks the merge is GitHub's call, read in Phase 2 as BEHIND, which execute clears with gh pr update-branch.

Phase 2 — Merge State Gate

This is a hard gate and runs before the per-finding spot checks: a conflicted PR cannot be ready to merge no matter what those checks find.

  1. Re-check merge state live — never reuse the value from either artifact. Add --check-markers when execute.merge_state.conflicts_resolved is non-empty: a resolved-then-recommitted marker passes CI lint on some file types and would otherwise ship.

    bash .agents/skills/shared/verify-merge-gate.sh <number> [--check-markers]
    

    The script runs merge-state.sh once and applies the flag table in its header. CONFLICTING, DIRTY or a surviving <<<<<<</>>>>>>> marker raises MERGE-CONFLICT, even if mergeable says MERGEABLE. UNKNOWN raises MERGE-STATE-UNKNOWN, BEHIND raises BRANCH-BEHIND, and `is_draft:

Полный SKILL.md на GitHub

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

  • REFERENCE.md

FAQ

Что делает скилл pr-verify?

Verification phase of the PR review pipeline. Reads .claude/pr-{number}-execute.json, re-checks mergeability as a hard gate, spot-checks each claimed fix against HEAD (not just the commit diff), validates CI and test suite, and posts a per-finding verdict comment on the PR. Cleans up both artifact files as its final step. Makes NO code changes. Use after /pr-execute, or as the third step of /pr-ship.

Как установить скилл pr-verify?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл pr-verify запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить pr-verify с