Releases: google/protobuf.dart
package:protoc_plugin v25.0.0
Note: this version requires protobuf 6.0.0.
- Handle importing well-known protos. (#1081)
package:protobuf v6.0.0
-
New
GeneratedMessageextension methodstoTextFormatandwriteTextFormatadded to convert the message into the official protocol buffers text format. (#1080, #125) -
Add well-known proto types as libraries. This change is required for protoc_plugin-25.0.0. (#1081)
-
Breaking: Hide
PbListandPbMapconstructors. It is not possible to construct these values correctly in user code, so the constructors are now private. Existing uses ofPbListcan be replaced byListandPbMapcan be replaced byMap.For immutable lists and maps, you can use
built_value. (#1072) -
Map fields now check key and value validity when adding elements. (#1065, #1076)
package:protobuf v5.1.0
-
Update default size limit of
CodedBufferReaderfrom 67,108,864 bytes to 2,147,483,647 bytes, and default recursion limit from 64 to 100.The new limits are consistent with the Java and C++ implementations. (#1060)
-
Fix
GeneratedMessage.addExtensionreturning non-frozen andGeneratedMessage.getExtensionallowing modifying an extension when the message is frozen before initializing the extension field set. (#1062) -
Fix
GeneratedMessage.getExtensionreturning differently typed lists when the message extension field set is initialized and frozen and initialized but not frozen. (#1062) -
Fix
PbListmethodsaddAll,insertAll,replaceRange,setAll,setRangeiterating theIterableargument twice. (#730, #1070) -
Fix
GeneratedMessage.==throwing a type error when comparingmapfields in some cases. (#1075, #1077)This bug was introduced with protobuf-5.0.0.
package:protoc_plugin v24.0.0
-
Breaking: Don't generate
createRepeatedmethods.These methods are not too useful as there isn't much you can do with a
PbListthat you can't do with aList.To migrate, replace
MyMessage.createRepeated()with<MyMessage>[].
package:protoc_plugin v23.0.0
package:protobuf v5.0.0
- Improve performance of
GeneratedMessage.deepCopy. (#742) - Fix unknown enum handling in
GeneratedMessage.mergeFromProto3Jsonwhen theignoreUnknownFieldsoptional argument istrue. (#853) - Add
BuilderInfomethods to support protoc-plugin 23.0.0. (#1047) - Generalize argument type of
PbList.fromfromList<T>toIterable<T>. (#1054) - Fix clearing oneof fields with
GeneratedMessage.clear. (#1057) - Fix unknown JSON handling when using
GeneratedMessagemethodsmergeFromJson,mergeFromJsonMap,writeToJson,writeToJsonMap. (#1058)
package:protoc_plugin v22.5.0
- Generated files are now formatted using the Dart formatter. The code is
formatted using the min. SDK forpackage:protoc_plugin; currently3.7.0. - Minimum SDK dependency bumped from 3.6.0 to 3.7.0. (#1024)
package:protobuf v4.1.1
package:protoc_plugin v22.4.0
- Update how we calculate import prefixes (#1010); import prefixes are now
unique per-library instead of being unique across all generated libraries. - Ignore
unused_importdiagnostics for*.pbjson.dartfiles. (#1013) - Revert the change to not generate empty
*.pbenum.dartfiles; these can be
exported from other enum files. (#1016) - Improve the readablity of generated gRPC client files. (#1021)
- Adjust the text of generated file headers ('This is a generated file...').
(#1022)
package:protoc_plugin v22.3.0
- Update the generated code to improve readability and to better follow common Dart patterns.
- No longer generate empty enum (
*.pbenum.dart) files. - No longer generate empty server (
*.pbserver.dart) files. - Ignore
implementation_importsfor some generated files.