Repository navigation
🐛 fix(github): attribute human-merge path holds and document pin-only rollout - #16293
Conversation
Provide a conservative shared release API and document pin-only rollout prerequisites. Admission integration remains pending the classifier/config and relay/sweep siblings. Hive-Run: hivecommons#16269 Hive-Plan: human-merge pin-only hold attribution and operator rollout Hive-Spec: hivecommons#16269#changes Signed-off-by: mendezr <mendezr@users.noreply.github.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
@mendezr this PR is back in your court ( Failing checks:
Reply here or push a new head to this branch (same sign-off); CI and the review swarm re-run automatically and the PR returns to the normal path. Your relay could not take this as a |
Signed-off-by: mendezr <mendezr@users.noreply.github.com>
Signed-off-by: mendezr <mendezr@users.noreply.github.com>
Open PR overlap checkBase branch: Conflicts are checked with every PR merged onto the current tip of
|
There was a problem hiding this comment.
Decision needed: @clubanderson should decide whether this pin-only groundwork (a new ReleaseHumanMergePathHold API with no production caller yet, plus head attribution on new hold comments) should land now, ahead of its consumers #16262/#16265/#16266 under #16242.
Conclusion: The code is fail-closed and I found no defect; the question is sequencing, which is a maintainer's call, not mine.
What I verified from the tree:
src/pkg/github/human_merge_path_release.go:38—ReleaseHumanMergePathHoldhas no caller outside its own test (grepacrosssrc/); the only runtime effect of this PR ishuman_merge_paths.go:103-118,130-133, which appends<!-- hive-human-merge-path-head: <sha> -->to a new hold comment when the live head matches and the hold label was not already present. Both call sites (automerge_human_paths.go:74,human_merge_paths.go:218) now passpr.GetHead().GetSHA(); the variadichead ...stringkeeps the exported signature source-compatible.- Every ambiguous path in the release function returns
(false, nil): wrong/short head, non-App or non-Botcomment author, a second marker comment, an edited comment (UpdatedAt != CreatedAt), a marker equal to the current head, anylabeled/unlabeledtransition other than exactly one App-appliedlabeledwithin 60 s before the notice, and a head change between the twoPullRequests.Getcalls. That matches the contract in the doc comment. human_merge_path_release.go:150gates the label removal aswriteback.KindHoldGateNotice, whichwriteback/kinds.go:126marksOwnOnly: trueandgate.go:442enforces as "only ever writes on hive-authored items". So, as written, the release can only ever fire on an App-authored PR. If the pin-only exception is meant to cover human-authored pin bumps too, this is the line that will block it; if it is meant for Hive pin PRs only, this is correct and worth stating insrc/docs/hive-merge.md. Not a defect, but the consumers should know before they wire it.
Body and diff agree: the body and src/docs/hive-merge.md:157-178 both say this change alone does not enable the exception.
— hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88
|
Needs a decision, not a merge:
Head: verdict requires_human @82b9781, 59/59 checks green, DCO yes, soak 10m0s elapsed. How to release it:
Clear the cause and the hive re-evaluates on its next pass; the stage moves to |
|
Needs a decision, not a merge:
Head: verdict requires_human @82b9781, 59/59 checks green, DCO yes, soak 10m0s elapsed. How to release it:
Clear the cause and the hive re-evaluates on its next pass; the stage moves to |
Summary
ReleaseHumanMergePathHold, a shared, fail-closed API requiring a later qualified head, configured App identity, an unedited attributed App notice, and complete label-event history. Human/re-added/ambiguous holds remain untouched.Refs #16269 — partial: automatic release still needs wiring after qualification in the relay and sweep once #16262, #16265 and #16266 provide their APIs; a concrete minimum released version and live Utah deployment evidence also remain outstanding. This PR deliberately does not duplicate their classifier or enable an exception on a branch that lacks its schema. Parent: #16242.
Integration contract
Call
github.ReleaseHumanMergePathHold(ctx, ghClient, owner, repo, number, appLogin, expectedHead, qualified)only after enabled pin-only admission qualifies that exact head. Re-read labels afterwards and preserve the existing exact-head merge guard and every other gate. Legacy/edited notices, multiple hold transitions, or unavailable history fail closed. The new API has no production release callers in this partial PR.Validation
gofmt -lon changed Go files: clean.git diff --check: clean.AGENTS.md; CI is the test verdict.— hive: backend=pi model=openai-codex/gpt-6.1-sol
Closes #16269
🐝 Hive Agent:
contributor| SHA:78d7d84fa