Joe Tsai

Results 341 comments of Joe Tsai

Thank you for being willing to contribute a fix. Before jumping in, I would wait for @neild to make a call for whether this bug meets the bar for a...

This use-case for wanting to disable the version markers is suspect as it's bad practices to have a number of developers working on the same module, but using different versions.

> Given that reframing, it's possible that just hiding sub-versions of protoc might resolve the base problem I'm having. By sub-version, do you mean the "PATCH" version per [semver terminology](https://semver.org/)?...

As with almost all other proposals to generate some helper method, the main concerns are binary bloat and increased API surface for generated code.

In production code, using [`proto.Equal`](https://pkg.go.dev/google.golang.org/protobuf/proto#Equal) is recommended for its speed. In test code, using [`cmp`](https://pkg.go.dev/github.com/google/go-cmp/cmp) is recommended with `cmp.Comparer(proto.Equal)` or [`protocmp.Transform`](https://pkg.go.dev/google.golang.org/protobuf/testing/protocmp#Transform) for its flexibility.

Well known types are weirdly inconsistent with regard to binary marshaling versus text-based marshaling because they were invented after binary marshaling already existed. This is not specific to Go, but...

It seems that this can be addressed in the new API by changing `protoreflect.FileDescriptor.DescriptorByName`: https://github.com/golang/protobuf/blob/b4e370ef3a86cd5a0f62874fe112e24e855be711/reflect/protoreflect/type.go#L181-L183 to also search the name within any files that were publicly imported (by also calling...

I'm fairly certain that the v2 API resolves this since `prototype.findMessageDescriptor` is responsible for resolving the message name, for which it searches the `protoregistry.Files` for *all* declarations that have been...

Wanted update this thread. @neild and I have talked on/off about this in the past. One of things we'd like to explore first before addressing this is to figure out...

Currently, binary bloat is increasingly a concern for generated types, and any method added contributes to that problem. It's unlikely that we generate such a method by default, but an...