Repository navigation
π fix(ci): port DCO provider-unavailable classification to v6 policy script - #16467
Conversation
β¦script Backport of the policy-script half of #16442 (head 0ac19df) to v6: native-queue-policy.cjs gains ProviderUnavailable and the narrow dcoEnumerationUnavailable classifier (applied only after the App-1861 / exact-head / completed checks; still fails admission), its regression tests, the read-only diagnose-dco-provider reproducer and its tests, and the operator runbook. Why v6 first: .github/workflows/native-queue-policy.yml exists only on v5 and is the default-branch definition GitHub uses for every pull_request_target run, while the job checks out the PR base branch's scripts. Once #16442's yml lands on v5 it imports ProviderUnavailable from the checked-out script; on a v6 base that must exist, otherwise 'error instanceof undefined' throws inside the catch and breaks the bounded wait for pending evidence on every v6-base PR. Landing this first keeps v6-base admission intact and lets v6 report the ceiling case as UNKNOWN honestly. No workflow, permission, protection or trust change. Refs #16404. Signed-off-by: clubanderson <andy@clubanderson.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 |
Open PR overlap checkBase branch: Conflicts are checked with every PR merged onto the current tip of
|
There was a problem hiding this comment.
Read this against v6 at the merge-base and against #16442's head 0ac19dfa3. The backport is faithful and looks correct to me.
What I verified
- The
native-queue-policy.cjsand.test.cjshunks applied here are line-for-line identical to #16442's hunks againstv5(git diff origin/v6 e2f84ddvsgit diff origin/v5 0ac19dfa3, added/removed lines compared). The remaining difference between the two resulting files (closedNoop,isTransientAPIError/evaluateOnce) is pre-existing v5/v6 divergence, not something this port dropped. diagnose-dco-provider.cjs, its test anddocs/operations/dco-provider-unavailable.mdare byte-identical to #16442.- Guard ordering in
.github/scripts/native-queue-policy.cjs:92-96:dcoEnumerationUnavailableis only consulted after the App-1861/exact-head check and thecompletedcheck, and it can only throw β there is no path by which the summary text becomes passing evidence. An unmatchedfailuresummary still reaches the plainDCO: failurethrow (covered by the last assertion in the newUNKNOWN reporting requiresβ¦test). node --test .github/scripts/on this head: 26 pass, 0 fail.- The sequencing claim in the body holds:
.github/workflows/native-queue-policy.ymldoes not exist onv6, andv5's current definition (line 41) destructures only{ evaluate, PendingEvidence }. Once #16442 lands onv5it destructuresProviderUnavailableand doeserror instanceof ProviderUnavailablein the catch; with v6's script not exporting it that isinstanceof undefinedβTypeErroron every v6-base run. With this port merged first, v6 exports the class and the check degrades to the intended UNKNOWN message. Until #16442 merges, aProviderUnavailablethrown on v6 just propagates as a non-PendingEvidencefailure β admission stays blocked either way. diagnose-dco-provider.cjsshells out viaexecFileSync('gh', args)withowner/reporestricted to[\w.-]+andnumberto a positive safe integer, so no argument injection; the GraphQL document is a read-only query.
No workflow, permission or protection surface changes in this diff. Sequencing (this before #16442, and how #16378 picks up the excluded yml/doc paragraph) is a maintainer call; nothing in the code blocks it.
β hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88
|
Hive status β updated in place; edits do not notify. Full history is in the Activity Monitor. Review findings from Read the v6 tree at the PR head ( What I verified
One sequencing note (not a defect)
No workflow, permission or protection file changes; UNKNOWN still fails admission as stated. Evidence bundle `#16467e2f84dd` sha256:9067839e5b43f5eadaf5bc262f4f4620944f887992b9ad6ee0943178b2f52f25 β download from the dashboard or `hivectl review evidence #16467`. |
|
Thank you for your contribution! Your PR has been merged. We'd love to hear how your experience was: share feedback |
β¦the top-up Plain merge of origin/v6 (5c963b7) into the v5->v6 top-up; the only conflicts were the additive export/import lists in .github/scripts/native-queue-policy.cjs and its test, resolved to the union, which is byte-identical to v5 after #16442 (ed048ec). Signed-off-by: clubanderson <andy@clubanderson.com>
Backport of the policy-script half of #16442 (head
0ac19dfa36e6fbe46e50120ddced291fac3a7bdb) tov6, so that v6 receives it before #16442's workflow change becomes the default-branch definition.Why this has to land first.
.github/workflows/native-queue-policy.ymlhas never existed onv6, yetnative-queue-policyruns on v6-base PRs (e.g. run 41684812577 on #16378:path: .github/workflows/native-queue-policy.yml, checkoutref: refs/heads/v6). GitHub takes thepull_request_targetworkflow definition from the default branch (v5) and the job then checks out the PR base branch's scripts. #16442's yml doesconst { evaluate, PendingEvidence, ProviderUnavailable } = require(...)anderror instanceof ProviderUnavailableinside the catch; against v6's current scriptProviderUnavailableisundefined, which throwsTypeError: Right-hand side of 'instanceof' is not an objectand replaces the bounded wait for pending evidence on every v6-base PR. With this port in place v6's script exports the class, and a v6-base PR hitting the DCO App's 250-commit enumeration ceiling reports DCO provider unavailable / verdict UNKNOWN instead of a bareDCO: failure.What is included (identical content to #16442 at
0ac19dfa3):.github/scripts/native-queue-policy.cjs:ProviderUnavailable+dcoEnumerationUnavailable, thrown only after the App-1861 / exact-head trust check and thecompletedcheck. Admission still fails; an unrecognised summary still falls through toDCO: failure..github/scripts/native-queue-policy.test.cjs: the two regression tests..github/scripts/diagnose-dco-provider.cjs+ test: read-only enumeration reproducer, wired only intonode --test.docs/operations/dco-provider-unavailable.md: operator runbook referenced by the error message.Deliberately excluded on v6: the yml (not present on v6; v5's definition is what runs),
pr-auto-update-test.ymlwiring and thesrc/docs/native-merge-queue.mdparagraph (v6's copies have diverged; the v5βv6 top-up #16378 carries them).No workflow, permission, protection or trust change. UNKNOWN still fails admission. This does not unblock #16378 by itself; a genuine current-head App-1861 DCO success is still required there.
Refs #16404