Webhook intake for pull_request_review and _comment events #1174

Closed
opened 2026-10-27 13:39:19 +00:00 by sam · 0 comments
Owner

Extend internal/forge/webhook/receiver.go to decode pull_request_review and
pull_request_review_comment behind the existing HMAC verification, producing
the same ReviewCommentEnvelope the poll backstop produces.

Step 6 of docs/prds/pr-review-remediation.md. A producer, so it comes after
its consumer and the owned-task guard, per the PRD's sequencing note: built
first it publishes into nothing, and becomes an unguarded intake the moment a
stream appears. That is what PR #859 did.

PR #859 (closed unmerged) has a usable decode for both event types. Reusable
with corrections: it filtered only on r.botUser, carried no Kind in the key,
and its reviewFromEvent exceeded the cyclop limit.

Webhook intake still refuses to start when identities is configured, so
the identity used to exclude archie's own comments is the receiver's single
configured one here; the poll path must use the task's identity instead.

Depends on archie-core-8li9.4.

Acceptance: a signed pull_request_review for an archie-owned PR enqueues one
reaction; for a PR archie does not own, it is dropped and counted; an unsigned
body never reaches the parser.

Close reason

Closed on GitHub; syncing bead state


Imported from beads archie-core-8li9.5 · GitHub #942 · type feature · priority P2 · created 2026-09-18 · closed 2026-09-26

Extend internal/forge/webhook/receiver.go to decode pull_request_review and pull_request_review_comment behind the existing HMAC verification, producing the same ReviewCommentEnvelope the poll backstop produces. Step 6 of docs/prds/pr-review-remediation.md. A producer, so it comes after its consumer and the owned-task guard, per the PRD's sequencing note: built first it publishes into nothing, and becomes an unguarded intake the moment a stream appears. That is what PR #859 did. PR #859 (closed unmerged) has a usable decode for both event types. Reusable with corrections: it filtered only on r.botUser, carried no Kind in the key, and its reviewFromEvent exceeded the cyclop limit. Webhook intake still refuses to start when [[identities]] is configured, so the identity used to exclude archie's own comments is the receiver's single configured one here; the poll path must use the task's identity instead. Depends on archie-core-8li9.4. Acceptance: a signed pull_request_review for an archie-owned PR enqueues one reaction; for a PR archie does not own, it is dropped and counted; an unsigned body never reaches the parser. ### Close reason Closed on GitHub; syncing bead state --- _Imported from beads `archie-core-8li9.5` · GitHub #942 · type feature · priority P2 · created 2026-09-18 · closed 2026-09-26_
sam added the mediumfeature labels 2026-10-27 13:39:19 +00:00
sam self-assigned this 2026-10-27 13:39:19 +00:00
sam closed this issue 2026-10-27 13:39:19 +00:00
sam added a new dependency 2026-10-27 13:42:19 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Reference: sam/archie#1174