[sergo] Sergo Report: CACHED-reconcile+NEWEXPLORE-registry-mechanism-audit - 2026-09-05 #58713
Closed
Replies: 1 comment
|
This discussion has been marked as outdated by Sergo - Serena Go Expert. A newer discussion is available at Discussion #58915. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Executive Summary
Strategy this run: CACHED-reconcile-expired-issues + NEW-EXPLORE registry-mechanism-change audit. Reconciled all 5 open
sergoissues against current code (all still valid, none duplicated), discovered the linter registry mechanism changed since the last recorded strategy entry, and audited 8 previously-unreviewed/edge-case linters. Filed 1 new issue: a re-file of a self-expired, still-unfixed bug.Tool & Registry Changes
cmd/linters/main.gono longer enumerates individual analyzers — it now just callsmultichecker.Main(linters.All()...). The old detector (grep -c Analyzer main.go) is dead (returns 0). The canonical analyzer count now lives inpkg/linters/registry.go'sallAnalyzersslice: 67 analyzers, cross-checked against thedoc.go:3"All 67 active analyzers" header — they agree.Strategy Split
Cached (reconcile): Pulled all
sergo-labeled issues viagh api(open + a sample of closed) and cross-referenced against current code, rather than assuming closed = fixed or open = still-actionable.HasOverlappingCommentguard gap), goroutinemissingrecover: recover-defer placed after risky code is accepted as safe, but never protects earlier statements #58150 (goroutinemissingrecoverrecover-after-risky-code), generatedyamlheredoc: literal<<inside a quoted shell string is misreported as a heredoc #57606 (generatedyamlheredocquoted-heredoc false positive), stringsconcatloop: self-referential ASSIGN form misses map-index/selector accumulators #57340 (stringsconcatloopmap-accumulator gap), sprintferrdot: verb-set check still wrong both directions after issue 40434 closed #57339 (sprintferrdotverb-set check).state_reason: not_planned), not landed — see finding below.New exploration: Deep-read 8 linters with no prior dedicated bug audit or a fresh look at edge cases:
nilctxpassed,trimleftright,ioutildeprecated,logfatallibrary,httpstatuscode,excessivefuncparams,fmterrorfnoverbs,goroutinemissingrecover.Findings
1. Re-filed:
errorfwrapv/fmterrorfnoverbsconcatenated-format-string blind spot hides a live%v-vs-%wbug (new issue)pkg/cli/audit_run_pipeline.go:317-325'scacheRecoveryErrorstill formats its trailingerrargument with%vinstead of%w, breakingerrors.Is/errors.Aschain inspection — even though the same file relies onerrors.Is(err, ErrNoArtifacts)elsewhere for control flow. This was first filed as #56533; that issue auto-expired on 2026-09-03 withstate_reason: not_plannedand zero code change. Re-verified today: the bug is unchanged, and botherrorfwrapvandfmterrorfnoverbsstill extract format strings viacall.Args[0].(*ast.BasicLit)only, so neither can see through themessage+"..."concatenation to check it. A repo-wide grep confirms this is the only production call combining a concatenated format string with a%v-formatted error argument today.Findings that were investigated and ruled clean / already covered (not filed):
httpstatuscode: only narrow-heuristic coverage gaps (e.g., named integer types without "http"+"status" in the name skip the variable-name fallback) — a design limitation, not a bug.logfatallibraryand 4 sibling linters mixpass.Fset.Position()andpass.Fset.PositionFor(pos, false)for the generated-file-skip check — investigated and ruled out:filecheck.BuildGeneratedIndexdeliberately indexes both the original and (lineadjusted/redacted) filenames, so either call convention resolves correctly.goroutinemissingrecover's "any top-level defer/recover anywhere in the body" check matches goroutinemissingrecover: recover-defer placed after risky code is accepted as safe, but never protects earlier statements #58150 exactly (already open, not re-filed).nilctxpassed,trimleftright,ioutildeprecated,excessivefuncparams: read in full, no correctness bugs found.Generated Task
cacheRecoveryError(pkg/cli/audit_run_pipeline.go:317-325) to wraperrwith%w, and hardenerrorfwrapv/fmterrorfnoverbsformat-string extraction to resolve constant-foldable string concatenation via a sharedastutilhelper (tracked in the new issue).Metrics
Historical Context
sergoissue is not proof of a fix — issues carry a self-expiry checkbox and auto-close withstate_reason: not_plannedif nobody acts before the deadline. Both directions (open-but-landed, and closed-but-unfixed) require re-grepping the actual code before trusting issue status.Next-Run Focus
pkg/cli/audit_run_pipeline.gofor%w).pkg/linters/registry.goanalyzer count vs.doc.goheader for the next registry delta.References:
Warning
Firewall blocked 1 domain
The following domain was blocked by the firewall during workflow execution:
api.anthropic.comTo allow these domains, add them to the
network.allowedlist in your workflow frontmatter:See Network Configuration for more information.
All reactions