Skip to content

feat(reporting): reconcile stable finding IDs across report formats - #310

Merged
rng1995 merged 19 commits into
mainfrom
naren/port-stable-finding-ids
Nov 5, 2026
Merged

rng1995 merged 19 commits into
mainfrom
naren/port-stable-finding-ids

Conversation

@rng1995

@rng1995 rng1995 commented Nov 2, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Reports now count findings one way, and every finding has stable IDs.

  • Finding IDs. Finding has two new properties, and Finding.to_dict() emits both:
    • finding_id (SEF- plus 20 hex characters) is a SHA-256 of the category, check name, message and suggestion. Case and extra whitespace are ignored. It does not include location or severity, so it stays the same when a finding moves to another line or file, or when a policy or verifier changes its severity.
    • Location text a check copies into its message is left out of the hash, so those IDs survive line moves too: the in <file>:<line> in a secret detection message, and the — N occurrences (...) list the PII scan appends when it folds repeats of one value. The secret location is also left out when a folder run ([skill] prefix) or a plugin scan (member directory) has changed the finding's file_path but not its message, by matching the message's path against the end of file_path. The visible message is unchanged. Other message and suggestion text stays in the ID: script lint names the script in its messages and secret detection names the file in its suggestion, so the same problem in two files has two IDs.
    • occurrence_id (SEO-...) adds the file path (with / separators), line number and line content, so it identifies one location. Line 0 and "no line" give different IDs. Finding.location_occurrence_id(file, line) gives the ID at another location a finding lists.
    • Identical findings in different files or skills share one finding_id, so they count as one unique finding with one occurrence per location. A three-skill collection that misses the same description field reads "1 unique finding / 3 occurrences", and each skill shows 1 finding.
  • New module reporting/finding_summary.py.
    • summarize_findings groups raw findings by finding_id across validators. Each group keeps every distinct occurrence and the highest severity. A finding that lists its repeated locations in metadata["occurrences"] (the PII scan folds repeats of one value this way) contributes one occurrence per listed location, so its Occurrences count matches the "N occurrences" in its message. ValidationResult.merge_with_prefix now prefixes each listed occurrences[].file the same way as file_path (on a copy of the metadata), so a folder run does not count the finding's own location twice.
    • It returns raw_occurrences (raw records), distinct_occurrences, unique_findings, duplicates_removed (reported locations that repeat one already counted), occurrences_grouped, raw_by_severity and unique_by_severity.
    • merge_finding_summaries combines per-result summaries without hashing again.
    • summarize_messages returns independent_errors and independent_warnings: error and warning strings with no Finding behind them, such as failed gates (fail_gate), scanner and execution errors, and a missing or failed scanner. Strings that only mirror a finding are not counted, so nothing is counted twice. It uses the existing additional_errors and additional_warnings helpers. The Workflow scope: note a tier workflow records when configuration skips a stage (for example LLM checks under --no-llm) is not counted as an independent warning; the raw total_warnings still counts it. It also returns informational: informational messages, not counting the [OK] line that add_success records for each passed check (those checks are in success_details).
    • total_issue_count and describe_issue_counts give the HTML and Markdown reports one count and one wording.
    • groups_by_display_priority orders groups most severe first for capped human-readable lists. Machine output stays ordered by finding_id.
    • refresh_finding_identities recomputes a JSON report's IDs and groups from its current finding text (see CI redaction below).
  • JSON report.
    • New top-level finding_counts, finding_groups and message_counts.
    • New per-result finding_counts.
    • Each finding includes finding_id and occurrence_id.
    • Each finding_groups[].occurrences[] entry has occurrence_id, validator, file_path and line_number. The source line is not copied there; it stays on the finding in results[].findings[] with the same occurrence_id, so a check that fires on many lines does not double the report size.
    • total_errors, total_warnings, severity_counts, skills[].issue_count, legacy and the null metadata convention are unchanged.
  • HTML report. Built on the redesigned verdict-led summary now on main.
    • The embedded report data has the same finding_counts, finding_groups and message_counts as the JSON report. summary.total_issues counts unique findings plus independent errors and warnings, with raw_finding_occurrences, distinct_finding_occurrences and duplicates_removed beside it.
    • Every embedded finding in results has both IDs. In the per-skill view, an entry that merges the same finding on several lines carries finding_id and an occurrence_ids list with every merged location, instead of a single occurrence_id. The merge key includes finding_id, so two different checks with the same text stay separate entries and every ID on an entry belongs to its finding.
    • The tier cards, the Tier 1 Findings and Blocking critical + high numbers, the verdict sentence ("N critical or high findings ...", "N advisory findings do not block"), the skill finding badges and the gate policy line count unique findings at their highest severity. The gate policy adds up each tier's unique findings, as the tier cards show them.
    • When the unique, occurrence and raw-record counts differ, or some errors or warnings have no finding behind them, a line under the Findings number gives the same breakdown as Markdown, for example "1 unique finding / 2 occurrences / 3 raw records / 1 duplicate reconciled", followed by any errors or warnings with no finding ("; 1 error without a finding"). A run that only fails a gate shows Findings 0, "None reported" and "1 error without a finding".
    • The legend under the numbers now says that the same problem reported on several lines, files or skills counts once and that each location is an occurrence. "The other findings are listed under their checks below" compares the Fix first list against distinct occurrences.
  • Markdown report.
    • The summary reads, for example, "Total Issues: 1 unique finding (1 high) / 2 occurrences / 3 raw records", followed by any independent errors and warnings in the same wording as HTML. The severity breakdown counts unique findings at their highest severity.
    • A new "Duplicate Occurrences Reconciled" summary row.
    • A new "Finding Reconciliation" table lists each unique finding's ID, severity, message, occurrence count and validators, most severe first and then by occurrence count, so a critical finding is never hidden behind low ones by the max_findings_shown cap.
    • Finding details show both IDs.
  • CI redaction. The CI runner (ci/secret_redaction.py) and the publisher (ci/publish_reports.py) remove detected credentials from a report after it is written. They now call refresh_finding_identities on every JSON report after redacting, whether or not a credential token was collected, so no published ID is hashed from text that held a removed value (a short password could otherwise be confirmed by hashing guesses). The refresh is unconditional because the redactor also masks database userinfo, such as postgresql+psycopg2://, mongodb+srv:// or rediss:// URLs, that the PII collector does not name. Only fields the report already has are replaced, so retained reports written before this change keep their shape.
  • Docs and changelog. docs/ci-integration.mdx documents the new JSON fields, how the IDs are derived, the cross-skill grouping, the CI recomputation, and which counts are unique or raw. docs/reports.mdx updates the HTML definition of a finding. CHANGELOG entries under Unreleased / Added and Unreleased / Changed.

