Skip to content

🐛 decision path: approve-with-rationale reads as changes_requested, Refs→Fixes rewrite overrides owner decision, 070 deadlock without a new head #14816

Closed

Description

@clubanderson

Observed 2026-10-28 while resolving the requires_human backlog through the hive's own decision path (dashboard POST /api/repos/{owner}/{repo}/items/{n}/decision, /hive decision comments, GitHub reviews). Four places where the owner's recorded decision did not produce the outcome the owner stated, with evidence. Each is a small, separable fix; none needed a manual merge or close.

1. /hive decision approve <rationale> on a hive-authored PR is treated as changes requested

unparkCommand.BareApproval() (pkg/github/issue_unpark_command.go) only recognises the approval when the comment is literally approve/lgtm/yes. A maintainer who writes /hive decision approve followed by a rationale — the natural way to answer a requires_human question — gets mode=changes_requested, the author agent is kicked with the rationale "verbatim", pushes a cosmetic head, and the swarm re-review + human approval start over.

Proposed: treat a /hive decision whose first word is approve/approved/lgtm as an approval and the rest as the recorded rationale; only route to the fix lane when the text does not start with an approval word (or add an explicit /hive decision approve: / --reason form and document it in maintainer-commands.md).

2. The issue-link safeguard rewrote an owner-directed Refs #N back to Fixes #N

On #14628 the owner's decision item 1 was "change Closes #14605 to Refs #14605" (#14605 stays open for two further expectations). The agent applied it at 01:15Z; at 01:44Z EnsureIssueStagePRLink → rewriteRefsIssueLinkToClosing (pkg/github/pr_issue_link.go) rewrote it to Fixes #14605 and stamped <!-- hive:issue-link-fixed --> — see the PR's edit history (editor hivecommons-hive, 2026-10-28T01:44:05Z). Had the PR merged, #14605 would have auto-closed against the recorded human decision. bodySaysIssueStaysOpen did not match the wording "… remain open on the issue".

Proposed: never upgrade Refs→Fixes on a PR head that carries a recorded human decision / hive:decision-head marker; and treat a Refs written after a Closes (body edit history, or the agent's own "applied the decision" comment) as intentional. I restored Refs by hand (the marker now prevents a second rewrite).

3. 070-fixing deadlock when the recorded change request needs no new head

A changes-kind HumanChangeRequest on head H keeps HumanChangeRequestStage → 070 until a new head appears (humanChangesRequestedForHead falls back to the standing store entry even with no CHANGES_REQUESTED review). When the requested change is a body/metadata edit, no head ever appears: #14628 sat at stage/070-fixing + stage/stalled for ~2h after the agent reported done. Neither a GitHub APPROVED review on H nor a /hive decision approve comment can release it — the un-park sweep only reads /hive decision on PRs wearing stage/085 (issue_unpark_command.go). The only release was the dashboard direction API with text approve (which records an approval-kind entry that outranks the standing one): #14628 (comment)

Proposed: let a trusted APPROVED review on H (or the agent's "applied, no head change" completion) clear the standing change request; and read /hive decision approve on 070 as well as 085.

4. Trusted CHANGES_REQUESTED review on a contributor PR did not move it off 085 (crux)

hivecommons/crux#22: owner CHANGES_REQUESTED review on head 40de8a11 at 2026-10-28T00:23Z (hivecommons/crux#22 (review) — see reviews tab), re-stated at 02:37Z; at 03:40Z the PR still wears stage/085-needs-decision. Per TrustedHumanChangeRequested it should derive 072/returned-to-contributor and nudge the author. Possibly crux is outside the lane's trusted-merger config or the review is not read for contributor PRs there — worth a look.

What worked (for the record)

close-superseded via the decision API on contributor and hive PRs: #14702→#14695, #14795→#14791, #14779→#14772, #14794→#14788, #14803→#14807 — each closed with hive/superseded and an attributed comment, first try. direction: approve on hive PRs #14628/#14758 recorded mode=approve.

Activity

  1. added
    help wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.
    on Oct 28, 2026
  2. hivecommons-hive commented on Oct 28, 2026

    @hivecommons-hive
    Contributor

    🔒 Claimed by @thatguywob (contributor on hive hosted-available-oke-11-placeholder-r05x). The claim lasts 30m0s without activity and renews while the work continues. Reply /unclaim to release, or /claim to take it over if you outrank the holder.

  3. clubanderson commented on Oct 28, 2026

    @clubanderson
    MemberAuthor

    5. Contributor PR at stage/085-needs-decision does not advance after the owner's CHANGES_REQUESTED review

    #14701 (author Karibhou, contributor): reviewer swarm returned requires_human → stage 085. Owner's /hive decision approve with a "retarget to v6" rationale was refused (hive did not open the PR, 01:04Z). Owner delegate then submitted a formal GitHub review CHANGES_REQUESTED (03:33Z) with the same verdict. 20+ min later the PR still carries stage/085-needs-decision and shows "Needs human decision" in the activity monitor, although the human decision now exists on the PR as a review. Expected: an owner (or owner-delegate) review of CHANGES_REQUESTED / APPROVED on a 085 item resolves the decision and moves the stage to 071-needs-author / 050-review-pending respectively, for contributor PRs as well as hive-authored ones.

  4. hivecommons-hive commented on Oct 28, 2026

    @hivecommons-hive
    Contributor

    🔓 Claim by @thatguywob released (lease revoked).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions