Address jhump/protoreflect deprecations introduced by v1.17.0
#4,035 opened on 2024年11月4日
説明
As we bumped our github.com/jhump/protoreflect/desc dependency to v0.17.0 we decided to postpone addressing the deprecations this specific version introduced.
Specifically:
github.com/jhump/protoreflect/descis now considered deprecated.
This package is now deprecated. Though use of this package is still needed in order to use a handful of other packages in this repo, many usages should instead prefer the "google.golang.org/protobuf/reflect/protoreflect" package in the Protobuf runtime. In a v2 of this repo, this package will no longer be present.
github.com/jhump/protoreflect/desc/protoparseis now considered deprecated.
This package is now deprecated. Most usages should instead prefer the "github.com/bufbuild/protocompile" package. There are some behavioral differences that we hope to address with additional API and enhancements to protocompile. But the protoparse package here is just a veneer on top of protocompile and we plan to do as little maintenance as possible here. In a v2 of this repo, this package will no longer be present.
As a result we have a couple of //nolint:staticcheck comments ignoring those deprecations explicitly. Those can be found in the following files:
- lib/netext/grpcext/reflect.go
- lib/netext/grpcext/conn_test.go
- js/modules/k6/grpc/client.go
- js/modules/k6/grpc/client.go
Definition of done
We have replaced the deprecated packages import with their more modern counterparts, and the nolint statements have been removed.