Skip to content

feat(vetted-ops): extend the catalogue to the PR-management family - #1177

Merged
potiuk merged 2 commits into
apache:mainfrom
potiuk:feat/vetted-ops-pr-family
Sep 8, 2026
Merged

potiuk merged 2 commits into
apache:mainfrom
potiuk:feat/vetted-ops-pr-family

Conversation

@potiuk

@potiuk potiuk commented Sep 8, 2026

Copy link
Copy Markdown
Member

The dispatcher shipped with an issue-shaped catalogue because the security lifecycle is where the sweep volume first appeared. PR management makes the same shape of many small forge writes — a triage pass over the open queue answers a wildcard ask per label flip — so it gets the same treatment. This is future-work item 2 from the spec, for the first family.

22 operations: list / view / diff / comments / reviews; the label, milestone, assignee and reviewer edits; the three review verdicts; draft, ready, close and branch update; failed-job re-run and first-time-contributor workflow approval. The catalogue goes 19 → 41 ops.

GraphQL is the interesting part. gh api graphql takes a query as a string — precisely the unbounded surface this catalogue exists to remove — and the PR skills make two narrow, repeated GraphQL calls. Rather than a generic escape hatch, each document in src/vetted_ops/queries/ registers as its own operation taking only the variables it needs: the caller names a query, the dispatcher supplies the text, and owner/name come from policy. A caller can choose among the allowlisted queries; it cannot write one, and cannot re-aim one at another repository.

There is deliberately no pr-merge. Merging is this framework's deferred Agentic Autonomous mode — pr-management-quick-merge prints a merge command for the maintainer rather than running one — so a vetted merge operation would hand the agent the one capability the surrounding design withholds. A test asserts its absence so the reasoning survives the next person who notices the gap.

Caller manifests stay adopter-owned by design (a caller must not be able to widen its own policy), so the README's example config gains PR-family entries rather than the repo shipping manifests of its own.

Tests: 29 pass, including the catalogue-wide "every parameter has a validator" and "every builder produces a gh argv" sweeps, which now cover the new operations.

First in a family-by-family series; repo health and release management follow, and the spec records them as what remains.

🤖 Generated with Claude Code

https://claude.ai/code/session_015qpVgY8ADkD9c7vYZk5imP

The dispatcher shipped with an issue-shaped catalogue because the security
lifecycle is where the sweep volume first appeared. PR management makes the
same shape of many small forge writes — a triage pass over the open queue
answers a wildcard `ask` per label flip — so it gets the same treatment.

Twenty-two operations: list / view / diff / comments / reviews; the label,
milestone, assignee and reviewer edits; the three review verdicts; draft,
ready, close and branch update; failed-job re-run and first-time-contributor
workflow approval.

GraphQL is the interesting part. `gh api graphql` takes a query as a string,
which is precisely the unbounded surface this catalogue exists to remove, and
the PR skills make two narrow, repeated GraphQL calls. Rather than a generic
escape hatch, each document in `src/vetted_ops/queries/` registers as its own
operation taking only the variables it needs: the caller names a query, the
dispatcher supplies the text, and owner/name come from policy. A caller can
choose among the allowlisted queries; it cannot write one, and cannot re-aim
one at another repository.

There is deliberately no `pr-merge`. Merging is the framework's deferred
Agentic Autonomous mode — `pr-management-quick-merge` prints a merge command
for the maintainer rather than running one — so a vetted merge operation would
hand the agent the one capability the surrounding design withholds. A test
asserts its absence so the reasoning survives the next person who notices the
gap.

Caller manifests stay adopter-owned by design (a caller must not be able to
widen its own policy), so the README's example config gains PR-family entries
rather than the repo shipping manifests of its own.

Generated-by: Claude Code (Opus 5)
Comment thread tools/vetted-ops/src/vetted_ops/ops.py Dismissed
Apache RAT failed on apache#1177: the two `.graphql` files carried no approved
licence header. GraphQL takes `#` comments, so the standard ASF block goes in
unchanged and the documents parse exactly as before.

RAT runs as its own workflow rather than a prek hook, so an unstamped file is
invisible locally and only surfaces after the PR is pushed — and
`add-license-headers.py` covers Markdown alone, by design. A test now asserts
every shipped query carries the header, which puts the feedback where the file
is written instead of two minutes into CI.

Generated-by: Claude Code (Opus 5)
@potiuk
potiuk merged commit 3ec8dbf into apache:main Sep 8, 2026
9 checks passed
potiuk added a commit to potiuk/magpie that referenced this pull request Sep 9, 2026
Seven changes have landed behind the previous stamp: the agent-guard plugin
move (apache#1170), the doctoc URL fix (apache#1171), the marketplace re-sync plus the
self-correcting prek hook (apache#1174), the vetted command surface (apache#1176), and the
three PRs that extended its catalogue from 19 to 58 operations (apache#1177, apache#1178,
apache#1179). `claude plugin update` compares version strings, so none of that
reaches an adopter until the stamp moves.

Mechanical: `project.version` edited, then
`tools/dev/check-family-plugins.py --fix` propagated it to the five ecosystem
manifests and the eleven per-family plugin manifests plus the marketplace
entries, and `uv lock` refreshed the workspace's own package version.

Generated-by: Claude Code (Opus 5)
potiuk added a commit that referenced this pull request Sep 9, 2026
Seven changes have landed behind the previous stamp: the agent-guard plugin
move (#1170), the doctoc URL fix (#1171), the marketplace re-sync plus the
self-correcting prek hook (#1174), the vetted command surface (#1176), and the
three PRs that extended its catalogue from 19 to 58 operations (#1177, #1178,
#1179). `claude plugin update` compares version strings, so none of that
reaches an adopter until the stamp moves.

Mechanical: `project.version` edited, then
`tools/dev/check-family-plugins.py --fix` propagated it to the five ecosystem
manifests and the eleven per-family plugin manifests plus the marketplace
entries, and `uv lock` refreshed the workspace's own package version.

Generated-by: Claude Code (Opus 5)
@potiuk potiuk added the substrate:sandbox Tool substrate: agent isolation, egress control, settings audit label Sep 25, 2026
@potiuk potiuk added family:docs Docs, MISSION.md, READMEs family:tools tools/* labels Nov 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

family:docs Docs, MISSION.md, READMEs family:tools tools/* substrate:sandbox Tool substrate: agent isolation, egress control, settings audit

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants