Skip to content

πŸ› Admit operator-trusted registry contributors in the contributor-lane auto-merge tier - #12167

Merged
hivecommons-hive[bot] merged 1 commit into
v5from
fix/contributor-lane-registry-trusted
Oct 15, 2026
Merged

hivecommons-hive[bot] merged 1 commit into
v5from
fix/contributor-lane-registry-trusted

Conversation

@clubanderson

Copy link
Copy Markdown
Member

Fixes #12166

What

The contributor-lane auto-merge tier (#12051) read the contributor's tier only from the hive:claim marker on a closed issue. The operator's own trust tier in the contributor registry had no effect: mrbobbytables is trusted on hive's hive, yet #12045 (Part of #12002, a reference not a closing keyword) skipped with contributor-lane:no-linked-issue and #11756 (claimed outside the relay) with contributor-lane:no-claim.

This adds a second admission path. When the PR author's contributor-registry profile carries a tier in require_tiers (default trusted, merger), the tier requirement is satisfied without a linked issue or marker. The sweep logs contributor-lane admitted reason=contributor-lane:registry-trusted registry_tier=<tier>, the merge log carries admitted_by=contributor-lane:registry-trusted, and the audit comment names the path (@author holds the trusted tier in this hive's contributor registry). A non-trusted (newcomer/contributor/revoked) or absent registry entry falls through to the marker path with its skip reasons unchanged.

Every other gate is untouched: author_association, workflow/test diff fences, CI green, reviewer verdict, soak, exclude labels, sentinel, reporter-trust hold, changes-requested, human-merge paths, head re-check.

Config

  • New key auto_merge.contributor_lane.registry_tiers_sufficient (*bool, default true). false requires the claim marker for everyone.
  • Exposed on GET/PUT /api/config/auto-merge and as a toggle under Settings β†’ Features β†’ Auto Merge β†’ Contributor-lane auto-merge.

Wiring

  • automerge.Options.ContributorRegistryTier (ContributorRegistryTierFunc) injects the lookup so tests fake it; cmd/hive passes dashboard.ContributorTrustTierByLogin (new exported, case-insensitive read over the registry on the PVC).
  • ContributorLanePolicy.RegistryTiersSufficient carries the config flag.

Tests

  • TestTrySweepContributorLanePRRegistryAdmission: registry trusted/merger admits with no linked issue / no marker; case-insensitive login; fences and author_association still apply; newcomer/contributor/revoked/absent entry fall through to no-linked-issue / no-claim; tier outside require_tiers falls through; nil lookup and registry_tiers_sufficient: false keep the marker path; valid claim without registry still merges via marker.
  • Helper tests for the admit path/reason and tier normalisation; ContributorTrustTierByLogin; config default; dashboard API default + PUT.

Docs

src/docs/hive-merge.md, src/docs/operator-reference.md, src/hive.yaml.example, changelog.d/fixed-contributor-lane-registry-trusted.md.

…e auto-merge tier

The contributor lane (#12051) only merged a non-App PR when it closed an
issue whose App-authored hive:claim marker named the author with a
require_tiers tier and verified=true. The operator's own registry tier had
no effect: mrbobbytables is trusted in hive's registry, yet #12045
("Part of #12002", a reference not a closing keyword) skipped with
contributor-lane:no-linked-issue and #11756 (claimed outside the relay)
with contributor-lane:no-claim.

Add a registry admission path: when the PR author's contributor-registry
profile carries a tier in require_tiers, the tier requirement is satisfied
without a linked issue or marker (auto_merge.contributor_lane.
registry_tiers_sufficient, default true). The sweep logs
contributor-lane:registry-trusted and the merge comment names the path.
Every other gate (author_association, diff fences, CI, reviewer verdict,
soak, labels, human-merge paths) is unchanged, and a non-trusted or absent
registry entry falls through to the marker path with its reasons intact.

The lookup is injected as automerge.Options.ContributorRegistryTier
(dashboard.ContributorTrustTierByLogin in cmd/hive) so tests fake it.

Signed-off-by: Andrew Anderson <andy@clubanderson.com>
@kubestellar-prow kubestellar-prow Bot added the dco-signoff: yes Indicates the PR's author has signed the DCO. label Oct 15, 2026
@kubestellar-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign danathar for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubestellar-prow kubestellar-prow Bot added the size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. label Oct 15, 2026
@github-actions

github-actions Bot commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Open PR overlap check

Base branch: v5

Conflicts are checked with every PR merged onto the current tip of v5, so a PR that only needs a rebase is not reported as conflicting with its siblings.

PR Title Relation Files
#12025 ✨ keep unstick steps running in conserve API budget mode same files src/cmd/hive/main.go
src/docs/operator-reference.md
#12164 🌱 tokens: per-issue/PR/head-SHA launch attribution over the token collector same files src/cmd/hive/main.go
src/pkg/dashboard/static/index.html
#12158 ✨ review: add review.shadow to record would_have_held for the review gate same files src/cmd/hive/merge_eligibility.go
src/pkg/config/config.go
src/pkg/dashboard/static/index.html

@hivecommons-hive

Copy link
Copy Markdown
Contributor

merged by Hive trusted-author auto-merge: author @clubanderson holds role owner and GitHub permission admin on repo; CI green at 50368c6.

@kubestellar-prow
kubestellar-prow Bot deleted the fix/contributor-lane-registry-trusted branch October 15, 2026 19:29
@github-actions

Copy link
Copy Markdown
Contributor

Thank you for your contribution! Your PR has been merged.

We'd love to hear how your experience was: share feedback

@hivecommons-hive

Copy link
Copy Markdown
Contributor

Shared-CI triage: relative links and anchors resolve fails here with the same evidence as the open incident #12162 (src/docs/documentation-map.md and src/docs/troubleshooting.md link to a missing src/docs/admin-mcp.md on the v5 base β€” not caused by this PR's diff). Deferring repair to the incident; this PR re-enters the queue when #12162 closes or the base turns green.


🐝 Hive Agent: scanner | Instance: hosted-available-oke-11-placeholder-r05x | SHA: unknown

β€” hive: agent=scanner backend=copilot model=claude-fable-5.1

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

Labels

dco-signoff: yes Indicates the PR's author has signed the DCO. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

πŸ› Contributor-lane auto-merge ignores the operator-set registry tier; trusted contributors skip with no-linked-issue / no-claim

1 participant