Protobuf in go mod

Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: go mod 里的 protobuf

| username: ShawnYan

What are the differences between the protobufs in go mod?

protobuf module - google.golang.org/protobuf - Go Packages v1.30.0 // indirect
GitHub - gogo/protobuf: [Deprecated] Protocol Buffers for Go with Gadgets v1.3.2
GitHub - golang/protobuf: Go support for Google's protocol buffers v1.5.3

Why are all three referenced at the same time?

| username: redgame | Original post link

protobuf module - google.golang.org/protobuf - Go Packages is the official protobuf implementation maintained by Google.
GitHub - gogo/protobuf: [Deprecated] Protocol Buffers for Go with Gadgets is a third-party protobuf implementation maintained by the community. It offers some additional features and extensions.
GitHub - golang/protobuf: Go support for Google's protocol buffers is also a third-party protobuf implementation maintained by the community.
A classmate told me this.