Skip to content

feat: Add BundleURL to Attestation - #4647

Open
Frank2006x wants to merge 2 commits into
google:masterfrom
Frank2006x:fix-attestations-bundle-url
Open

Frank2006x wants to merge 2 commits into
google:masterfrom
Frank2006x:fix-attestations-bundle-url

Conversation

@Frank2006x

Copy link
Copy Markdown
Contributor

Summary

Adds BundleURL *string to Attestation and adds omitempty to Bundle. The GitHub REST API for artifact attestations now provides
bundle_url to download the Sigstore bundle instead of returning the bundle inline.

This addresses the Attestations: Remove the bundle property from attestation list responses (users should use bundle_url instead). #4077 (comment).

part of #4077

Tests

go test ./github
script/test.sh
script/lint.sh

Assisted Contribution

Drafted with the assistance of an AI coding agent. All changes and test results were reviewed and verified against repository
guidelines.

@Frank2006x Frank2006x mentioned this pull request Oct 18, 2026
@gmlewis gmlewis added the NeedsReview PR is awaiting a review before merging. label Oct 18, 2026
@codecov

codecov Bot commented Oct 18, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.62%. Comparing base (af24e38) to head (f04d5ac).
⚠️ Report is 5 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff            @@
##           master    #4647    +/-   ##
========================================
  Coverage   98.61%   98.62%            
========================================
  Files         199      201     +2     
  Lines       18689    18811   +122     
========================================
+ Hits        18431    18553   +122     
  Misses        258      258            

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@gmlewis gmlewis 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.

Thank you, @Frank2006x!
LGTM.
Awaiting second LGTM+Approval from any other contributor to this repo before merging.

cc: @stevehipwell - @Not-Dhananjay-Mishra

@Not-Dhananjay-Mishra Not-Dhananjay-Mishra 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.

Just one nit. Otherwise, LGTM 🚀

Comment thread github/attestations.go
// The provided bundle can be used to verify the provenance of artifacts.
//
// https://docs.github.com/en/actions/security-for-github-actions/using-artifact-attestations/using-artifact-attestations-to-establish-provenance-for-builds
type Attestation struct {

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.

initiator field is also missing from the Attestation struct, Can you add that as well?

          "bundle_url": {
            "type": "string"
          },
          "initiator": {
            "type": "string"
          }

@Frank2006x

Copy link
Copy Markdown
Contributor Author

Added the initiator into the Attestation struct as requested

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

NeedsReview PR is awaiting a review before merging.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants