Repository navigation
fix(core): accept googleapis 0.2 and require Elixir ~> 1.17 - #664
Conversation
grpc_core declares `elixir: "~> 1.15"` but pins `googleapis ~> 0.1.0`, and googleapis 0.1.0 requires Elixir `~> 1.18`. Projects on Elixir 1.15 to 1.17 therefore get "the dependency :googleapis requires Elixir ~> 1.18" and run an unsupported combination. googleapis 0.2.0 drops that requirement back to `~> 1.15` (its PR elixir-grpc#2) and regenerates the stubs with current protobuf (elixir-grpc#4), which grpc_core already requires (`~> 0.17`). Allow both so existing locks keep 0.1.0 and new resolutions can take 0.2.0.
|
Could you also bump the required version to Elixir 1.17 for all 3 grpc libs? |
CI's oldest lane is Elixir 1.17 on OTP 27, so 1.17 is the floor the libraries are tested on. Declare it.
|
Done in 7cf8ccd: grpc, grpc_core and grpc_server now declare |
|
Thanks for merging this and #663. Is a release planned that includes both? Downstream, a library with an optional gRPC transport can then resolve googleapis 0.2 on Elixir 1.17, and hosts that leave out |
I expect to release something in the next coupld days. Lots of fixes merged today with a couple more merging soon. |
grpc_corepins{:googleapis, "~> 0.1.0"}, and googleapis 0.1.0 requires Elixir~> 1.18, above what the grpc libraries declare. On an older supported Elixir, Mix printsthe dependency :googleapis requires Elixir "~> 1.18"and the project runs a combination googleapis doesn't support.googleapis 0.2.0 lowers its requirement to
~> 1.15(elixir-grpc/googleapis#2) and regenerates the stubs with current protobuf (#4), which grpc_core already requires (~> 0.17). This PR:{:googleapis, "~> 0.1.0 or ~> 0.2.0"}in grpc_core, so existing locks keep 0.1.0 and new resolutions can take 0.2.0;~> 1.17in grpc, grpc_core and grpc_server (was~> 1.15), matching CI's oldest lane (Elixir 1.17 / OTP 27), as requested in review.I checked that 0.2.0 is compatible with everything grpc uses from it (
git grep 'Google\.'across grpc_core, grpc and grpc_server):Google.Api.Http,Google.Api.HttpRule,Google.Api.CustomHttpPatternandGoogle.Rpc.Statusare field-for-field identical in v0.1.0 and v0.2.0.Google.Api.PbExtensionkeeps every v0.1.0 extension (including:http,72_295_728, used byGRPC.Service) and adds one,:routing.Google.Protobuf.*modules grpc uses come fromprotobuf, not googleapis.The locks still resolve 0.1.0, so CI keeps testing that. Running
mix deps.update googleapisin grpc_core would let CI exercise 0.2.0 too, if you want this PR to carry the lock change.