Found new managed modules references#1242
Merged
Merged
Conversation
| }, | ||
| { | ||
| "name": "v35.0", | ||
| "digest": "e7579d76656bf352b2369d1c855f3a3ce25aeb3fd4a0505ad065e468fab2df935d6f2d14daa7d5dd98b4cd8102c6a509ede5969783be083b0e35e279b5de8be6" |
There was a problem hiding this comment.
[Posted at 2026-05-20T12:52:00Z]
Intermediate transition
$ casdiff v34.1 \
v35.0 \
--format=markdown5 files changed: 0 removed, 0 renamed, 0 added, 5 changed content.
5 files changed: 0 removed, 0 renamed, 0 added, 5 changed content.
Files changed content:
buf.md:
--- shake256:3ce5a81127a805cd15b1003159b504229a725bbb03c099905a26bcef1bcfe535beee30b1107e7301d368866f5a28c27e2bc3d79a606022d3060d86b251f10ffa buf.md
+++ shake256:79883ba311a2ce5432112a9c639d953b1db80105c92bb2b7b03e5c8d0d415ff73a566683008890a68dac2d3aeaedfa41660c5e258225b5c8c48d8066c06b28ab buf.md
@@ -41,7 +41,7 @@
# buf.yaml
version: v1
deps:
- - buf.build/protocolbuffers/wellknowntypes:v21.12
+ - {{bsrhost}}/protocolbuffers/wellknowntypes:v21.12
```
We update the tags on this module for every release of
@@ -58,7 +58,7 @@
Semantic versioning with `v{major}.{minor}.{patch}` was adhered to:
```
-v3.0.0, v3.0.2, v3.1.0, v3.2.0, v3.3.0, ...
+v3.0.0, v3.0.2, v3.1.0, v3.2.0, v3.3.0, ...
→
..., v3.19.6, v3.20.0, v3.20.1, v3.20.2, v3.20.3
```
google/protobuf/any.proto:
--- shake256:1c6874c26892049275074aff5b9f87e59b45a2a6d6c25782ac827d5e64f43f35a5b497e912e0d36ac30eeda2d09363bd9b19e95918d740a98bed15037df65622 google/protobuf/any.proto
+++ shake256:44fce03c43269bb017c93d1fc2a5b8dd8413313d0123652aa97ab0d715ebc290daf7214e232a484e0b467d16ae4af255ef9670c93397c949546ea247dfb18852 google/protobuf/any.proto
@@ -42,121 +42,65 @@
// `Any` contains an arbitrary serialized protocol buffer message along with a
// URL that describes the type of the serialized message.
//
-// Protobuf library provides support to pack/unpack Any values in the form
-// of utility functions or additional generated methods of the Any type.
-//
-// Example 1: Pack and unpack a message in C++.
-//
-// Foo foo = ...;
-// Any any;
-// any.PackFrom(foo);
-// ...
-// if (any.UnpackTo(&foo)) {
-// ...
-// }
-//
-// Example 2: Pack and unpack a message in Java.
-//
-// Foo foo = ...;
-// Any any = Any.pack(foo);
-// ...
-// if (any.is(Foo.class)) {
-// foo = any.unpack(Foo.class);
-// }
-// // or ...
-// if (any.isSameTypeAs(Foo.getDefaultInstance())) {
-// foo = any.unpack(Foo.getDefaultInstance());
-// }
-//
-// Example 3: Pack and unpack a message in Python.
-//
-// foo = Foo(...)
-// any = Any()
-// any.Pack(foo)
-// ...
-// if any.Is(Foo.DESCRIPTOR):
-// any.Unpack(foo)
-// ...
-//
-// Example 4: Pack and unpack a message in Go
-//
-// foo := &pb.Foo{...}
-// any, err := anypb.New(foo)
-// if err != nil {
-// ...
-// }
-// ...
-// foo := &pb.Foo{}
-// if err := any.UnmarshalTo(foo); err != nil {
-// ...
-// }
-//
-// The pack methods provided by protobuf library will by default use
-// 'type.googleapis.com/full.type.name' as the type URL and the unpack
-// methods only use the fully qualified type name after the last '/'
-// in the type URL, for example "foo.bar.com/x/y.z" will yield type
-// name "y.z".
-//
-// JSON
-// ====
-// The JSON representation of an `Any` value uses the regular
-// representation of the deserialized, embedded message, with an
-// additional field `@type` which contains the type URL. Example:
-//
-// package google.profile;
-// message Person {
-// string first_name = 1;
-// string last_name = 2;
-// }
-//
-// {
-// "@type": "type.googleapis.com/google.profile.Person",
-// "firstName": <string>,
-// "lastName": <string>
-// }
-//
-// If the embedded message type is well-known and has a custom JSON
-// representation, that representation will be embedded adding a field
-// `value` which holds the custom JSON in addition to the `@type`
-// field. Example (for message [google.protobuf.Duration][]):
-//
-// {
-// "@type": "type.googleapis.com/google.protobuf.Duration",
-// "value": "1.212s"
-// }
-//
+// In its binary encoding, an `Any` is an ordinary message; but in other wire
+// forms like JSON, it has a special encoding. The format of the type URL is
+// described on the `type_url` field.
+//
+// Protobuf APIs provide utilities to interact with `Any` values:
+//
+// - A 'pack' operation accepts a message and constructs a generic `Any` wrapper
+// around it.
+// - An 'unpack' operation reads the content of an `Any` message, either into an
+// existing message or a new one. Unpack operations must check the type of the
+// value they unpack against the declared `type_url`.
+// - An 'is' operation decides whether an `Any` contains a message of the given
+// type, i.e. whether it can 'unpack' that type.
+//
+// The JSON format representation of an `Any` follows one of these cases:
+//
+// - For types without special-cased JSON encodings, the JSON format
+// representation of the `Any` is the same as that of the message, with an
+// additional `@type` field which contains the type URL.
+// - For types with special-cased JSON encodings (typically called 'well-known'
+// types, listed in https://protobuf.dev/programming-guides/json/#any), the
+// JSON format representation has a key `@type` which contains the type URL
+// and a key `value` which contains the JSON-serialized value.
+//
+// The text format representation of an `Any` is like a message with one field
+// whose name is the type URL in brackets. For example, an `Any` containing a
+// `foo.Bar` message may be written `[type.googleapis.com/foo.Bar] { a: 2 }`.
message Any {
- // A URL/resource name that uniquely identifies the type of the serialized
- // protocol buffer message. This string must contain at least
- // one "/" character. The last segment of the URL's path must represent
- // the fully qualified name of the type (as in
- // `path/google.protobuf.Duration`). The name should be in a canonical form
- // (e.g., leading "." is not accepted).
+ // Identifies the type of the serialized Protobuf message with a URI reference
+ // consisting of a prefix ending in a slash and the fully-qualified type name.
//
- // In practice, teams usually precompile into the binary all types that they
- // expect it to use in the context of Any. However, for URLs which use the
- // scheme `http`, `https`, or no scheme, one can optionally set up a type
- // server that maps type URLs to message definitions as follows:
+ // Example: type.googleapis.com/google.protobuf.StringValue
//
- // * If no scheme is provided, `https` is assumed.
- // * An HTTP GET on the URL must yield a [google.protobuf.Type][]
- // value in binary format, or produce an error.
- // * Applications are allowed to cache lookup results based on the
- // URL, or have them precompiled into a binary to avoid any
- // lookup. Therefore, binary compatibility needs to be preserved
- // on changes to types. (Use versioned type names to manage
- // breaking changes.)
+ // This string must contain at least one `/` character, and the content after
+ // the last `/` must be the fully-qualified name of the type in canonical
+ // form, without a leading dot. Do not write a scheme on these URI references
+ // so that clients do not attempt to contact them.
//
- // Note: this functionality is not currently available in the official
- // protobuf release, and it is not used for type URLs beginning with
- // type.googleapis.com. As of May 2023, there are no widely used type server
- // implementations and no plans to implement one.
+ // The prefix is arbitrary and Protobuf implementations are expected to
+ // simply strip off everything up to and including the last `/` to identify
+ // the type. `type.googleapis.com/` is a common default prefix that some
+ // legacy implementations require. This prefix does not indicate the origin of
+ // the type, and URIs containing it are not expected to respond to any
+ // requests.
//
- // Schemes other than `http`, `https` (or the empty scheme) might be
- // used with implementation specific semantics.
+ // All type URL strings must be legal URI references with the additional
+ // restriction (for the text format) that the content of the reference
+ // must consist only of alphanumeric characters, percent-encoded escapes, and
+ // characters in the following set (not including the outer backticks):
+ // `/-.~_!$&()*+,;=`. Despite our allowing percent encodings, implementations
+ // should not unescape them to prevent confusion with existing parsers. For
+ // example, `type.googleapis.com%2FFoo` should be rejected.
//
+ // In the original design of `Any`, the possibility of launching a type
+ // resolution service at these type URLs was considered but Protobuf never
+ // implemented one and considers contacting these URLs to be problematic and
+ // a potential security issue. Do not attempt to contact type URLs.
string type_url = 1;
- // Must be a valid serialized protocol buffer of the above specified type.
+ // Holds a Protobuf serialization of the type described by type_url.
bytes value = 2;
}
google/protobuf/cpp_features.proto:
--- shake256:7e7b42c4681a54c57930d9d33422e44a91bd97fdd319042030184345a11d9b973629ab9f1145fdf198fbb3c5c7a330c7ed93ad44db3536a161bbd0e949f8d17f google/protobuf/cpp_features.proto
+++ shake256:9b345056b93152a41897728a29e0b313d748541b58357f08f079f828e3575a52987f93a88d98c675d583c1de6b43b0df036b7adfbb056dc58df8710c494a9b9c google/protobuf/cpp_features.proto
@@ -1,5 +1,5 @@
// Protocol Buffers - Google's data interchange format
-// Copyright 2023 Google Inc. All rights reserved.
+// Copyright 2023 Google LLC. All rights reserved.
//
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file or at
@@ -64,4 +64,24 @@
edition_defaults = { edition: EDITION_LEGACY, value: "false" },
edition_defaults = { edition: EDITION_2024, value: "true" }
];
+
+ enum RepeatedType {
+ REPEATED_TYPE_UNKNOWN = 0;
+ // The repeated field will be backed by proto2::Repeated(Ptr)Field, and
+ // accessors will return a reference/pointer to this type.
+ LEGACY = 1;
+ // The repeated field has an opaque backing type, and accessors will return
+ // a RepeatedFieldProxy.
+ PROXY = 2;
+ }
+
+ optional RepeatedType repeated_type = 4 [
+ retention = RETENTION_RUNTIME,
+ targets = TARGET_TYPE_FIELD,
+ targets = TARGET_TYPE_FILE,
+ feature_support = {
+ edition_introduced: EDITION_UNSTABLE,
+ },
+ edition_defaults = { edition: EDITION_LEGACY, value: "LEGACY" }
+ ];
}
google/protobuf/descriptor.proto:
--- shake256:1b87b903df1d64270e3b8c3458bdd28ad8a9e29feeca3da0e51ede2421d90d7c90c1b3a0b314c7e272eb3bf8b208f2f9addf1a2d9c7a1fc582162d832677a3a3 google/protobuf/descriptor.proto
+++ shake256:0a7d1f2ba306506998bb15d242deee55be625f8c1d9e564b3c066d9277b1fe22815f014137e6da39d09840e26e56f8b5f7d646164e8e0d4141e4d245aa6e7886 google/protobuf/descriptor.proto
@@ -1,32 +1,9 @@
// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
+// Copyright 2008 Google LLC. All rights reserved.
//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file or at
+// https://developers.google.com/open-source/licenses/bsd
// Author: kenton@google.com (Kenton Varda)
// Based on original Protocol Buffers design by
@@ -85,6 +62,7 @@
// comparison.
EDITION_2023 = 1000;
EDITION_2024 = 1001;
+ EDITION_2026 = 1002;
// A placeholder edition for developing and testing unscheduled features.
EDITION_UNSTABLE = 9999;
@@ -189,6 +167,9 @@
}
message ExtensionRangeOptions {
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -583,6 +564,14 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 50;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998 [declaration = {
+ number: 990,
+ full_name: ".pb.file.cpp",
+ type: ".pb.file.CppFileOptions"
+ }];
+
// The parser stores options it doesn't recognize here.
// See the documentation for the "Options" section above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -672,6 +661,10 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 12;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -842,6 +835,10 @@
}
optional FeatureSupport feature_support = 22;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -859,6 +856,10 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 1;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -894,6 +895,10 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 7;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -922,6 +927,10 @@
// Information about the support window of a feature value.
optional FieldOptions.FeatureSupport feature_support = 4;
+ // Range reserved for first-class extension options defined by the Protobuf
+ // team. Custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -948,6 +957,10 @@
// this is a formalization for deprecating services.
optional bool deprecated = 33 [default = false];
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -985,6 +998,10 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 35;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -1133,6 +1150,7 @@
ENFORCE_NAMING_STYLE_UNKNOWN = 0;
STYLE2024 = 1;
STYLE_LEGACY = 2;
+ STYLE2026 = 3;
}
optional EnforceNamingStyle enforce_naming_style = 7 [
retention = RETENTION_SOURCE,
@@ -1149,7 +1167,8 @@
edition_introduced: EDITION_2024,
},
edition_defaults = { edition: EDITION_LEGACY, value: "STYLE_LEGACY" },
- edition_defaults = { edition: EDITION_2024, value: "STYLE2024" }
+ edition_defaults = { edition: EDITION_2024, value: "STYLE2024" },
+ edition_defaults = { edition: EDITION_UNSTABLE, value: "STYLE2026" }
];
message VisibilityFeature {
@@ -1203,6 +1222,11 @@
type: ".pb.PythonFeatures"
},
declaration = {
+ number: 1004,
+ full_name: ".pb.csharp",
+ type: ".pb.CSharpFeatures"
+ },
+ declaration = {
number: 1100,
full_name: ".imp.impress_feature_set",
type: ".imp.ImpressFeatureSet"
google/protobuf/struct.proto:
--- shake256:a949db8740c3d3ef65e7787a779db1bd1342767cbd053b510273849cf7cf996f65bd08b9c26086f44d310157b1eee784bac7d0b8f68559a7382132875ed1f30d google/protobuf/struct.proto
+++ shake256:b78f6252dbbc3395b4cb69c572dd88e239cec8b643a569cfa24960d4dd4b5e3e9c2d1d49290e2d4020284d7dc5184f080e26863c3bfc35c60ceebb3991e954f5 google/protobuf/struct.proto
@@ -40,55 +40,71 @@
option objc_class_prefix = "GPB";
option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-// `Struct` represents a structured data value, consisting of fields
-// which map to dynamically typed values. In some languages, `Struct`
-// might be supported by a native representation. For example, in
-// scripting languages like JS a struct is represented as an
-// object. The details of that representation are described together
-// with the proto support for the language.
+// Represents a JSON object.
//
-// The JSON representation for `Struct` is JSON object.
+// An unordered key-value map, intending to perfectly capture the semantics of a
+// JSON object. This enables parsing any arbitrary JSON payload as a message
+// field in ProtoJSON format.
+//
+// This follows RFC 8259 guidelines for interoperable JSON: notably this type
+// cannot represent large Int64 values or `NaN`/`Infinity` numbers,
+// since the JSON format generally does not support those values in its number
+// type.
+//
+// If you do not intend to parse arbitrary JSON into your message, a custom
+// typed message should be preferred instead of using this type.
message Struct {
// Unordered map of dynamically typed values.
map<string, Value> fields = 1;
}
+// Represents a JSON value.
+//
// `Value` represents a dynamically typed value which can be either
// null, a number, a string, a boolean, a recursive struct value, or a
// list of values. A producer of value is expected to set one of these
-// variants. Absence of any variant indicates an error.
-//
-// The JSON representation for `Value` is JSON value.
+// variants. Absence of any variant is an invalid state.
message Value {
// The kind of value.
oneof kind {
- // Represents a null value.
+ // Represents a JSON `null`.
NullValue null_value = 1;
- // Represents a double value.
+
+ // Represents a JSON number. Must not be `NaN`, `Infinity` or
+ // `-Infinity`, since those are not supported in JSON. This also cannot
+ // represent large Int64 values, since JSON format generally does not
+ // support them in its number type.
double number_value = 2;
- // Represents a string value.
+
+ // Represents a JSON string.
string string_value = 3;
- // Represents a boolean value.
+
+ // Represents a JSON boolean (`true` or `false` literal in JSON).
bool bool_value = 4;
- // Represents a structured value.
+
+ // Represents a JSON object.
Struct struct_value = 5;
- // Represents a repeated `Value`.
+
+ // Represents a JSON array.
ListValue list_value = 6;
}
}
-// `NullValue` is a singleton enumeration to represent the null value for the
-// `Value` type union.
+// Represents a JSON `null`.
//
-// The JSON representation for `NullValue` is JSON `null`.
+// `NullValue` is a sentinel, using an enum with only one value to represent
+// the null value for the `Value` type union.
+//
+// A field of type `NullValue` with any value other than `0` is considered
+// invalid. Most ProtoJSON serializers will emit a Value with a `null_value` set
+// as a JSON `null` regardless of the integer value, and so will round trip to
+// a `0` value.
enum NullValue {
// Null value.
NULL_VALUE = 0;
}
-// `ListValue` is a wrapper around a repeated field of values.
-//
-// The JSON representation for `ListValue` is JSON array.
+// Represents a JSON array.
message ListValue {
// Repeated field of dynamically typed values.
repeated Value values = 1;
| { | ||
| "module_name": "googleapis/cloud-run", | ||
| "latest_reference": "aa87617d6732d348ff158d20d474c0dfba3d0086" | ||
| "latest_reference": "ace54bb386870ac182a4cf7278bfa0e2cc089670" |
There was a problem hiding this comment.
[Posted at 2026-05-20T12:52:02Z]
Overall transition
$ casdiff aa87617d6732d348ff158d20d474c0dfba3d0086 \
ace54bb386870ac182a4cf7278bfa0e2cc089670 \
--format=markdown0 files changed: 0 removed, 0 renamed, 0 added, 0 changed content.
| { | ||
| "module_name": "googleapis/googleapis", | ||
| "latest_reference": "aa87617d6732d348ff158d20d474c0dfba3d0086" | ||
| "latest_reference": "ace54bb386870ac182a4cf7278bfa0e2cc089670" |
There was a problem hiding this comment.
[Posted at 2026-05-20T12:52:03Z]
Overall transition
$ casdiff aa87617d6732d348ff158d20d474c0dfba3d0086 \
ace54bb386870ac182a4cf7278bfa0e2cc089670 \
--format=markdown0 files changed: 0 removed, 0 renamed, 0 added, 0 changed content.
| { | ||
| "module_name": "protocolbuffers/wellknowntypes", | ||
| "latest_reference": "v34.1" | ||
| "latest_reference": "v35.0" |
There was a problem hiding this comment.
[Posted at 2026-05-20T12:52:04Z]
Overall transition
$ casdiff v34.1 \
v35.0 \
--format=markdown5 files changed: 0 removed, 0 renamed, 0 added, 5 changed content.
Files changed content:
buf.md:
--- shake256:3ce5a81127a805cd15b1003159b504229a725bbb03c099905a26bcef1bcfe535beee30b1107e7301d368866f5a28c27e2bc3d79a606022d3060d86b251f10ffa buf.md
+++ shake256:79883ba311a2ce5432112a9c639d953b1db80105c92bb2b7b03e5c8d0d415ff73a566683008890a68dac2d3aeaedfa41660c5e258225b5c8c48d8066c06b28ab buf.md
@@ -41,7 +41,7 @@
# buf.yaml
version: v1
deps:
- - buf.build/protocolbuffers/wellknowntypes:v21.12
+ - {{bsrhost}}/protocolbuffers/wellknowntypes:v21.12
```
We update the tags on this module for every release of
@@ -58,7 +58,7 @@
Semantic versioning with `v{major}.{minor}.{patch}` was adhered to:
```
-v3.0.0, v3.0.2, v3.1.0, v3.2.0, v3.3.0, ...
+v3.0.0, v3.0.2, v3.1.0, v3.2.0, v3.3.0, ...
→
..., v3.19.6, v3.20.0, v3.20.1, v3.20.2, v3.20.3
```
google/protobuf/any.proto:
--- shake256:1c6874c26892049275074aff5b9f87e59b45a2a6d6c25782ac827d5e64f43f35a5b497e912e0d36ac30eeda2d09363bd9b19e95918d740a98bed15037df65622 google/protobuf/any.proto
+++ shake256:44fce03c43269bb017c93d1fc2a5b8dd8413313d0123652aa97ab0d715ebc290daf7214e232a484e0b467d16ae4af255ef9670c93397c949546ea247dfb18852 google/protobuf/any.proto
@@ -42,121 +42,65 @@
// `Any` contains an arbitrary serialized protocol buffer message along with a
// URL that describes the type of the serialized message.
//
-// Protobuf library provides support to pack/unpack Any values in the form
-// of utility functions or additional generated methods of the Any type.
-//
-// Example 1: Pack and unpack a message in C++.
-//
-// Foo foo = ...;
-// Any any;
-// any.PackFrom(foo);
-// ...
-// if (any.UnpackTo(&foo)) {
-// ...
-// }
-//
-// Example 2: Pack and unpack a message in Java.
-//
-// Foo foo = ...;
-// Any any = Any.pack(foo);
-// ...
-// if (any.is(Foo.class)) {
-// foo = any.unpack(Foo.class);
-// }
-// // or ...
-// if (any.isSameTypeAs(Foo.getDefaultInstance())) {
-// foo = any.unpack(Foo.getDefaultInstance());
-// }
-//
-// Example 3: Pack and unpack a message in Python.
-//
-// foo = Foo(...)
-// any = Any()
-// any.Pack(foo)
-// ...
-// if any.Is(Foo.DESCRIPTOR):
-// any.Unpack(foo)
-// ...
-//
-// Example 4: Pack and unpack a message in Go
-//
-// foo := &pb.Foo{...}
-// any, err := anypb.New(foo)
-// if err != nil {
-// ...
-// }
-// ...
-// foo := &pb.Foo{}
-// if err := any.UnmarshalTo(foo); err != nil {
-// ...
-// }
-//
-// The pack methods provided by protobuf library will by default use
-// 'type.googleapis.com/full.type.name' as the type URL and the unpack
-// methods only use the fully qualified type name after the last '/'
-// in the type URL, for example "foo.bar.com/x/y.z" will yield type
-// name "y.z".
-//
-// JSON
-// ====
-// The JSON representation of an `Any` value uses the regular
-// representation of the deserialized, embedded message, with an
-// additional field `@type` which contains the type URL. Example:
-//
-// package google.profile;
-// message Person {
-// string first_name = 1;
-// string last_name = 2;
-// }
-//
-// {
-// "@type": "type.googleapis.com/google.profile.Person",
-// "firstName": <string>,
-// "lastName": <string>
-// }
-//
-// If the embedded message type is well-known and has a custom JSON
-// representation, that representation will be embedded adding a field
-// `value` which holds the custom JSON in addition to the `@type`
-// field. Example (for message [google.protobuf.Duration][]):
-//
-// {
-// "@type": "type.googleapis.com/google.protobuf.Duration",
-// "value": "1.212s"
-// }
-//
+// In its binary encoding, an `Any` is an ordinary message; but in other wire
+// forms like JSON, it has a special encoding. The format of the type URL is
+// described on the `type_url` field.
+//
+// Protobuf APIs provide utilities to interact with `Any` values:
+//
+// - A 'pack' operation accepts a message and constructs a generic `Any` wrapper
+// around it.
+// - An 'unpack' operation reads the content of an `Any` message, either into an
+// existing message or a new one. Unpack operations must check the type of the
+// value they unpack against the declared `type_url`.
+// - An 'is' operation decides whether an `Any` contains a message of the given
+// type, i.e. whether it can 'unpack' that type.
+//
+// The JSON format representation of an `Any` follows one of these cases:
+//
+// - For types without special-cased JSON encodings, the JSON format
+// representation of the `Any` is the same as that of the message, with an
+// additional `@type` field which contains the type URL.
+// - For types with special-cased JSON encodings (typically called 'well-known'
+// types, listed in https://protobuf.dev/programming-guides/json/#any), the
+// JSON format representation has a key `@type` which contains the type URL
+// and a key `value` which contains the JSON-serialized value.
+//
+// The text format representation of an `Any` is like a message with one field
+// whose name is the type URL in brackets. For example, an `Any` containing a
+// `foo.Bar` message may be written `[type.googleapis.com/foo.Bar] { a: 2 }`.
message Any {
- // A URL/resource name that uniquely identifies the type of the serialized
- // protocol buffer message. This string must contain at least
- // one "/" character. The last segment of the URL's path must represent
- // the fully qualified name of the type (as in
- // `path/google.protobuf.Duration`). The name should be in a canonical form
- // (e.g., leading "." is not accepted).
+ // Identifies the type of the serialized Protobuf message with a URI reference
+ // consisting of a prefix ending in a slash and the fully-qualified type name.
//
- // In practice, teams usually precompile into the binary all types that they
- // expect it to use in the context of Any. However, for URLs which use the
- // scheme `http`, `https`, or no scheme, one can optionally set up a type
- // server that maps type URLs to message definitions as follows:
+ // Example: type.googleapis.com/google.protobuf.StringValue
//
- // * If no scheme is provided, `https` is assumed.
- // * An HTTP GET on the URL must yield a [google.protobuf.Type][]
- // value in binary format, or produce an error.
- // * Applications are allowed to cache lookup results based on the
- // URL, or have them precompiled into a binary to avoid any
- // lookup. Therefore, binary compatibility needs to be preserved
- // on changes to types. (Use versioned type names to manage
- // breaking changes.)
+ // This string must contain at least one `/` character, and the content after
+ // the last `/` must be the fully-qualified name of the type in canonical
+ // form, without a leading dot. Do not write a scheme on these URI references
+ // so that clients do not attempt to contact them.
//
- // Note: this functionality is not currently available in the official
- // protobuf release, and it is not used for type URLs beginning with
- // type.googleapis.com. As of May 2023, there are no widely used type server
- // implementations and no plans to implement one.
+ // The prefix is arbitrary and Protobuf implementations are expected to
+ // simply strip off everything up to and including the last `/` to identify
+ // the type. `type.googleapis.com/` is a common default prefix that some
+ // legacy implementations require. This prefix does not indicate the origin of
+ // the type, and URIs containing it are not expected to respond to any
+ // requests.
//
- // Schemes other than `http`, `https` (or the empty scheme) might be
- // used with implementation specific semantics.
+ // All type URL strings must be legal URI references with the additional
+ // restriction (for the text format) that the content of the reference
+ // must consist only of alphanumeric characters, percent-encoded escapes, and
+ // characters in the following set (not including the outer backticks):
+ // `/-.~_!$&()*+,;=`. Despite our allowing percent encodings, implementations
+ // should not unescape them to prevent confusion with existing parsers. For
+ // example, `type.googleapis.com%2FFoo` should be rejected.
//
+ // In the original design of `Any`, the possibility of launching a type
+ // resolution service at these type URLs was considered but Protobuf never
+ // implemented one and considers contacting these URLs to be problematic and
+ // a potential security issue. Do not attempt to contact type URLs.
string type_url = 1;
- // Must be a valid serialized protocol buffer of the above specified type.
+ // Holds a Protobuf serialization of the type described by type_url.
bytes value = 2;
}
google/protobuf/cpp_features.proto:
--- shake256:7e7b42c4681a54c57930d9d33422e44a91bd97fdd319042030184345a11d9b973629ab9f1145fdf198fbb3c5c7a330c7ed93ad44db3536a161bbd0e949f8d17f google/protobuf/cpp_features.proto
+++ shake256:9b345056b93152a41897728a29e0b313d748541b58357f08f079f828e3575a52987f93a88d98c675d583c1de6b43b0df036b7adfbb056dc58df8710c494a9b9c google/protobuf/cpp_features.proto
@@ -1,5 +1,5 @@
// Protocol Buffers - Google's data interchange format
-// Copyright 2023 Google Inc. All rights reserved.
+// Copyright 2023 Google LLC. All rights reserved.
//
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file or at
@@ -64,4 +64,24 @@
edition_defaults = { edition: EDITION_LEGACY, value: "false" },
edition_defaults = { edition: EDITION_2024, value: "true" }
];
+
+ enum RepeatedType {
+ REPEATED_TYPE_UNKNOWN = 0;
+ // The repeated field will be backed by proto2::Repeated(Ptr)Field, and
+ // accessors will return a reference/pointer to this type.
+ LEGACY = 1;
+ // The repeated field has an opaque backing type, and accessors will return
+ // a RepeatedFieldProxy.
+ PROXY = 2;
+ }
+
+ optional RepeatedType repeated_type = 4 [
+ retention = RETENTION_RUNTIME,
+ targets = TARGET_TYPE_FIELD,
+ targets = TARGET_TYPE_FILE,
+ feature_support = {
+ edition_introduced: EDITION_UNSTABLE,
+ },
+ edition_defaults = { edition: EDITION_LEGACY, value: "LEGACY" }
+ ];
}
google/protobuf/descriptor.proto:
--- shake256:1b87b903df1d64270e3b8c3458bdd28ad8a9e29feeca3da0e51ede2421d90d7c90c1b3a0b314c7e272eb3bf8b208f2f9addf1a2d9c7a1fc582162d832677a3a3 google/protobuf/descriptor.proto
+++ shake256:0a7d1f2ba306506998bb15d242deee55be625f8c1d9e564b3c066d9277b1fe22815f014137e6da39d09840e26e56f8b5f7d646164e8e0d4141e4d245aa6e7886 google/protobuf/descriptor.proto
@@ -1,32 +1,9 @@
// Protocol Buffers - Google's data interchange format
-// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
+// Copyright 2008 Google LLC. All rights reserved.
//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are
-// met:
-//
-// * Redistributions of source code must retain the above copyright
-// notice, this list of conditions and the following disclaimer.
-// * Redistributions in binary form must reproduce the above
-// copyright notice, this list of conditions and the following disclaimer
-// in the documentation and/or other materials provided with the
-// distribution.
-// * Neither the name of Google Inc. nor the names of its
-// contributors may be used to endorse or promote products derived from
-// this software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file or at
+// https://developers.google.com/open-source/licenses/bsd
// Author: kenton@google.com (Kenton Varda)
// Based on original Protocol Buffers design by
@@ -85,6 +62,7 @@
// comparison.
EDITION_2023 = 1000;
EDITION_2024 = 1001;
+ EDITION_2026 = 1002;
// A placeholder edition for developing and testing unscheduled features.
EDITION_UNSTABLE = 9999;
@@ -189,6 +167,9 @@
}
message ExtensionRangeOptions {
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -583,6 +564,14 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 50;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998 [declaration = {
+ number: 990,
+ full_name: ".pb.file.cpp",
+ type: ".pb.file.CppFileOptions"
+ }];
+
// The parser stores options it doesn't recognize here.
// See the documentation for the "Options" section above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -672,6 +661,10 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 12;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -842,6 +835,10 @@
}
optional FeatureSupport feature_support = 22;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -859,6 +856,10 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 1;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -894,6 +895,10 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 7;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -922,6 +927,10 @@
// Information about the support window of a feature value.
optional FieldOptions.FeatureSupport feature_support = 4;
+ // Range reserved for first-class extension options defined by the Protobuf
+ // team. Custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -948,6 +957,10 @@
// this is a formalization for deprecating services.
optional bool deprecated = 33 [default = false];
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -985,6 +998,10 @@
// developers should rely on the protoreflect APIs for their client language.
optional FeatureSet features = 35;
+ // Range reserved for first-class custom options defined by the Protobuf
+ // team. User custom options must use the 1000+ range instead.
+ extensions 990 to 998;
+
// The parser stores options it doesn't recognize here. See above.
repeated UninterpretedOption uninterpreted_option = 999;
@@ -1133,6 +1150,7 @@
ENFORCE_NAMING_STYLE_UNKNOWN = 0;
STYLE2024 = 1;
STYLE_LEGACY = 2;
+ STYLE2026 = 3;
}
optional EnforceNamingStyle enforce_naming_style = 7 [
retention = RETENTION_SOURCE,
@@ -1149,7 +1167,8 @@
edition_introduced: EDITION_2024,
},
edition_defaults = { edition: EDITION_LEGACY, value: "STYLE_LEGACY" },
- edition_defaults = { edition: EDITION_2024, value: "STYLE2024" }
+ edition_defaults = { edition: EDITION_2024, value: "STYLE2024" },
+ edition_defaults = { edition: EDITION_UNSTABLE, value: "STYLE2026" }
];
message VisibilityFeature {
@@ -1203,6 +1222,11 @@
type: ".pb.PythonFeatures"
},
declaration = {
+ number: 1004,
+ full_name: ".pb.csharp",
+ type: ".pb.CSharpFeatures"
+ },
+ declaration = {
number: 1100,
full_name: ".imp.impress_feature_set",
type: ".imp.ImpressFeatureSet"
google/protobuf/struct.proto:
--- shake256:a949db8740c3d3ef65e7787a779db1bd1342767cbd053b510273849cf7cf996f65bd08b9c26086f44d310157b1eee784bac7d0b8f68559a7382132875ed1f30d google/protobuf/struct.proto
+++ shake256:b78f6252dbbc3395b4cb69c572dd88e239cec8b643a569cfa24960d4dd4b5e3e9c2d1d49290e2d4020284d7dc5184f080e26863c3bfc35c60ceebb3991e954f5 google/protobuf/struct.proto
@@ -40,55 +40,71 @@
option objc_class_prefix = "GPB";
option csharp_namespace = "Google.Protobuf.WellKnownTypes";
-// `Struct` represents a structured data value, consisting of fields
-// which map to dynamically typed values. In some languages, `Struct`
-// might be supported by a native representation. For example, in
-// scripting languages like JS a struct is represented as an
-// object. The details of that representation are described together
-// with the proto support for the language.
+// Represents a JSON object.
//
-// The JSON representation for `Struct` is JSON object.
+// An unordered key-value map, intending to perfectly capture the semantics of a
+// JSON object. This enables parsing any arbitrary JSON payload as a message
+// field in ProtoJSON format.
+//
+// This follows RFC 8259 guidelines for interoperable JSON: notably this type
+// cannot represent large Int64 values or `NaN`/`Infinity` numbers,
+// since the JSON format generally does not support those values in its number
+// type.
+//
+// If you do not intend to parse arbitrary JSON into your message, a custom
+// typed message should be preferred instead of using this type.
message Struct {
// Unordered map of dynamically typed values.
map<string, Value> fields = 1;
}
+// Represents a JSON value.
+//
// `Value` represents a dynamically typed value which can be either
// null, a number, a string, a boolean, a recursive struct value, or a
// list of values. A producer of value is expected to set one of these
-// variants. Absence of any variant indicates an error.
-//
-// The JSON representation for `Value` is JSON value.
+// variants. Absence of any variant is an invalid state.
message Value {
// The kind of value.
oneof kind {
- // Represents a null value.
+ // Represents a JSON `null`.
NullValue null_value = 1;
- // Represents a double value.
+
+ // Represents a JSON number. Must not be `NaN`, `Infinity` or
+ // `-Infinity`, since those are not supported in JSON. This also cannot
+ // represent large Int64 values, since JSON format generally does not
+ // support them in its number type.
double number_value = 2;
- // Represents a string value.
+
+ // Represents a JSON string.
string string_value = 3;
- // Represents a boolean value.
+
+ // Represents a JSON boolean (`true` or `false` literal in JSON).
bool bool_value = 4;
- // Represents a structured value.
+
+ // Represents a JSON object.
Struct struct_value = 5;
- // Represents a repeated `Value`.
+
+ // Represents a JSON array.
ListValue list_value = 6;
}
}
-// `NullValue` is a singleton enumeration to represent the null value for the
-// `Value` type union.
+// Represents a JSON `null`.
//
-// The JSON representation for `NullValue` is JSON `null`.
+// `NullValue` is a sentinel, using an enum with only one value to represent
+// the null value for the `Value` type union.
+//
+// A field of type `NullValue` with any value other than `0` is considered
+// invalid. Most ProtoJSON serializers will emit a Value with a `null_value` set
+// as a JSON `null` regardless of the integer value, and so will round trip to
+// a `0` value.
enum NullValue {
// Null value.
NULL_VALUE = 0;
}
-// `ListValue` is a wrapper around a repeated field of values.
-//
-// The JSON representation for `ListValue` is JSON array.
+// Represents a JSON array.
message ListValue {
// Repeated field of dynamically typed values.
repeated Value values = 1;
oliversun9
approved these changes
May 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.