Skip to content

fix(release): generate SBOM for QuerySpec.Analyzers package#249

Merged
AbongileBoja merged 1 commit intodevelopfrom
fix/analyzer-sbom-generation
Apr 29, 2026
Merged

fix(release): generate SBOM for QuerySpec.Analyzers package#249
AbongileBoja merged 1 commit intodevelopfrom
fix/analyzer-sbom-generation

Conversation

@AbongileBoja
Copy link
Copy Markdown
Owner

Summary

Removes <GenerateSBOM>false</GenerateSBOM> from QuerySpec.Analyzers.csproj. This flag was introduced in commit c9032a8 (PR #153) because Microsoft.Sbom.Targets 3.x could not generate an SBOM for IncludeBuildOutput=false analyzer-shape packs. Microsoft.Sbom.Targets was bumped to 4.1.5 in PR #227; the limitation no longer exists. Removing the override restores the uniform Directory.Build.props-driven SBOM generation for all packable projects.

The v4.1.0 release gate correctly blocked publish because QuerySpec.Analyzers.4.1.0.nupkg was missing _manifest/spdx_2.2/manifest.spdx.json. This is the engineering fix; v4.1.1 will be the published release.

Verification

Local pack with the fix applied:

$ unzip -l /tmp/sbom-verify/QuerySpec.Analyzers.0.0.0-local.nupkg | grep manifest
    31423  _manifest/spdx_2.2/manifest.spdx.json
       64  _manifest/spdx_2.2/manifest.spdx.json.sha256

Diff

One-line deletion from src/QuerySpec.Analyzers/QuerySpec.Analyzers.csproj:

-    <GenerateSBOM>false</GenerateSBOM>

Test plan

Microsoft.Sbom.Targets 4.1.5 handles IncludeBuildOutput=false analyzer-shape
packs correctly. The GenerateSBOM=false override from commit c9032a8 (PR #153)
was set when Sbom.Targets 3.x could not emit the manifest into a no-build-output
pack; that limitation no longer exists. Removing the override lets
Directory.Build.props drive SBOM generation for all packable projects uniformly.

Local verification: dotnet pack produces _manifest/spdx_2.2/manifest.spdx.json
in the archive (31 423 bytes, 22 packages detected).

Fixes #248
@github-actions
Copy link
Copy Markdown

Code Coverage

Package Line Rate Branch Rate Complexity Health
QuerySpec.Analyzers 93% 84% 133
QuerySpec.Analyzers.CodeFixes 90% 70% 50
QuerySpec.Core 93% 84% 959
QuerySpec.DependencyInjection 92% 75% 43
QuerySpec.EFCore 86% 77% 303
Summary 91% (2118 / 2316) 81% (930 / 1143) 1488

@AbongileBoja AbongileBoja merged commit 17a54f2 into develop Apr 29, 2026
12 checks passed
@AbongileBoja AbongileBoja deleted the fix/analyzer-sbom-generation branch April 29, 2026 07:11
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.

QuerySpec.Analyzers nupkg missing SPDX 2.2 SBOM manifest

1 participant