Rename audit report finding type - #55801
Conversation
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Renames the audit-specific finding type to avoid confusion with scanner findings while preserving behavior and JSON output.
Changes:
- Renames
FindingtoAuditFindingacross audit generation and rendering. - Updates test helpers and fixtures to use the renamed type.
Show a summary per file
| File | Description |
|---|---|
pkg/cli/audit_report.go |
Defines and wires AuditFinding. |
pkg/cli/audit_report_analysis.go |
Updates finding generation and recommendation inputs. |
pkg/cli/audit_report_render.go |
Updates finding rendering and filtering. |
pkg/cli/audit_agentic_analysis.go |
Updates agentic finding generation. |
pkg/cli/audit_report_test.go |
Updates audit tests and helpers. |
pkg/cli/audit_agent_output_test.go |
Updates agent-output test fixtures. |
Review details
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
- Files reviewed: 6/6 changed files
- Comments generated: 0
- Review effort level: Balanced
|
✅ PR Code Quality Reviewer completed the code quality review.
|
|
✅ Design Decision Gate 🏗️ completed the design decision gate check. No ADR enforcement needed: PR #55801 does not have the 'implementation' label and has 67 new lines of code in business logic directories (threshold: 100).
|
|
✅ Test Quality Sentinel completed test quality analysis. Test Quality Sentinel skipped: Pre-fetch PR data was unavailable — unable to fetch test file diff. Cannot perform behavioral test quality analysis without diff content.
|
|
✅ Ponytail Reviewer completed successfully! Lean already. Ship.
|
|
🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅
|
There was a problem hiding this comment.
Skills-Based Review 🧠
Applied /codebase-design and /grill-with-docs — this is a clean, well-scoped rename with no logic changes.
📋 Assessment
Positive Highlights
- ✅
AuditFindingis a better name: it distinguishes the audit-report type from scannerFindingstructs in the same package, reducing naming collision risk - ✅ Rename is complete and consistent across all 6 files (generation, rendering, analysis, tests)
- ✅ JSON wire shape (
key_findings) is preserved — no compatibility break - ✅ PR body references the motivating issue and explains the disambiguation
No actionable issues found.
🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · copilot · sonnet46 · 15.4 AIC · ⌖ 9.7 AIC · ⊞ 7.6K
Comment /matt to run again
There was a problem hiding this comment.
Clean, mechanical rename of Finding → AuditFinding across the audit package. The change is complete and consistent — no stray references to the old name remain. The new name is more specific and avoids ambiguity with other potential Finding types in the codebase. No issues found.
🧵 Reviewed using Impeccable skills by Impeccable Skills Reviewer · copilot · sonnet46 · 21.3 AIC · ⌖ 9.02 AIC · ⊞ 6.2K
Comment MemoryNote This comment is managed by comment memory.It stores persistent context for this thread in the code block at the top of this comment.
|
There was a problem hiding this comment.
Verdict
No blocking issues in the changed lines.
Review notes
This PR is a straight rename from Finding to AuditFinding across the audit-report codepath and its tests. The JSON field names stay unchanged, the constructors/call sites were updated consistently, and I did not find a changed-line regression worth blocking on.
I also checked for leftover ambiguous Finding usages in the touched package; the remaining references are to other domains (for example scanfindings.Finding) or unrelated prose/tests, not missed rename sites from this patch.
🔎 Code quality review by PR Code Quality Reviewer · pi · gpt54 · 12.5 AIC · ⌖ 6.87 AIC · ⊞ 7K
Comment /review to run again
|
🎉 This pull request is included in a new release. Release: |
Audit-report insights and scanner findings used the same
Findingname despite representing different data. This renames the audit-specific type to clarify package-local usage.cli.Findingtocli.AuditFinding.key_findingsJSON shape and all existing fields.