Skip to content

Conversation

@osa1
Copy link
Member

@osa1 osa1 commented Nov 11, 2025

  • Add generated Dart for the well-known protos to the package.

  • Special case google/protobuf/... imports in the plugin to generate imports
    to the libraries in the protobuf package.

    Note: protoc already special cases these imports, you don't have to specify
    paths to them with -I....

    With this change you also don't have to manually compile them to Dart
    classes.

Fixes #1073.
Fixes #817.
Fixes #780.
Fixes #483.


Changes to test files to use internal wkt protos: cl/831301744 (merged)
Output configuration change tested in: cl/831310910

@github-actions
Copy link

github-actions bot commented Nov 11, 2025

Package publishing

Package Version Status Publish tag (post-merge)
package:protobuf 5.2.0 ready to publish protobuf-v5.2.0
package:protoc_plugin 25.0.0 ready to publish protoc_plugin-v25.0.0

Documentation at https://github.com/dart-lang/ecosystem/wiki/Publishing-automation.

@osa1
Copy link
Member Author

osa1 commented Nov 13, 2025

So with this change any breaking change in protoc_plugin becomes a breaking change in protobuf too, because protobuf now exports generated code. This wasn't the case before, we could update protoc_plugin without updating protobuf.

Not sure if this is a big deal in practice, but for example when we merge all of the generated files into one in the future it'll require a major version bump in protobuf with this change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant