Skip to content

fix(cli): apply governance suppressions before SARIF export#105

Merged
PythonWoods-Dev merged 3 commits into
mainfrom
release/v0.13.1-prep
Jun 19, 2026
Merged

fix(cli): apply governance suppressions before SARIF export#105
PythonWoods-Dev merged 3 commits into
mainfrom
release/v0.13.1-prep

Conversation

@PythonWoods-Dev

Copy link
Copy Markdown
Contributor

Summary

This PR fixes a critical bug in the SARIF formatter where the output bypassed the per_file_ignores and directory_policies filtering.

Previously, when running zenzic check all --format sarif, the raw findings were directly converted to SARIF without calling _apply_per_file_ignores() and _apply_directory_policies(). This exposed all internal suppressed issues to GitHub Advanced Security, effectively breaking the CI pipeline despite the issues being properly managed and suppressed in .zenzic.toml.

Changes

  • Applied sovereign governance context (_apply_per_file_ignores and _apply_directory_policies) to the findings array before calling _output_sarif_findings in src/zenzic/cli/_check.py.
  • Bumped project version to v0.13.1 across all manifests and documentation, including CITATION.cff.

Impact

  • Managed Debt Correctness: The SARIF output now aligns with text and github-annotations formats, respecting the repository's configured technical debt.
  • Zero-Debt Compliance: Allows CI pipelines using upload-sarif: 'true' to run without failing on explicitly suppressed files (e.g. legacy blog posts with i18n parity exemptions).

Signed-off-by: PythonWoods <gianluca.catalano@gmail.com>
Signed-off-by: PythonWoods <gianluca.catalano@gmail.com>
Signed-off-by: PythonWoods <gianluca.catalano@gmail.com>
@PythonWoods-Dev PythonWoods-Dev merged commit f8537b1 into main Jun 19, 2026
5 checks passed
@PythonWoods-Dev PythonWoods-Dev deleted the release/v0.13.1-prep branch June 19, 2026 18:59
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.

1 participant