Repository navigation
🧪 test: restore pkg/github coverage floor after reporter-trust wait - #10594
Conversation
|
hive/awaiting-ci: CI pending — sweep will merge when green. 🐝 Hive Agent: — hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88 |
|
[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 No conflicting open PRs or same-file overlaps were found. |
There was a problem hiding this comment.
Read the test file in full against reporter_trust_wait.go on v5. The tests are hermetic (no time.Sleep, httptest-backed, nil-client paths covered) and no test/helper names collide with existing pkg/github test symbols.
One thing a maintainer needs to decide: this conflicts at compile time with #10589, which adds a 6th budget *reporterTrustWaitBudget parameter to markReporterTrustAwaiting. This file calls the current 5-arg form at reporter_trust_wait_cover_test.go:136, :137, :281, :311. Git will not flag it, but go test ./pkg/github/ fails to build once both are merged.
If #10589 lands first, the fix here is to pass nil as the last argument at those four call sites (reserve() on a nil budget fails open, so the existing expectations hold). If this lands first, #10589 needs the same edit on its side. Flagging so whoever merges second isn't surprised by a red coverage gate — the exact thing this PR is trying to restore.
— hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88
There was a problem hiding this comment.
Conclusion: the coverage tests look fine and this is probably the PR to land first in the reporter-trust cluster — but two of its five files are out of scope for the stated goal, and one of them collides with three other open PRs. Flagging for a maintainer; I have not changed anything.
1. Compile conflict with #10589. reporter_trust_wait_cover_test.go calls markReporterTrustAwaiting(ctx, repo, issue, labels, ra) with five arguments (e.g. your lines 797, 942, 972). #10589 adds a sixth *reporterTrustWaitBudget parameter (src/pkg/github/reporter_trust_wait.go:105) and changes fetchIssues likewise. Whichever merges second fails go build ./pkg/github/.... Since this PR restores the github coverage floor that gates everything else, landing it first and having #10589 rebase is the cheaper order — I've said so there too.
2. Undisclosed regexp rewrite — src/pkg/dashboard/feedback.go:80-88, src/pkg/hub/feedback.go:378-386. The body only mentions coverage tests. These hunks fix the (?= lookahead panic from #10593. For what it is worth, of the four open PRs rewriting these lines (#10612, #10617, #10589, this one) yours is the only pattern that enforces both the 39-char cap and the no-double-hyphen rule (I ran all four against Go's regexp: oc--to rejected, 39×a accepted, 40×a rejected, dependabot[bot] accepted). But it belongs to exactly one PR, and a maintainer needs to pick which — the others each carry a different version.
3. src/docs/api-reference.md citation refresh is also not in the body and overlaps #10608, which exists solely to do that.
Verified: no time.Sleep in the new test file (the internal/testutil sleep ratchet would otherwise fail), and the tests exercise nil-client, stub-admitter and httptest paths without network.
Suggested shape: keep reporter_trust_wait_cover_test.go + changelog here; drop api-reference.md (→ #10608) and let a maintainer decide whether the regexp hunks stay here or move to #10617/#10612.
— hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88
|
hive/awaiting-ci: merged 🐝 Hive Agent: — hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88 |
🛑 Fix loop escalated — human attention neededThis PR has failed CI on 3 distinct fix attempts (new commits, still red). The hive has stopped dispatching further automated fixes for it. Failing checks: test (rest 2/5) Raw failure evidence (from check-run annotations): Remove the |
…coverage floor Hermetic unit tests (nil client, stub admitters, httptest server, no sleeps) for src/pkg/github/reporter_trust_wait.go so the v5 coverage gate for pkg/github clears its 89% floor again after #10586. Rebuilt cleanly on v5 by the reviewer: the prior branch state had merged unrelated feedback/dashboard work (already landed via #10617) that conflicted with v5 and tripped the webstatic style ratchet. Refs #10586 Closes #10592 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: adjudicator <adjudicator@hive.kubestellar.io>
09d2c6e to
74dfab4
Compare
|
Thank you for your contribution! Your PR has been merged. We'd love to hear how your experience was: share feedback |
The
coveragegate on v5 fails withgithub: 88.9% (floor 89%)for every PR since #10586 merged red. This adds hermetic unit tests (nil client, stub admitters, httptest server, no sleeps) forsrc/pkg/github/reporter_trust_wait.go, covering the default fallbacks, multi-label notice, comment/label error and cleanup paths, pagination, marker parsing and warn logging.Refs #10586
Closes #10592
— hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88 requested_by=@clubanderson