Why

Each reporter used to compute its own totals:

  • The JSON report emitted raw validator total_errors and total_warnings.
  • The Markdown report labelled the same raw sum "Total Issues".
  • The HTML summary counted len(findings) for its Findings number, tier cards and verdict sentence, while its per-skill view merged repeated findings within one validator.

So one validation run could show different issue counts depending on the format. When two validators flagged the same line, or one check fired on several lines, nothing in any report said whether the records were one problem, several locations of one problem, or duplicates. Findings also had no identifier, so a CI consumer could not track a finding across runs or match it between validators without building its own key.

Example: one check fires on lines 8 and 12, and a second validator reports line 8 again. JSON, Markdown and the HTML summary used to report 3. Now Markdown reports "1 unique finding (1 high) / 2 occurrences / 3 raw records" with 1 duplicate reconciled, the HTML Findings number reads 1 (1 high) with the same breakdown under it, and the JSON report and the HTML report's embedded data contain the same finding_counts and finding_groups.

The JSON report only gains fields; its existing raw fields keep their values. One existing field changes meaning: summary.total_issues in the HTML report's embedded and exported data now counts unique findings plus errors and warnings with no finding, not raw errors plus warnings; the raw finding count is beside it in summary.raw_finding_occurrences and finding_counts.raw_occurrences. The CHANGELOG and docs/ci-integration.mdx say so. What changes for readers is the issue and finding counts in the Markdown summary and the HTML summary. For a run where no finding repeats, the numbers are the same as before, except that the Workflow scope: note recorded for a stage skipped by configuration (for example LLM checks under --no-llm) is no longer counted as an issue.

