Skip to content

🌱 ci: native-queue-policy re-triggers queue instead of cancelling the evidence wait - #16943

Merged
hivecommons-hive[bot] merged 1 commit into
v5from
scanner/fix-16942
Nov 6, 2026
Merged

hivecommons-hive[bot] merged 1 commit into
v5from
scanner/fix-16942

Conversation

@hivecommons-hive

Copy link
Copy Markdown
Contributor

Closes #16942

native-queue-policy could never reach a verdict on a PR the hive is actively staging: every stage-label flip re-fires the pull_request_target run, and cancel-in-progress killed the in-flight 22.5-minute evidence wait each time (173/173 runs cancelled on #16607). The concurrency group already serialises runs per PR, so turning cancellation off makes a re-trigger queue behind the current run instead of aborting it. The newest run still re-reads the mutable PR state after the previous one finishes, so a hold added after a green run still turns the check red — fail-closed semantics are unchanged.

The labeled/unlabeled/edited triggers are kept on purpose and now pinned by a structural-contract test in .github/scripts/test-native-queue-workflows.py, alongside the assertion that the group never cancels.

The issue assumed the App token could not push .github/workflows/**; this branch pushed cleanly, so the only remaining human step is the owner approval the contributor-lane:workflow-path fence asks for.

— hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88

…vidence wait

Stage-label flips fire pull_request_target every few minutes; with
cancel-in-progress the 22.5-minute evidence wait never completed
(173/173 runs cancelled on #16607). Serialise per PR, never cancel.

Closes #16942

Signed-off-by: scanner <280983584+hivecommons-hive[bot]@users.noreply.github.com>
@kubestellar-prow kubestellar-prow Bot added the dco-signoff: yes Indicates the PR's author has signed the DCO. label Nov 6, 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 kellyaa 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/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Nov 6, 2026
@github-actions

github-actions Bot commented Nov 6, 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.

No conflicting open PRs or same-file overlaps were found.

@hivecommons-hive

hivecommons-hive Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor Author

Hive status — updated in place; edits do not notify. Full history is in the Activity Monitor.

hive/awaiting-ci: CI pending — sweep will merge when green (workflow-path fence: needs an owner approval on this head to release).


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

— hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88

Hive filed review findings that do not block this PR as backlog items:

Cap: 10 backlog item(s) per PR per day.

Evidence bundle `#16943d302b8d` sha256:f2f2f2d65b84d83b6afbb1a8b643fd6b2a2b575c3721f554d54a145d132fc006 — download from the dashboard or `hivectl review evidence #16943`.

@hivecommons-hive hivecommons-hive Bot added author/hive This repository's own hive (the App or one of its agent lanes) authored this PR dco All commits are DCO signed-off role/trusted Author is trusted for unattended merge (trusted-author role or registry/claim tier in require_tiers) stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Nov 6, 2026

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Read the workflow at base v5 and the evaluator it drives; this looks correct to me.

What I verified

  • .github/workflows/native-queue-policy.yml:18 — the group was already keyed per PR (github.event.pull_request.number), so flipping cancel-in-progress to false only changes what happens to the in-flight run: it finishes, and the newest re-trigger queues behind it. For merge_group the group is run_id and cancellation was already a no-op, so that path is unchanged.
  • Fail-closed claim holds: .github/scripts/native-queue-policy.cjs:224 and :229 re-fetch the PR with pulls.get and re-run assertEligible (hold/needs-human/do-not-merge labels, :22/:91) after the evidence wait, so a queued run evaluates live state, not the payload it was triggered with.
  • permissions: (lines 10–14) are untouched — still all read.
  • The new contract test runs in CI: pr-auto-update-test.yml:65 invokes test-native-queue-workflows.py, and its path filter (lines 14–15 / 31–32) covers both files in this diff, so the test would have fired here. assertIs(..., False) is the right check — the old value was a string expression, not a boolean.

One behaviour to be aware of (not a defect): with cancel-in-progress: false GitHub keeps at most one pending run per group and replaces it on each new trigger, so intermediate label flips will still show as CANCELLED runs on the PR — but the surviving run is always the newest, which is what you want. Worst-case time to a verdict after a flip during a running wait is roughly two evidence windows (~45 min).

This touches .github/workflows/**, so the contributor-lane:workflow-path owner approval is still the gate; nothing here should block that.

— hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88

@hivecommons-hive

Copy link
Copy Markdown
Contributor Author
d302b8d

ℹ️ Sentinel notice — informational; author is trusted (hive agent), merge is not blocked

Hive flagged this PR (author @hivecommons-hive[bot], head d302b8dfc24e) because it matches behaviors that can override security controls, escalate privileges or damage the codebase. This is a heuristic, not an accusation — a maintainer should confirm the change is intended before it merges.

  • sensitive_path — changes 1 sensitive path(s) (Touches a sensitive path (OWNERS, workflows, policies, hive config, security docs, …))
    • .github/workflows/native-queue-policy.yml

Hive did not add the sentinel-alert label because this author is trusted. The finding remains recorded for audit and the dashboard Security tab; set sentinel.trusted_authors_block: true to require the blocking label for trusted authors too.

@hivecommons-hive hivecommons-hive Bot added stage/060-reviewed Review swarm verdict approve; a gate is still pending (CI running, soak not started) and removed stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Nov 6, 2026
@hivecommons-hive
hivecommons-hive Bot merged commit d9a9583 into v5 Nov 6, 2026
96 of 106 checks passed
@kubestellar-prow
kubestellar-prow Bot deleted the scanner/fix-16942 branch November 6, 2026 17:17
@github-actions

github-actions Bot commented Nov 6, 2026

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 hivecommons-hive Bot removed role/trusted Author is trusted for unattended merge (trusted-author role or registry/claim tier in require_tiers) stage/060-reviewed Review swarm verdict approve; a gate is still pending (CI running, soak not started) labels Nov 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author/hive This repository's own hive (the App or one of its agent lanes) authored this PR copilot dco All commits are DCO signed-off dco-signoff: yes Indicates the PR's author has signed the DCO. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[scanner] native-queue-policy never completes on hive-managed PRs: label flips cancel the 22.5-min evidence wait (173/173 runs cancelled on #16607)

0 participants