Skip to content

Releases: protocolbuffers/protobuf

Protocol Buffers v31.1

28 May 18:57
Compare
Choose a tag to compare

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

Compiler

  • Support allowing late injection of language feature set defaults from FeatureSet extensions while getting feature set extension values. (3419598)

C++

  • Support allowing late injection of language feature set defaults from FeatureSet extensions while getting feature set extension values. (3419598)

Java

  • Add missing copts attribute (#21982) (bec5b5a)
  • Support allowing late injection of language feature set defaults from FeatureSet extensions while getting feature set extension values. (3419598)

Python

  • Support allowing late injection of language feature set defaults from FeatureSet extensions while getting feature set extension values. (3419598)
  • Python pyi print "import datetime" for Duration/Timestamp field (#21885) (0fe099a)
  • Add recursion depth limits to pure python (a3921fb)

Other

  • Fix cmake staleness test (96a9ef6)

Protocol Buffers v29.5

28 May 21:39
Compare
Choose a tag to compare

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

C++

  • Remove fast-path check for non-clang compilers in MessageCreator. (#21612) (69cca9b)

Java

Python

Other

Protocol Buffers v25.8

27 May 21:49
Compare
Choose a tag to compare

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

Java

  • Change pre-22 poison pill to only log once per affected message type. (#21754) (88a3b90)
  • Weaken vulnerable gencode poison pill to a warning by default. (320eafa)

Python

  • Backport recursion limit enforcement to 25.x (29445be)

Protocol Buffers v31.0

14 May 17:32
Compare
Choose a tag to compare

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

Bazel

  • Loosen py_proto_library check to be on the import path instead of full directory (i.e. excluding external/module-name prefix). (a4be867)

Compiler

  • Add support for import option for protoc.(9901db6)
  • Add notices.h with information about our dependencies' licenses and add --notices flag to protoc to print the contents of that file. (7a26486)
  • Move upb minitable code generator into protoc (dce6b0f)
  • Upgrade abseil-cpp to 20250127 and use @com_google_absl -> @abseil-cpp and com_google_googletest -> @googletest canonical BCR names. (ba6b54d)

C++

  • Remove fast-path check for non-clang compilers in MessageCreator. (aa5410d)
  • Add missing include. (d390631)
  • Add weak attribute to GetClassData to speed up clang builds. (d896480)
  • Add nontemporal software prefetcher to repeated ptr field dtor to improve performance. (73f3469)
  • Warn on unused RepeatedPtrField. (683e9d2)
  • Add notices.h with information about our dependencies' licenses and add --notices flag to protoc to print the contents of that file. (7a26486)
  • Fix a bug in handling of implicit-presence string_view fields. (bd70a7c)
  • Control bounds checks via BUILD flags. (d21e8ef)
  • Upgrade abseil-cpp to 20250127 and use @com_google_absl -> @abseil-cpp and com_google_googletest -> @googletest canonical BCR names. (ba6b54d)
  • Create hardened versions of Get and Mutable for repeated_field. (ffade4a)

Java

  • Add weak attribute to GetClassData to speed up clang builds. (d896480)
  • Use ProtobufToStringOutput to control the output format of AbstractMessage.Builder.toString. (f5cb162)
  • Implement Protobuf Java Immutable API nest_in_file_class feature for Edition 2024. (0416c3e)
  • Introduce a Generated annotation to eventually replace javax.annotation.Generated (31e57fc)
  • Add volatile to featuresResolved (9e03ca5)
  • Fix Java concurrency issue in feature resolution for old <=3.25.x gencode using lazy feature resolution. (fafb0fd)
  • Remove Java runtime classes from kotlin release. (079be27)
  • Split maven dependencies into dev vs local (#20549) (e045fc6)
  • Improve error messaging when detecting and erroring out on integer overflow of byte count limit variables. (097fdb8)

Kotlin

  • Remove Java runtime classes from kotlin release. (079be27)

Csharp

  • Remove "experimental API" warnings from members in the .NET protobuf runtime. (afea52f)
  • Improve performace of repeated packed fixedSize fields (#19667) (85507b9)

Objective-C

  • [ObjC] Deprecate GPBFieldDescriptor.isOptional. (86ab252)
  • [ObjC] Raise the library version and enable new generated code. (a639cf8)

Rust

  • Cherry-pick Rust fix to 31.x (#21617) (01b42bb)
  • Add upb_Map_GetMutable API to upb (dd5bf5e)
  • See also UPB changes below, which may affect Rust.

Python

  • Update GetCurrentTime to use datetime.datetime.now (01b154c)
  • Make Py JSON float_precision apply to both float and double fields. (5b54ee3)
  • -Add '+' and '-' annotations for Timestamp and Duration in Python (fff783e)
  • Bug fix for FieldMask.MergeFrom() with unset fields. (1c87ac3)
  • Make python text_format able to skip unknown fields for repeated messages (dcafca2)
  • Fix segment fault for UPB Pyhon 'in' method of empty repeated extensions (da04261)
  • Fix upb to escape DefinitelyNeedsEscape (like " and ') for bytes field (b234305)
  • Check with fallback descriptorDB for FindExtensionByNumber()/FindAllExtensions in UPB python pool. (9fd28d9)
  • Add clear() method to repeated fields in Python. (0324f39)
  • Register Scalar/MessageMapContainerTypes as virtual subclasses of (9a0b591)
  • Fix python codegen crash when C++ features are used. (308aaf4)
  • Add more detail to the comment for GetMessageClassesForFiles (9befb58)
  • Add constructing unpack routine to Python Protobuf Any API. (fb78c09)
  • Implement typing for proto Timestamp/Duration assignments. (0e3326b)

PHP

  • Deprecate Descriptor Label. As an alternative, add helper methods for checking whether a field is required or repeated. (d82de8f)
  • Feat(php): improve return typehint when repeatedfield (#11734) (e04fe69)

PHP C-Extension

  • Automated rollback of commit f9863df. (#21355) (a59988c)
  • Deprecate Descriptor Label. As an alternative, add helper methods for checking whether a field is required or repeated. (d82de8f)
  • Ruby: Allow to get a file descriptor by a file name (#20287) (c398592)
  • Feat(php): improve return typehint when repeatedfield (#11734) (e04fe69)
  • See also UPB changes below, which may affect PHP C-Extension.

Ruby

  • Fix silent failure of rb_test rules to run test (#21733) (0cf5489)
  • Ruby | Add support for a protobuf debug build (#21060) (59e1f0f)
  • Ruby | Support installing the gem via git and some other small build tweaks (#21061) (d3560e7)
  • Deprecate Descriptor Label. As an alternative, add helper methods for checking whether a field is required or repeated. (d82de8f)
  • [Ruby]Implement #to_hash for message classes (#20866) (5596f6d)
  • Drop Ruby 3.0 (5de7c80)
  • Fixes #18726 ...
Read more

Protocol Buffers v31.0-rc2

30 Apr 18:12
Compare
Choose a tag to compare
Pre-release

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

Compiler

  • Add support for import option for protoc.(9901db6)

PHP

PHP C-Extension

Other

Protocol Buffers v25.7

23 Apr 23:02
Compare
Choose a tag to compare

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

Compiler

C++

PHP

  • Fix(php): do not throw deprecated warning on field getters for default values (#21033) (a4dc75f)

Ruby

Other

  • Update test_cpp.yml (96fca23)
  • Backport bumps to aarch64 runners (d4a4426)

Protocol Buffers v31.0-rc1

18 Apr 16:16
Compare
Choose a tag to compare
Pre-release

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

Bazel

  • Loosen py_proto_library check to be on the import path instead of full directory (i.e. excluding external/module-name prefix). (a4be867)

Compiler

  • Implement Protobuf Java Immutable API nest_in_file_class feature for Edition 2024. (0416c3e)
  • Fix python codegen crash when C++ features are used. (308aaf4)
  • Add notices.h with information about our dependencies' licenses and add --notices flag to protoc to print the contents of that file. (7a26486)
  • Move upb minitable code generator into protoc (dce6b0f)
  • Upgrade abseil-cpp to 20250127 and use @com_google_absl -> @abseil-cpp and com_google_googletest -> @googletest canonical BCR names. (ba6b54d)

C++

  • Add weak attribute to GetClassData to speed up clang builds. (d896480)
  • Implement Protobuf Java Immutable API nest_in_file_class feature for Edition 2024. (0416c3e)
  • Add nontemporal software prefetcher to repeated ptr field dtor to improve performance. (73f3469)
  • Warn on unused RepeatedPtrField. (683e9d2)
  • Fix python codegen crash when C++ features are used. (308aaf4)
  • Add notices.h with information about our dependencies' licenses and add --notices flag to protoc to print the contents of that file. (7a26486)
  • Fix a bug in handling of implicit-presence string_view fields. (bd70a7c)
  • Move upb minitable code generator into protoc (dce6b0f)
  • Control bounds checks via BUILD flags. (d21e8ef)
  • Upgrade abseil-cpp to 20250127 and use @com_google_absl -> @abseil-cpp and com_google_googletest -> @googletest canonical BCR names. (ba6b54d)
  • Create hardened versions of Get and Mutable for repeated_field. (ffade4a)

Java

  • Add weak attribute to GetClassData to speed up clang builds. (d896480)
  • Use ProtobufToStringOutput to control the output format of AbstractMessage.Builder.toString. (f5cb162)
  • Implement Protobuf Java Immutable API nest_in_file_class feature for Edition 2024. (0416c3e)
  • Introduce a Generated annotation to eventually replace javax.annotation.Generated (31e57fc)
  • Introduce Java NestInFileClass feature in java_features.proto for Edition 2024. (c8ff762)
  • Add volatile to featuresResolved (9e03ca5)
  • Fix Java concurrency issue in feature resolution for old <=3.25.x gencode using lazy feature resolution. (fafb0fd)
  • Automated rollback of commit 1d4b6ba. (1df3dde)
  • Remove Java runtime classes from kotlin release. (079be27)
  • Split maven dependencies into dev vs local (#20549) (e045fc6)
  • Automated rollback of commit 6d2f6fc. (055297b)
  • Improve error messaging when detecting and erroring out on integer overflow of byte count limit variables. (097fdb8)
  • Upgrade abseil-cpp to 20250127 and use @com_google_absl -> @abseil-cpp and com_google_googletest -> @googletest canonical BCR names. (ba6b54d)

Kotlin

  • Remove Java runtime classes from kotlin release. (079be27)

Csharp

  • Remove "experimental API" warnings from members in the .NET protobuf runtime. (afea52f)
  • Improve performace of repeated packed fixedSize fields (#19667) (85507b9)
  • Upgrade abseil-cpp to 20250127 and use @com_google_absl -> @abseil-cpp and com_google_googletest -> @googletest canonical BCR names. (ba6b54d)

Objective-C

  • [ObjC] Deprecate GPBFieldDescriptor.isOptional. (86ab252)
  • [ObjC] Raise the library version and enable new generated code. (a639cf8)
  • Upgrade abseil-cpp to 20250127 and use @com_google_absl -> @abseil-cpp and com_google_googletest -> @googletest canonical BCR names. (ba6b54d)

Rust

  • Add upb_Map_GetMutable API to upb (dd5bf5e)
  • Upgrade abseil-cpp to 20250127 and use @com_google_absl -> @abseil-cpp and com_google_googletest -> @googletest canonical BCR names. (ba6b54d)
  • See also UPB changes below, which may affect Rust.

Python

  • Update GetCurrentTime to use datetime.datetime.now (01b154c)
  • Make Py JSON float_precision apply to both float and double fields. (5b54ee3)
  • -Add '+' and '-' annotations for Timestamp and Duration in Python (fff783e)
  • Bug fix for FieldMask.MergeFrom() with unset fields. (1c87ac3)
  • Make python text_format able to skip unknown fields for repeated messages (dcafca2)
  • Fix segment fault for UPB Pyhon 'in' method of empty repeated extensions (da04261)
  • Fix upb to escape DefinitelyNeedsEscape (like " and ') for bytes field (b234305)
  • Check with fallback descriptorDB for FindExtensionByNumber()/FindAllExtensions in UPB python pool. (9fd28d9)
  • Add clear() method to repeated fields in Python. (0324f39)
  • Register Scalar/MessageMapContainerTypes as virtual subclasses of (9a0b591)
  • Fix python codegen crash when C++ features are used. (308aaf4)
  • Add more detail to the comment for GetMessageClassesForFiles (9befb58)
  • Add constructing unpack routine to Python Protobuf Any API. (fb78c09)
  • Implement typing for proto Timestamp/Duration assignments. (0e3326b)
  • Upgrade abseil-cpp to 20250127 and use @com_google_absl -> @abseil-cpp and com_google_googletest -> @googletest canonical BCR names. (ba6b54d)

PHP

  • Deprecate Descriptor Label. As an alternative, add helper methods for checking whether a field is required or repeated. (d82de8f)
  • Feat(php): improve return typehint when ...
Read more

Protocol Buffers v30.2

26 Mar 18:45
Compare
Choose a tag to compare

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

Compiler

  • Restore generator headers in cmake install until the next breaking C++ release (#20749) (b69f653)

C++

  • Remove dllexport attribute on variable definition. (#20833) (7831669)
  • Restore generator headers in cmake install until the next breaking C++ release (#20749) (b69f653)
  • Change how we decide which empty string implementation to use. (#20708) (221b2a0)

Java

  • Remove dllexport attribute on variable definition. (#20833) (7831669)
  • Add protobuf_maven artifacts to protobuf_maven_dev as well so they can still be referenced correctly using the dev namespace for dev-only targets. (#20771) (09b5078)
  • Add volatile to featuresResolved (#20766) (b7f06f1)
  • Restore generator headers in cmake install until the next breaking C++ release (#20749) (b69f653)
  • Restore custom protobuf maven namespaces to avoid polluting main maven namespace for non-dev dependencies as well. (#20739) (f4b0a79)
  • Fix Java concurrency issue in feature resolution for old <=3.25.x gencode using lazy feature resolution. (#20751) (2dc9f35)
  • Fix lite classes in the protobuf-java Maven release to be JDK8 compatible. (#20843) (7a4c63b)

Kotlin

  • Restore custom protobuf maven namespaces to avoid polluting main maven namespace for non-dev dependencies as well. (#20739) (f4b0a79)

Csharp

  • Restore generator headers in cmake install until the next breaking C++ release (#20749) (b69f653)

Objective-C

  • Restore generator headers in cmake install until the next breaking C++ release (#20749) (b69f653)

Python

  • Restore generator headers in cmake install until the next breaking C++ release (#20749) (b69f653)

Ruby

  • Restore generator headers in cmake install until the next breaking C++ release (#20749) (b69f653)

Other

  • Restore JDK8 compatibility in Bazel for libraries with dependencies from Maven (e.g. //java/util) (#20832) (da9cadc)

Protocol Buffers v29.4

19 Mar 21:36
Compare
Choose a tag to compare

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

Java

  • Fix Java concurrency issue in feature resolution for old <=3.25.x gencode using lazy feature resolution. (#20750) (ce59907)

Protocol Buffers v30.1

13 Mar 21:17
Compare
Choose a tag to compare

Announcements

  • Protobuf News may include additional announcements or pre-announcements for upcoming changes.

Bazel

  • Loosen py_proto_library check to be on the import path instead of full directory (i.e. excluding external/module-name prefix). (#20569) (3576a1f)

Compiler

  • Fix python codegen crash when C++ features are used. (#20577) (250c550)

C++

  • Fix python codegen crash when C++ features are used. (#20577) (250c550)

Java

  • Remove Java runtime classes from kotlin release. (#20607) (4747628)

Kotlin

  • Remove Java runtime classes from kotlin release. (#20607) (4747628)

Python

  • Fix python codegen crash when C++ features are used. (#20577) (250c550)

Other

  • Re-add system_python repo alias to MODULE.bazel (#20662) (ebb5224)