Skip to content

Commit c3e7516

Browse files
authored
Upgrade to Protovalidate v0.11.0 (#291)
This upgrades to the latest v0.11.0 release of Protovalidate. As a result, it conforms to the convention of using `rule` everywhere instead of `constraint`. All usages of `constraint` have been removed. In addition, this adds a few additional tests to the `expected_failures` list as a result of v0.11.0.
1 parent 3a35cc4 commit c3e7516

File tree

15 files changed

+868
-759
lines changed

15 files changed

+868
-759
lines changed

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@ ADD_LICENSE_HEADER := $(BIN)/license-header \
1616
--license-type apache \
1717
--copyright-holder "Buf Technologies, Inc." \
1818
--year-range "2023-2025"
19-
PROTOVALIDATE_VERSION ?= v0.10.4
19+
# This version should be kept in sync with the version in buf.yaml
20+
PROTOVALIDATE_VERSION ?= v0.11.0
2021

2122
.PHONY: help
2223
help: ## Describe useful make targets

buf.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ version: v2
22
modules:
33
- path: proto
44
deps:
5-
- buf.build/bufbuild/protovalidate
6-
- buf.build/bufbuild/protovalidate-testing
5+
- buf.build/bufbuild/protovalidate:v0.11.0
6+
- buf.build/bufbuild/protovalidate-testing:v0.11.0
77
lint:
88
use:
99
- STANDARD

gen/buf/validate/conformance/cases/custom_constraints/custom_constraints_pb2.py

Lines changed: 0 additions & 192 deletions
This file was deleted.

gen/buf/validate/conformance/cases/custom_rules/custom_rules_pb2.py

Lines changed: 232 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 66 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

gen/buf/validate/conformance/cases/numbers_pb2.py

Lines changed: 273 additions & 273 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

gen/buf/validate/conformance/cases/numbers_pb2.pyi

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

gen/buf/validate/validate_pb2.py

Lines changed: 99 additions & 99 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

gen/buf/validate/validate_pb2.pyi

Lines changed: 20 additions & 20 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

protovalidate/internal/extra_func.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
from celpy import celtypes
2222

2323
from protovalidate.internal import string_format
24-
from protovalidate.internal.constraints import MessageType, field_to_cel
24+
from protovalidate.internal.rules import MessageType, field_to_cel
2525

2626
# See https://html.spec.whatwg.org/multipage/input.html#valid-e-mail-address
2727
_email_regex = re.compile(

0 commit comments

Comments
 (0)