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 just bumped into this error, using pact-go together with the Go pulumi sdk, both registering plugin.proto:
panic: proto: file "plugin.proto" is already registered
previously from: "github.com/pact-foundation/pact-go/v2/internal/native"
currently from: "github.com/pulumi/pulumi/sdk/v3/proto/go"
See https://developers.google.com/protocol-buffers/docs/reference/go/faq#namespace-conflict
Although both files have different go_package directives, as you can see here:
I’m from Pulumi and will submit a PR to change our filenames, but I strongly suggest to that you also rename your file to e.g. pact-plugin.proto or pact/plugin.proto to prevent future filename collisions. Since protobuf-go v1.26, such a filename collision generates a panic.
The text was updated successfully, but these errors were encountered:
mefellows
added a commit
to pact-foundation/pact-go
that referenced
this issue
Jun 28, 2022
I just bumped into this error, using
pact-go
together with the Gopulumi
sdk, both registeringplugin.proto
:Although both files have different
go_package
directives, as you can see here:this doesn't seem to be enough. The filenames need to be unique as well, according this comment:
golang/protobuf#1122 (comment)
I’m from Pulumi and will submit a PR to change our filenames, but I strongly suggest to that you also rename your file to e.g.
pact-plugin.proto
orpact/plugin.proto
to prevent future filename collisions. Since protobuf-go v1.26, such a filename collision generates apanic
.The text was updated successfully, but these errors were encountered: