chore(grpc): re-vendor stale protobuf message stubs#8
Open
lakhansamani wants to merge 1 commit into
Open
Conversation
The _pb2.py message descriptors under _grpc/authorizer/v1 were vendored from a stale gen/python that had frozen at the main repo's PR #635 and missed the security removal of is_multi_factor_auth_enabled from the public SignupRequest (upstream 7138237e), plus every proto change since. Re-vendored from a fresh buf generate --template buf.gen.clients.yaml --include-imports (authorizerdev/authorizer#726), with imports rewritten to the authorizer._grpc.* namespace to match the existing vendoring. - SignupRequest no longer declares is_multi_factor_auth_enabled (field 15 now reserved; field numbers skip 14->16). UpdateProfileRequest keeps it, as intended. - Only the message descriptors (_pb2.py) changed; the service stubs (_pb2_grpc.py) were already current. Verified: ruff clean, mypy clean, 112 unit tests pass, 63 live integration tests pass (graphql+rest+grpc) against a locally built authorizer image from upstream main.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The vendored gRPC message descriptors under
src/authorizer/_grpc/authorizer/v1(*_pb2.py) were byte-frozen against a stalegen/pythonthat had not been regenerated since the upstream main repo's PR #635. As a result they still declaredis_multi_factor_auth_enabledas active field 15 onSignupRequest— the field removed for security upstream in 7138237e — and were missing every proto change since #635.Runtime impact was low (the hand-written
types.pydataclass already omits the field, so no caller could set it), but this is the same silent-drift pattern that has caused API-parity gaps in this SDK before. Fixing it now keeps the vendored wire contract honest.Changes
_grpc/authorizer/v1/*_pb2.pyfrom a freshbuf generate --template buf.gen.clients.yaml --include-imports(main repo PR chore(proto): regenerate stale client-SDK proto stubs + add CI staleness gate authorizer#726), with imports rewritten to theauthorizer._grpc.*namespace to match the existing vendoring convention.*_pb2_grpc.py) and thebuf/,google/trees were already current.SignupRequestno longer hasis_multi_factor_auth_enabled(field numbers skip 14 -> 16);UpdateProfileRequestretains it, as intended.Testing
ruff check src tests— cleanmypy src— clean (no issues in 12 source files)pytest -q -m "not live"— 112 passed, 63 deselectedpytest tests/integration -m live(graphql+rest+grpc) against a locally builtauthorizerimage from upstreammain— 63 passedDepends on / pairs with authorizerdev/authorizer#726 (which fixes the same staleness at the source and adds a CI gate). Not for self-merge — generated + security-relevant, wants a human read.