Not changed in this PR: the JSON skills[].issue_count and the HTML contributor totals still count raw records, as do total_errors, total_warnings and severity_counts. The CI index and PR comment read those raw fields and are unchanged.

Kept from public

  • Redesigned HTML summary. The reconciled counts feed main's verdict-led layout (tier cards, KPIs, Fix first, gate policy) instead of the older header and dashboard elements.
  • Hardened Markdown cells. The reconciliation table's severity, message and validator cells go through _markdown_untrusted_table_cell. Finding text in a PR comment cannot inject HTML, links or @-mentions, or break the table. A test pins this.
  • Gate failures and execution errors. Independent failures with no finding (fail_gate, scanner and execution errors, incomplete scans) are counted through additional_errors and additional_warnings, so a run that fails a gate or leaves a scan incomplete without any finding never reads as zero issues.
  • Credential masking. Source-level PII redaction and the CI redaction of written reports are unchanged; the IDs are recomputed after CI redaction so they cannot undo it.
  • JSON serialization guarantees. allow_nan=False, default=str, the existing top-level fields and the legacy metadata: null for findings without metadata are all unchanged. Findings are serialized through Finding.to_dict(), once per finding.
  • Robustness. The ID helpers accept non-string values without raising. Occurrence de-duplication uses a set, so a check that fires on thousands of lines does not do a linear scan per occurrence. Occurrence sorting tolerates malformed line numbers. One known ID is pinned by a test.
  • Left out on purpose. SARIF output does not get partialFingerprints in this PR. That would change how code-scanning services de-duplicate alerts, so it should be its own decision. The CLI reporter is also unchanged.

Tests

