Protobuf/grpc integration with Pants 2.12.0 questi...
# general
b
Protobuf/grpc integration with Pants 2.12.0 question šŸ§µ
āœ… 1
Iā€™ve a need to use
protobuf==3.15.0
But Pants
2.12
defaults to
3.20.1
I instructed Pants to use the specific protoc version as documented here
But it looks like I need to provide the
--protoc-known-versions
as well. Which is a bit tedious.
Is there a better way to accomplish this?
Can Pants not use the same protoc version as the
protobuf
dependency specified in the requirements?
f
Which language (python/scala/java)?
b
Sorry, forgot to mention
python
f
Passing the version from a resolve through to the tool config is non-trivial to do given how the code is currently written. (The config for the
protoc
binary is also used for other languages in Pants.) And the notion of ā€œresolveā€ and tool config are separate in the code. A more tractable solution would be for Pants to contain the digests for most recent versions of
protoc
for the default value of
--protoc-known-versions
which would avoid the user having to fill it in. That was the solution used for
terraform
known versions in a recent PR.
b
Thanks. That makes sense
Also, the recent versioning change will make it difficult to tie the protoc version with language specific protobuf lib version