Skip to content

Store bottle SBOM data in manifests#22981

Merged
MikeMcQuaid merged 1 commit into
mainfrom
sbom-bottle-manifest-supplements
Jul 6, 2026
Merged

Store bottle SBOM data in manifests#22981
MikeMcQuaid merged 1 commit into
mainfrom
sbom-bottle-manifest-supplements

Conversation

@MikeMcQuaid

Copy link
Copy Markdown
Member
  • Keep bottled SBOMs reproducible by moving pour-specific runtime, compiler and bottle package data into package manifests.
  • Preserve per-platform supplements for :all bottles so installs merge only the current platform data.
  • Avoid validating full SBOMs during pour by appending manifest supplement arrays.

  • Have you followed our Contributing guidelines?
  • Have you checked for other open Pull Requests for the same change?
  • Have you explained what your changes do? Performance claims (e.g. "this is faster") must include Hyperfine benchmarks.
  • Have you explained why you'd like these changes included, not just what they do?
  • For bug fixes, have you given step-by-step brew commands to reproduce the bug?
  • Have you written new tests (excluding integration tests)? Here's an example.
  • Have you successfully run brew lgtm (style, typechecking and tests) locally?

  • AI was used to generate or assist with generating this PR.

OpenAI Codex 5.5 xhigh with local review and testing.


Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR restructures how bottle SBOM data is persisted by moving pour-specific details (runtime deps, compiler/stdlib, and bottle package metadata) into GitHub Packages manifest annotations, then merging that data into the installed SBOM at pour time to keep bottled SBOMs reproducible.

Changes:

  • Add SBOM “supplement” generation for pour-time-only package/relationship data and support generating “bottling” SBOMs that omit host-specific packages.
  • Emit/consume SBOM supplements via GitHub Packages manifest annotations (including per-platform tag handling for :all bottles).
  • Merge SBOM supplements during bottle pours without requiring full SBOM validation.

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
Library/Homebrew/sbom.rb Adds SBOM supplement support, bottle-manifest annotation generation, and bottling/pour merge behavior.
Library/Homebrew/resource.rb Parses SBOM supplement data from bottle manifest annotations (including :all tag selection).
Library/Homebrew/github_packages.rb Uploads SBOM supplement annotations alongside bottle manifest metadata.
Library/Homebrew/formula_installer.rb Merges manifest-provided SBOM supplements into the installed SBOM during bottle pours.
Library/Homebrew/dev-cmd/bottle.rb Writes bottling SBOMs and includes SBOM supplements in generated bottle JSON / :all merge output.
Library/Homebrew/test/sbom_spec.rb Adds coverage for bottling omissions, supplement generation, manifest annotation building, and pour-time merging.
Library/Homebrew/test/resource_spec.rb Adds coverage for selecting the current-platform SBOM supplement from :all bottle manifests.
Library/Homebrew/test/github_packages_spec.rb Verifies SBOM supplement annotations are included (and bottle package metadata is injected) in uploaded manifests.
Library/Homebrew/test/dev-cmd/bottle_spec.rb Extends merge test coverage to include SBOM supplement tag aggregation in :all bottle JSON.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread Library/Homebrew/formula_installer.rb Outdated
Comment thread Library/Homebrew/test/dev-cmd/bottle_spec.rb Outdated
@MikeMcQuaid MikeMcQuaid force-pushed the sbom-bottle-manifest-supplements branch from b8c4450 to e5516fb Compare July 6, 2026 12:55
- Keep bottled SBOMs reproducible by moving pour-specific runtime,
  compiler and bottle package data into package manifests.
- Preserve per-platform supplements for `:all` bottles so installs merge
  only the current platform data.
- Avoid validating full SBOMs during pour by appending manifest
  supplement arrays.
@MikeMcQuaid MikeMcQuaid force-pushed the sbom-bottle-manifest-supplements branch from e5516fb to ed17247 Compare July 6, 2026 14:01
@MikeMcQuaid MikeMcQuaid requested a review from Copilot July 6, 2026 14:02

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 11 out of 11 changed files in this pull request and generated no new comments.

@MikeMcQuaid MikeMcQuaid marked this pull request as ready for review July 6, 2026 14:09
@MikeMcQuaid MikeMcQuaid enabled auto-merge July 6, 2026 14:10
@MikeMcQuaid MikeMcQuaid added this pull request to the merge queue Jul 6, 2026
Merged via the queue into main with commit 08aaf39 Jul 6, 2026
42 checks passed
@MikeMcQuaid MikeMcQuaid deleted the sbom-bottle-manifest-supplements branch July 6, 2026 14:37
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.

4 participants