-
Notifications
You must be signed in to change notification settings - Fork 72
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
protos, python: use betterproto #315
Conversation
Signed-off-by: William Woodruff <[email protected]>
(I haven't removed any of the old |
Thanks for getting this started! A couple thoughts.
I'm not too concerned about this at the moment. Beyond in-toto's own (in-flight) transition to this library in our Python CLI, I don't know of other projects that currently depend on the current version of the Python library.
This is probably going to be the more cumbersome part. But if it's going to make writing future tests and using the library easier in the future, I think we can definitely motivate the re-implementation. |
Sounds good! The only other use I know of is sigstore-python's (also in-flight) use, which is currently ongoing here: #315
Makes sense -- I think this will absolutely make future testing and use easier, so I'll start the cumbersome bits now. |
Thank you! |
Just to post a brief update: I've run into some snarls with betterproto's JSON ser/de. This unfortunately looks like a bug in |
Signed-off-by: William Woodruff <[email protected]>
Blocked on: danielgtaylor/python-betterproto#551 |
@woodruffw Pinging this PR. Is this still something you expect to get back to? Otherwise, we'll close this until we're ready to pick this back up. |
I'll get back to it eventually, but I probably won't have enough time in the next month or so. If that timeline is too far out, please close this! |
No worries @woodruffw. We'll close this PR for now, but make sure the issue stays open! |
WIP for now.
This replaces
protobuf
withbetterproto
, which:betterproto
doesn't support Pydantic V2 yet;protobuf-specs
does, making the two more compatible.The main downsides, in turn:
protobuf
tobetterproto
. That means it'll be backwards-incompatible with previous versions;protobuf-specs
;Closes #291.