Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add VerificationMaterials.to_bundle() #719

Merged

Conversation

sethmlarson
Copy link
Contributor

Summary

Part of #718, adds the API to convert VerificationMaterials that have a Rekor entry loaded into a Bundle.

Release Note

Will add a release note.

Documentation

I don't think this needs a docs update?

sigstore/verify/models.py Outdated Show resolved Hide resolved
sigstore/verify/models.py Show resolved Hide resolved
test/unit/verify/test_models.py Show resolved Hide resolved
@woodruffw
Copy link
Member

Documentation

I don't think this needs a docs update?

Nope, I don't think so -- it'll be auto-generated.

Signed-off-by: Seth Michael Larson <seth@python.org>
@sethmlarson sethmlarson force-pushed the verification-materials-to-bundle branch from 0ea3e49 to feaf92b Compare July 27, 2023 17:56
@sethmlarson
Copy link
Contributor Author

@woodruffw Implemented your comments. I force pushed because I needed to add a --signoff.

@woodruffw
Copy link
Member

@woodruffw Implemented your comments. I force pushed because I needed to add a --signoff.

Thanks, LGTM! I think this just needs a CHANGELOG entry and then we're good to go.

@woodruffw
Copy link
Member

/gcbrun

@woodruffw
Copy link
Member

Lintage:

sigstore/verify/models.py:479: error: Item "None" of "Optional[LogEntry]" has no attribute "log_index"  [union-attr]
sigstore/verify/models.py:480: error: Item "None" of "Optional[LogEntry]" has no attribute "log_id"  [union-attr]
sigstore/verify/models.py:482: error: Item "None" of "Optional[LogEntry]" has no attribute "integrated_time"  [union-attr]
sigstore/verify/models.py:485: error: Item "None" of "Optional[LogEntry]" has no attribute "inclusion_promise"  [union-attr]
sigstore/verify/models.py:485: error: Argument 1 to "b64decode" has incompatible type "Union[B64Str, None, Any]"; expected "Union[str, Buffer]"  [arg-type]
sigstore/verify/models.py:489: error: Item "None" of "Optional[LogEntry]" has no attribute "inclusion_proof"  [union-attr]
sigstore/verify/models.py:489: error: Item "None" of "Union[LogInclusionProof, None, Any]" has no attribute "log_index"  [union-attr]
sigstore/verify/models.py:491: error: Item "None" of "Optional[LogEntry]" has no attribute "inclusion_proof"  [union-attr]
sigstore/verify/models.py:491: error: Item "None" of "Union[LogInclusionProof, None, Any]" has no attribute "root_hash"  [union-attr]
sigstore/verify/models.py:493: error: Item "None" of "Optional[LogEntry]" has no attribute "inclusion_proof"  [union-attr]
sigstore/verify/models.py:493: error: Item "None" of "Union[LogInclusionProof, None, Any]" has no attribute "tree_size"  [union-attr]
sigstore/verify/models.py:496: error: Item "None" of "Optional[LogEntry]" has no attribute "inclusion_proof"  [union-attr]
sigstore/verify/models.py:496: error: Item "None" of "Union[LogInclusionProof, None, Any]" has no attribute "hashes"  [union-attr]
sigstore/verify/models.py:499: error: Item "None" of "Optional[LogEntry]" has no attribute "inclusion_proof"  [union-attr]
sigstore/verify/models.py:499: error: Item "None" of "Union[LogInclusionProof, None, Any]" has no attribute "checkpoint"  [union-attr]
sigstore/verify/models.py:502: error: Item "None" of "Optional[LogEntry]" has no attribute "body"  [union-attr]
Found 16 errors in 1 file (checked [27](https://github.com/sigstore/sigstore-python/actions/runs/5683866017/job/15406553799?pr=719#step:5:28) source files)

Signed-off-by: Seth Michael Larson <seth@python.org>
@woodruffw
Copy link
Member

/gcbrun

Signed-off-by: Seth Michael Larson <seth@python.org>
@woodruffw
Copy link
Member

/gcbrun

woodruffw
woodruffw previously approved these changes Jul 27, 2023
Copy link
Member

@woodruffw woodruffw left a comment

Choose a reason for hiding this comment

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

LGTM, thanks @sethmlarson!

Were you planning on adding a CHANGELOG entry? If not, I can add one in a bit.

@sethmlarson
Copy link
Contributor Author

@woodruffw If you could add one that'd be appreciated, I couldn't immediately figure out what the right annotation would be :)

@woodruffw
Copy link
Member

If you could add one that'd be appreciated, I couldn't immediately figure out what the right annotation would be :)

It'd probably be "added" for a new public API surface, just for future reference! But I'll push to your branch.

Signed-off-by: William Woodruff <william@trailofbits.com>
@woodruffw
Copy link
Member

/gcbrun

Copy link
Member

@woodruffw woodruffw left a comment

Choose a reason for hiding this comment

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

LGTM, but I'm the last pusher so @di or @tetsuo-cpp will need to merge here.

@woodruffw woodruffw requested a review from di July 27, 2023 19:37
@tetsuo-cpp tetsuo-cpp merged commit 212a31f into sigstore:main Jul 28, 2023
23 checks passed
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.

None yet

3 participants