You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@magpie.apache.org by "potiuk (via GitHub)" <gi...@apache.org> on 2026/10/10 08:46:33 UTC
[PR] feat(pr-management): plug skill families into the tool, and guard review mentions [magpie]
potiuk opened a new pull request, #1579:
URL: https://github.com/apache/magpie/pull/1579
## Summary
Groundwork for moving the remaining `pr-management` skills onto `tools/pr-management`, after #1570 / #1571 / #1572:
- `pr-management` discovers a family's subcommands from `pr_management.<family>.cli` (`FAMILY`, `add_parsers`, `dispatch`), and vetted-ops loads per-family `ops_<family>.py` modules shipped in the package, so each skill adds its commands and reads without editing a shared file. The catalogue stays closed: only modules inside the package load.
- The agent-guard `mention` guard now also covers review posting (`gh pr review --body/--body-file`) and every value a non-GET `gh api` call sends, whatever the endpoint: every `-f` / `-F` / `--raw-field` / `--field` spelling `gh` accepts (including `@file`) and every `--input` string. No endpoint or mutation list to fall behind. Text it cannot read (stdin, an unreadable file) is refused instead of passing unseen.
- It allows the one mention the mentoring hand-off exists to make: the configured maintainer team, alone, in a body opening with the hand-off template line, and only within the target repository's own organisation.
Bottom of a stack of seven; each skill PR above builds on this one.
## Security notes
The hand-off exemption here trusts a *committed, unmodified* local `mentoring-config.md`. The top PR of the stack (mention allowlist) replaces that with a read from the target repository's default branch on GitHub, so a scratch repository the agent creates cannot satisfy it. **Please merge the stack together** rather than this PR alone.
## Type of change
- [x] Tool change (agent-guard, vetted-ops, tools/pr-management)
## Test plan
- [x] `prek run --all-files` passes
- [x] agent-guard pytest: new cases for review posting, every `gh api` write spelling, uninspectable bodies and the hand-off exemption
- [x] `tools/pr-management` and vetted-ops pytest / ruff / mypy
---
##### Was generative AI tooling used to co-author this PR?
- [x] Yes — Claude Code (Opus 5). I reviewed the diff and the test results; commits carry `Generated-by:`.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
https://claude.ai/code/session_01GTPsZ5aEE5bUVYqp47Dpvv
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@magpie.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(pr-management): plug skill families into the tool, and guard review mentions [magpie]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk merged PR #1579:
URL: https://github.com/apache/magpie/pull/1579
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@magpie.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org