fix: rework pickup ignores feedback when the verdict was COMMENT (reassignment starves the agent of context) #476

Closed
opened 2026-08-09 02:05:06 +00:00 by igor · 0 comments
Collaborator

Known gap, now with two field failures (igor#468, 2026-08-09): when a PR is REASSIGNED to the bot while its latest shadow verdict is COMMENT (not REQUEST_CHANGES), the rework agent receives no feedback payload -- .review.pending_rc_body is only populated on an RC verdict -- so it sees nothing actionable and exits without commits. Both rework rounds on #468 stalled exactly this way while an explicit, actionable reviewer comment sat on the thread unread.

The change: in the PR-reassignment pickup path (bin/tick.sh / wherever the rework user message is assembled), when there is no pending RC body, include the recent PR discussion instead: the last shadow-review comment AND any human/operator comments posted after the latest review marker (<!-- review sha=... -->). Fence them as feedback to address, same framing as the RC body gets.

Guard: keep the existing no-op path -- if there are genuinely no comments beyond the reviewed state, the current "no changes made" exit is correct.

Tests: extend the relevant bin/test-*.sh (review/rework surface): (1) reassignment with COMMENT verdict + a post-review operator comment -> the assembled prompt contains that comment; (2) reassignment with no post-review comments -> prompt assembly unchanged from today.

Known gap, now with two field failures (igor#468, 2026-08-09): when a PR is REASSIGNED to the bot while its latest shadow verdict is `COMMENT` (not `REQUEST_CHANGES`), the rework agent receives no feedback payload -- `.review.pending_rc_body` is only populated on an RC verdict -- so it sees nothing actionable and exits without commits. Both rework rounds on #468 stalled exactly this way while an explicit, actionable reviewer comment sat on the thread unread. **The change:** in the PR-reassignment pickup path (`bin/tick.sh` / wherever the rework user message is assembled), when there is no pending RC body, include the recent PR discussion instead: the last shadow-review comment AND any human/operator comments posted after the latest review marker (`<!-- review sha=... -->`). Fence them as feedback to address, same framing as the RC body gets. **Guard:** keep the existing no-op path -- if there are genuinely no comments beyond the reviewed state, the current "no changes made" exit is correct. **Tests:** extend the relevant `bin/test-*.sh` (review/rework surface): (1) reassignment with COMMENT verdict + a post-review operator comment -> the assembled prompt contains that comment; (2) reassignment with no post-review comments -> prompt assembly unchanged from today.
igor self-assigned this 2026-08-09 02:59:28 +00:00
igor added spent time 2026-08-09 03:10:28 +00:00
10 minutes 32 seconds
igor removed their assignment 2026-08-09 03:10:29 +00:00
igor closed this issue 2026-08-09 03:27:49 +00:00
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Total time spent: 10 minutes 32 seconds
igor
10 minutes 32 seconds
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
joshtronic/igor#476
No description provided.