Skip to content

deps: upgrade protobuf to >=6.33 and grpcio to >=1.76#8884

Draft
cdecker wants to merge 2 commits intomasterfrom
upgrade-protobuf-grpcio
Draft

deps: upgrade protobuf to >=6.33 and grpcio to >=1.76#8884
cdecker wants to merge 2 commits intomasterfrom
upgrade-protobuf-grpcio

Conversation

@cdecker
Copy link
Member

@cdecker cdecker commented Feb 5, 2026

Summary

Upgrade protobuf and grpcio dependencies to use floating version ranges, improving flexibility for downstream users.

Changes

Dependency updates:

  • protobuf: ==6.32.1>=6.33,<7
  • grpcio: ==1.75.1>=1.76
  • grpcio-tools: ==1.75.1>=1.76

Files modified:

  • pyproject.toml
  • contrib/pyln-grpc-proto/pyproject.toml
  • contrib/pyln-testing/pyproject.toml
  • uv.lock

Removed:

  • contrib/pyln-grpc-proto/uv.lock - stale lock file that referenced old protobuf3 package

CI changes:

  • Removed manual protoc installation from .github/scripts/setup.sh
  • Now relies on grpcio-tools bundled protoc, ensuring version consistency between the compiler and runtime

Rationale

Using floating version ranges allows downstream users of pyln-grpc-proto to avoid dependency conflicts when other libraries depend on specific protobuf versions. The generated protobuf code (for 6.31.1) is compatible with protobuf 6.33.x runtime.

@cdecker cdecker marked this pull request as draft February 5, 2026 16:11
Update protobuf and grpcio dependencies to use floating version ranges,
improving flexibility for downstream users.

Dependency updates:
- protobuf: ==6.32.1 -> >=6.33,<7
- grpcio: ==1.75.1 -> >=1.76
- grpcio-tools: ==1.75.1 -> >=1.76

Changes:
- Update pyproject.toml, contrib/pyln-grpc-proto/pyproject.toml,
  and contrib/pyln-testing/pyproject.toml
- Remove stale contrib/pyln-grpc-proto/uv.lock (referenced old protobuf3)
- Regenerate protobuf files with grpcio-tools 1.76
- Remove manual protoc installation from CI setup.sh, now relies on
  grpcio-tools bundled protoc for version consistency

Changelog-Changed: Upgraded protobuf to >=6.33 and grpcio to >=1.76 for better downstream compatibility
@cdecker cdecker force-pushed the upgrade-protobuf-grpcio branch from a23b2f2 to 3bee784 Compare February 5, 2026 16:18
Add a contrib/protoc wrapper script that invokes the protoc compiler
bundled with grpcio-tools via 'uv run python3 -m grpc_tools.protoc'.

This ensures the protoc version always matches the Python protobuf
package version, avoiding runtime errors from version mismatches
between generated code and the protobuf runtime library.

The setup.sh script now installs this wrapper to /usr/local/bin/protoc
so it's available system-wide during CI builds.
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.

1 participant