You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to use the migration tool provided under protovalidate to migrate from protoc-gen-validate but I am running into errors trying to download the git repository.
I am running go get github.com/bufbuild/[email protected] and getting this error in return:
go: github.com/bufbuild/[email protected] requires github.com/bufbuild/[email protected]: parsing go.mod:
module declares its path as: github.com/envoyproxy/protoc-gen-validate
but was required as: github.com/bufbuild/protovalidate
Currently, we import protoc-gen-validate through bazel. Any ideas why I might be running into this and how to bypass this issue?
The text was updated successfully, but these errors were encountered:
Hey, @rsylim804! There's no go module at the root of this project, so you'll need to go get github.com/bufbuild/protovalidate/tools@latest to get the module that contains the migrator.
(The error you're seeing is a red-herring related to caching in the go module proxy when we initially had this project live in the protoc-gen-validate repo itself.)
@rodaine Thanks for the reply! I'm running into a separate problem now trying to import protovalidate through bazel and getting it to build successfully.
Inside our BUILD file currently I have: # gazelle:resolve proto proto buf/validate/validate.proto @protovalidate//proto/protovalidate/buf/validate:validate_proto
and # gazelle:resolve proto go buf/validate/validate.proto @build_buf_gen_go_bufbuild_protovalidate_protocolbuffers_go//buf/validate:validate
However, I hit a cyclic dependency error trying to resolve the generated Go package for validate.proto with @org_golang_google_protobuf//cmd/protoc-gen-go:protoc-gen-go leading back to itself.
Is there a recommended way to get the migration to protovalidate working with Bazel?
I am trying to use the migration tool provided under protovalidate to migrate from protoc-gen-validate but I am running into errors trying to download the git repository.
I am running
go get github.com/bufbuild/[email protected]
and getting this error in return:Currently, we import protoc-gen-validate through bazel. Any ideas why I might be running into this and how to bypass this issue?
The text was updated successfully, but these errors were encountered: