Repository navigation
ci: ratchet discarded call results (_ = f()) in non-test Go - #745
Merged
Merged
Conversation
Freezes non-test Go statements that discard a call's results at today's count with the shared count-ratchet action. Complements the diff-only errcheck gate in ci.yml. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: James Reilly <jreilly1821@gmail.com>
Contributor
73aef38
ℹ️ Sentinel notice — informational; author is trusted (owner), merge is not blockedHive flagged this PR (author @hanthor, head
Hive did not add the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a
Ratchetworkflow using the sharedcount-ratchetaction (tuna-os/.github#389), pinned to8ecf20e. Budgets live in.ratchet.toml, seeded at today's counts on main.discarded-errors_ = f(...)/_, _ = f(...)Only a call on the right-hand side counts;
_ = unusedVardoes not (that is how 181 became 174). Excludes*_test.go,testdata/,e2e/,vendor/.Rules: count > budget fails; count < budget fails with the exact new budget to write (so improvements lock in); a PR that raises a budget or removes a metric needs the
ratchet-raiselabel. A job-summary table shows count/budget/delta.actions.lockregenerated withgh actions-lock.🤖 Generated with Claude Code