New tests in tests/reporting/test_reporters.py. All fail on current main except test_findings_kpi_has_no_detail_line_when_every_record_is_unique, which guards that the new breakdown line stays hidden when nothing repeats.

  • test_finding_identity_is_semantic_and_occurrence_identity_is_location_bound: case, whitespace, severity and line changes keep finding_id and change occurrence_id. Both IDs appear in to_dict(), and one known finding_id value is pinned.
  • test_occurrence_identity_distinguishes_line_zero_from_no_line.
  • test_occurrence_identity_uses_forward_slashes: scripts\\run.py and scripts/run.py get the same occurrence_id.
  • test_occurrences_with_and_without_a_line_number_sort_without_error: one finding with no line and at line 3 gives 1 unique finding with 2 occurrences, and the JSON, Markdown and HTML reporters render it.
  • test_secret_finding_id_ignores_the_location_written_into_its_message: a Gitleaks hit at scripts/run.py:10 and :11, as reported directly, after merge_with_prefix ([alpha] scripts/run.py) and after plugin member attribution (skills/alpha/scripts/run.py), keeps one finding_id and gets six occurrence IDs; the message still names the location. A hit in scripts/other.py has another finding_id, because the suggestion names the file.
  • test_repeated_pii_finding_id_survives_line_moves: a repeated personal path keeps its finding_id when a blank line moves it, and matches the ID of a single occurrence.
  • test_reconciled_finding_keeps_its_highest_severity_in_every_format: one finding reported as medium by one validator and high by another is high in JSON finding_groups (merged path) and in the HTML embedded data (single-pass path), and Markdown reads "1 unique finding (1 high)"; one validator reporting it as medium then high gives Blocking critical + high 1.
  • test_finding_reconciliation_contract_matches_json_markdown_and_html: three records give one finding, two occurrences and one duplicate; JSON and HTML embedded finding_counts, finding_groups and message_counts are identical; per-result counts and raw totals are kept; Finding.to_dict() runs once per finding; the Markdown summary, reconciliation row and IDs match; the HTML Findings number, its breakdown line, the severity line, the Blocking number, the verdict sentence, the legend, the Fix first note and the skill badge all count one unique finding; a per-skill HTML entry that merges two lines lists both occurrence IDs.
  • test_tier1_dashboard_reconciles_only_tier1_findings: with a Tier 2 finding in the run, the embedded summary counts both tiers, the Tier 1 card and Findings number count only Tier 1, the Tier 2 card keeps its own count, and the gate policy adds up each tier's unique findings.
  • test_tier1_dashboard_counts_only_tier1_errors_without_findings: a Tier 2 error with no finding appears in the embedded summary, not in the Tier 1 tab.
  • test_issue_counts_include_errors_and_warnings_without_findings: a failed gate, an incomplete scan with an error, and an incomplete scan with a warning each report one issue in JSON message_counts, the embedded HTML summary, the HTML Findings breakdown (under the Changes required or Incomplete verdict) and the Markdown summary.
  • test_issue_counts_put_errors_without_findings_after_unique_findings: findings and a failed gate in one run show both.
  • test_findings_kpi_has_no_detail_line_when_every_record_is_unique.
  • test_workflow_scope_note_is_not_an_issue_without_a_finding: a passing result with the --no-llm scope note shows Findings 0 with no detail line, message_counts.independent_warnings 0, raw total_warnings 1, and Markdown Total Issues with no warning.
  • test_folded_pii_finding_counts_each_listed_location_as_an_occurrence: a personal path on two lines gives one group with 2 occurrences (one of them the finding's own occurrence_id) in JSON, HTML and the Markdown table, 0 duplicates, and a detail line under the HTML Findings number; refreshing the IDs of the unredacted report changes nothing.
  • test_folded_pii_finding_in_a_folder_run_counts_each_location_once: an email repeated on two lines of one skill in a two-skill folder gives one group with 2 occurrences, both under [support] SKILL.md, and the Markdown row reads 2; merge_with_prefix does not change the original finding's metadata.
  • test_finding_group_occurrences_do_not_copy_the_source_line: group occurrences carry only occurrence_id, validator, file_path and line_number, the finding with the same occurrence_id keeps the source line, and the JSON report holds the source line once per finding.
  • test_html_skill_entries_merge_only_occurrences_of_one_finding: two checks with the same message and suggestion stay two per-skill entries, each listing only its own occurrence IDs, and the count matches the skill badge.
  • test_same_finding_in_several_skills_counts_once_with_one_occurrence_per_skill: three skills merged with merge_with_prefix give 1 unique finding and 3 occurrences in JSON, Markdown and HTML; each skill badge shows 1 finding; JSON skills[] keeps raw counts.
  • test_markdown_reconciliation_table_lists_the_most_severe_findings_first: a critical finding that falls past the 10-row cap in finding_id order is listed first; JSON finding_groups stay in ID order.
  • test_message_counts_leave_out_passed_check_lines.
  • test_markdown_finding_reconciliation_escapes_untrusted_text: pipes, HTML, link syntax and @-mentions in a finding message or validator name stay inert, and the row keeps five cells.

tests/reporting/test_report_redesign.py: the legend pin now checks the new definition of a finding.

tests/reporting/test_mixed_execution_errors.py:

  • The Tier 2 CLI test now expects the duplicate-content message three times in Markdown (reconciliation table, findings table, details) instead of two. It also pins message_counts and the Markdown "Total Issues" row for the mixed, errors-only and finding-only runs, so an errors-only run reports its analysis error, and the skipped catalog comparison's workflow scope note stays a raw warning without counting as a warning without a finding.
  • test_additional_warnings_excludes_only_existing_finding_messages_without_mutation: warning strings that mirror a finding are left out, including after merge_with_prefix.

tests/validators/test_pii_grouping.py: test_folder_run_counts_folded_locations_once checks that after merge_with_prefix every listed occurrence of a folded email is under the finding's prefixed file_path, and that the folder result has the same number of distinct occurrences as the single-skill result.

tests/ci/test_secret_redaction.py:

  • test_redacted_report_does_not_keep_ids_hashed_from_the_credential: another scanner's finding quotes a detected credential; after the runner's redaction, neither of its original IDs appears in the JSON, and every ID and group matches the redacted text.
  • test_refreshing_ids_keeps_the_shape_of_reports_written_before_ids.
  • test_ids_are_refreshed_when_only_database_userinfo_is_masked: a skill whose only credential is a postgresql+psycopg2:// URL gives no collected token; another scanner's finding quoting it is masked and gets IDs from the masked line in the runner's JSON, and a retained report that still quotes the URL with its old IDs is masked and refreshed by the publisher.
  • test_runner_and_retained_publisher_never_export_detected_value also checks that the runner's JSON and the publisher's retained JSON carry IDs that match their redacted text.

The new CI checks fail when the refresh calls are removed; the database userinfo check fails when either refresh is limited to runs with collected tokens.

Validation (branch head merged with current main):

  • pytest -n 8 tests/reporting tests/models tests/validators/test_pii_grouping.py: 1265 passed.
  • pytest -n 8 tests/validators tests/golden tests/ci: 3864 passed, 4 skipped.
  • Against main's src: 21 of the 22 new test_reporters.py tests fail (23 of 24 cases with parameters), as do the new test_pii_grouping.py test and the changed test_mixed_execution_errors.py and test_report_redesign.py pins; tests/ci/test_secret_redaction.py cannot import the new module. Mutations that drop the / normalization, the line-number sort guard, or either severity escalation each fail a new test.
  • ruff check .: clean. ruff format --check on the changed Python files: already formatted.
  • scripts/check_oss_boundary.py: passed.

🤖 Generated with Claude Code

Each reporter derived its own totals. The JSON report emitted raw
validator error and warning counts, the Markdown report labelled the
same raw sum "Total Issues", and the HTML summary counted every finding
record for its Findings number, tier cards and verdict sentence. One
run could therefore show different counts per format, and nothing said
whether records from two validators, or one check firing on several
lines, were one problem or many. Findings also had no ID a CI consumer
could track across runs.

Give every Finding a stable finding_id (SEF-, a SHA-256 of normalized
category, check name, message and suggestion, independent of location
and severity) and an occurrence_id (SEO-, which adds file path, line
number and line content). Identical findings in different files or
skills share one finding_id. A new reporting.finding_summary module
groups raw findings by finding_id across validators, keeps every
distinct occurrence, and returns one set of counts: raw occurrences,
distinct occurrences, unique findings, duplicates removed and
occurrences grouped, with raw and unique severity breakdowns. Errors
and warnings with no finding behind them (failed gates, scanner and
execution errors) are counted separately through additional_errors and
additional_warnings, so such a run never reads as zero issues.

The JSON report adds top-level finding_counts, finding_groups and
message_counts, per-result finding_counts, and both IDs on each
finding. The HTML report embeds the same objects. Its redesigned
summary (tier cards, Findings and Blocking critical + high numbers,
verdict sentence, skill badges and gate policy line) counts unique
findings at their highest severity, and shows the occurrence,
raw-record and no-finding breakdown under the Findings number when it
differs. The Markdown summary uses the same wording, adds a Finding
Reconciliation table ordered most severe first so the row cap never
hides a critical finding, and lists both IDs in finding details. The
informational message count leaves out the [OK] lines recorded for
passed checks. Existing total_errors, total_warnings, severity_counts
and skills[].issue_count are unchanged.

CI removes detected credentials from a report after it is written. The
runner and the publisher now recompute finding IDs and groups from the
redacted text, so no published ID is hashed from a removed value.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>

@rng1995 rng1995 left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated review: 8 findings (0 P1, 2 P2, 6 P3); 8 posted inline.

Comment thread ci/secret_redaction.py Resolved
Comment thread docs/ci-integration.mdx Resolved
Comment thread CHANGELOG.md Resolved
Comment thread src/skillevaluator/models/result.py Resolved
Comment thread src/skillevaluator/reporting/html.py Resolved
Comment thread src/skillevaluator/reporting/html.py Resolved
rng1995 and others added 8 commits November 2, 2026 10:46
No conflicted files.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The redactor also masks database userinfo (for example
postgresql+psycopg2://, mongodb+srv:// and rediss:// URLs) that the PII
collector does not name, so a run with an empty token set could keep IDs
hashed from the unmasked line. The runner and the publisher now refresh
every JSON report's IDs after redaction.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Secret detection writes "in <file>:<line>" into its message and the PII
scan appends "- N occurrences (...)" when it folds repeats of one value,
so their finding_id changed whenever a line moved. The identity now leaves
out the finding's own location and the PII occurrence list; the visible
message is unchanged. Docs and the CHANGELOG say which text stays in the ID.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The PII scan folds repeats of one value into a single finding and lists
every file and line in metadata.occurrences, but reconciliation counted
one occurrence for it. Each listed location now becomes an occurrence
with its own occurrence_id; duplicates_removed counts locations that
repeat one already counted, and the HTML Findings detail line appears
when occurrences differ from unique findings.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
… a finding

Tier workflows record a stage skipped by configuration, such as LLM
checks under --no-llm, as a "Workflow scope:" warning. It notes scope,
not a problem, but it made every --no-llm run show "1 warning without a
finding" under the HTML Findings number and in Markdown Total Issues.
independent_warnings now leaves it out; raw total_warnings still counts it.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The per-skill view merged entries by message, file and suggestion, so two
different checks with the same text became one entry that kept the first
finding_id but listed the second check's occurrence ID. The merge key now
includes finding_id, so every ID on an entry belongs to that finding and
the entry count matches the skill badge.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
…lation

Add tests that a backslash path gets the same occurrence_id as its "/"
form, that one finding reported with no line and at line 3 sorts into one
group with two occurrences, and that a finding reported as medium and as
high keeps "high" in JSON finding_groups, the HTML embedded data,
Markdown Total Issues and the Blocking critical + high number.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The HTML report's embedded and exported data now counts
summary.total_issues as unique findings plus errors and warnings with no
finding, not raw errors plus warnings. Say so in the CHANGELOG and the CI
integration guide, and name the fields that keep the raw count.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>

@chrisknvidia chrisknvidia left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One thing needs a fix before merge: counting each folded PII location double counts the first one in a folder run, so the reports disagree with their own message. Two minor notes are inline. The ID, CI refresh, workflow note and HTML merge changes otherwise read correctly.

Comment thread src/skillevaluator/reporting/html.py Resolved
rng1995 and others added 9 commits November 3, 2026 04:26
No conflicts.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
…g IDs

- merge_with_prefix prefixes each metadata occurrences[].file like
  file_path (on a copy), so a folded PII finding in a folder run no
  longer counts its own location twice.
- finding_id strips the secret detection "in <file>:<line>" also when a
  folder run or plugin scan changed file_path but not the message.
- finding_groups occurrences no longer copy line_content; the source
  line stays on the finding with the same occurrence_id.
- The secret identity test follows main's suggestion, which names the
  file, so a secret in another file is another finding.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The gate policy totals read advisory_by_tier, so the list was only
appended to.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ccurrence payload

- merge_with_prefix prefixes metadata occurrences[].file like file_path, so a folder run no longer counts a folded location twice.
- Occurrence entries drop line_content (already in results[].findings[]), keeping reports under the CI size cap.
- Remove the unused advisory_results list in the HTML payload builder.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
…ding-ids

Conflicted: src/skillevaluator/models/result.py (kept the local occurrence prefixing).

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
No conflicts.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The runner passed the native HTML report through text redaction only, so
its embedded report data kept finding and occurrence IDs hashed from text
that still held the credential. Render it from the redacted, refreshed
JSON, as the Markdown and SARIF copies already are.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
A plugin scan rewrites a member finding's file_path with "/" separators,
while a Gitleaks message on Windows names the path with backslashes. The
location was then left in the identity text, so the finding_id changed
when the line moved. Compare the two with "/" separators.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
No conflicts.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>

@chrisknvidia chrisknvidia left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Follow-up on the current head. merge_with_prefix now prefixes occurrences[].file, so a folder run counts a folded location once. The occurrence entries no longer carry line_content, and the unused list is gone. I also read the Windows-separator match in the finding identity and the CI change that renders the redacted HTML from the refreshed JSON, and both look right. Nothing further from me.

Resolve CHANGELOG.md conflicts by keeping both main's Unreleased entries
and this PR's stable finding ID and finding-count entries.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
@rng1995
rng1995 merged commit 47620b6 into main Nov 5, 2026
22 checks passed
@rng1995
rng1995 deleted the naren/port-stable-finding-ids branch November 5, 2026 18:07
rng1995 added a commit that referenced this pull request Nov 5, 2026
Resolve the CHANGELOG.md conflict: keep main's report finding-count entry
(#310) and add this PR's baseline-trial drill-down entry after it.

Signed-off-by: Narendran Raghavan <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants