Skip to content

Commit f4a28eb

Browse files
authored
Switch to use reserved mypy-protobuf extension option numbers (#403)
Fixes #396
1 parent db0c2ea commit f4a28eb

File tree

3 files changed

+10
-9
lines changed

3 files changed

+10
-9
lines changed

CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
## Upcoming
22

33
- Mark messages as @typing.final
4+
- Switch to use the reserved mypy-protobuf extension option numbers https://github.com/protocolbuffers/protobuf/blob/main/docs/options.md
45

56
## 3.3.0
67

mypy_protobuf/extensions_pb2.py

+5-5
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

proto/mypy_protobuf/extensions.proto

+4-4
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ message FieldOptions {
1616

1717
extend google.protobuf.FieldOptions {
1818
// Custom field options from mypy-protobuf
19-
FieldOptions options = 60004;
19+
FieldOptions options = 1154;
2020

2121
// Legacy fields. Prefer to use ones within `options` instead.
22-
string casttype = 60000 [deprecated = true];
23-
string keytype = 60002 [deprecated = true];
24-
string valuetype = 60003 [deprecated = true];
22+
string casttype = 1151 [deprecated = true];
23+
string keytype = 1152 [deprecated = true];
24+
string valuetype = 1153 [deprecated = true];
2525
}

0 commit comments

Comments
 (0)