Documentation
¶
Overview ¶
Package triage applies deterministic, user-directed suppression to findings AFTER analysis: inline `godzilla:ignore` source directives and a fingerprint baseline file. Both are the recourse a CI gate needs — a legacy codebase can be baselined so only NEW findings block a PR, and a reviewed false positive can be silenced at the source — without disabling a rule globally. Suppressed findings are RETAINED and flagged (analysis.Finding.Suppressed), not deleted, so they stay auditable, mirroring the LLM reviewer's behavior.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyBaseline ¶
ApplyBaseline marks findings whose fingerprint appears in the baseline as suppressed. Fingerprints are matched as a MULTISET: a baseline entry that appears twice suppresses at most two matching findings, so a genuinely new duplicate at the same location still surfaces. Findings are processed in a deterministic order so the choice of which duplicate is suppressed is stable.
func ApplyInlineIgnores ¶
ApplyInlineIgnores marks any finding whose sink line (or the line directly above it) carries a godzilla:ignore directive as suppressed. It returns the same slice with the matched findings flagged. Source files are read at most once each. A finding already suppressed (e.g. by the LLM reviewer) is left as-is.
func LoadBaseline ¶
LoadBaseline reads a Baseline document from path and returns its fingerprints.