Skip to content

Commit 81b747c

Browse files
author
jchadwick-buf
authored
Remove support for deprecated options (#178)
Related protovalidate change: bufbuild/protovalidate#297
1 parent 0b7d315 commit 81b747c

24 files changed

+100
-109
lines changed

.github/workflows/buf.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ jobs:
2828
token: ${{ secrets.BUF_TOKEN }}
2929
format: true
3030
lint: true
31-
breaking: true
3231
push: false
3332
archive: false
3433
- name: Check Generate

.golangci.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,6 @@ linters:
4747
- wsl # over-generous whitespace violates house style
4848
issues:
4949
exclude-use-default: true
50-
exclude:
51-
# we will continue to support the deprecated field until it's removed
52-
- "IgnoreEmpty is deprecated"
53-
- "Skipped is deprecated"
5450
exclude-rules:
5551
# Loosen requirements on conformance executor
5652
- path: internal/cmd/

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ GOLANGCI_LINT_VERSION ?= v1.60.1
1616
# Set to use a different version of protovalidate-conformance.
1717
# Should be kept in sync with the version referenced in proto/buf.lock and
1818
# 'buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go' in go.mod.
19-
CONFORMANCE_VERSION ?= v0.9.0
19+
CONFORMANCE_VERSION ?= v0.10.0
2020

2121
.PHONY: help
2222
help: ## Describe useful make targets

buf.lock

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
version: v2
33
deps:
44
- name: buf.build/bufbuild/protovalidate
5-
commit: 5a7b106cbb87462d9a8c9ffecdbd2e38
6-
digest: b5:0f2dc6c9453e9cc9e9f36807aaa5f94022e837d91fef4dcaeed79a35c0843cc64eba28ff077aab24da3b2cb12639ad256246f9f9a36c033b99d5754b19996b7e
5+
commit: 63bb56e204954558946a641ef0d68910
6+
digest: b5:ec5661b2855484eca2043fe61d27eb22673ab926ccd0e849531752eb17b08402fae1382705cee7f7b42d4d9ec56aff72bba7ec6835902cf6f86323c9ac682d16
77
- name: buf.build/bufbuild/protovalidate-testing
8-
commit: 165ebb0f38244fc2a5b23a82cabe812f
9-
digest: b5:4e3e21cabc93277d9069f7ded53c17659fefe47dd8daf9bc534387590feabe971b2d51b88b324835385650f3fa227e8a793a99ca9814cba76ee678f20ba9b4ef
8+
commit: 6106553151724c9480917a13c2fc2d57
9+
digest: b5:6a7a3700d0396fad82118850c2d94263b80ab2d1462220fab1227ef29bd320d85327748fa583a461e6d0084233a3ea8d5c372e85d12f7d64de075420051f9955
1010
- name: buf.build/envoyproxy/protoc-gen-validate
1111
commit: daf171c6cdb54629b5f51e345a79e4dd
1212
digest: b5:c745e1521879f43740230b1df673d0729f55704efefdcfc489d4a0a2d40c92a26cacfeab62813403040a8b180142d53b398c7ca784a065e43823605ee49681de

builder.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -505,13 +505,11 @@ func (bldr *builder) processRepeatedConstraints(
505505
}
506506

507507
func (bldr *builder) shouldSkip(constraints *validate.FieldConstraints) bool {
508-
return constraints.GetSkipped() ||
509-
constraints.GetIgnore() == validate.Ignore_IGNORE_ALWAYS
508+
return constraints.GetIgnore() == validate.Ignore_IGNORE_ALWAYS
510509
}
511510

512511
func (bldr *builder) shouldIgnoreEmpty(constraints *validate.FieldConstraints) bool {
513-
return constraints.GetIgnoreEmpty() ||
514-
constraints.GetIgnore() == validate.Ignore_IGNORE_IF_UNPOPULATED ||
512+
return constraints.GetIgnore() == validate.Ignore_IGNORE_IF_UNPOPULATED ||
515513
constraints.GetIgnore() == validate.Ignore_IGNORE_IF_DEFAULT_VALUE
516514
}
517515

error_utils.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,8 +121,6 @@ func finalizeViolationPaths(err error) {
121121
for _, violation := range valErr.Violations {
122122
if violation.Proto.GetField() != nil {
123123
slices.Reverse(violation.Proto.GetField().GetElements())
124-
//nolint:staticcheck // Intentional use of deprecated field
125-
violation.Proto.FieldPath = proto.String(fieldPathString(violation.Proto.GetField().GetElements()))
126124
}
127125
}
128126
}

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ module github.com/bufbuild/protovalidate-go
33
go 1.21.1
44

55
require (
6-
buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.4-20241127180247-a33202765966.1
6+
buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.4-20250130201111-63bb56e20495.1
77
github.com/envoyproxy/protoc-gen-validate v1.2.1
88
github.com/google/cel-go v0.23.0
99
github.com/stretchr/testify v1.10.0

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.4-20241127180247-a33202765966.1 h1:yeaeyw0RQUe009ebxBQ3TsqBPptiNEGsiS10t+8Htuo=
2-
buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.4-20241127180247-a33202765966.1/go.mod h1:novQBstnxcGpfKf8qGRATqn1anQKwMJIbH5Q581jibU=
1+
buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.4-20250130201111-63bb56e20495.1 h1:4erM3WLgEG/HIBrpBDmRbs1puhd7p0z7kNXDuhHthwM=
2+
buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.4-20250130201111-63bb56e20495.1/go.mod h1:novQBstnxcGpfKf8qGRATqn1anQKwMJIbH5Q581jibU=
33
cel.dev/expr v0.19.1 h1:NciYrtDRIR0lNCnH1LFJegdjspNx9fI59O7TWcua/W4=
44
cel.dev/expr v0.19.1/go.mod h1:MrpN08Q+lEBs+bGYdLxxHkZoUSsCp0nSKTs0nTymJgw=
55
github.com/antlr4-go/antlr/v4 v4.13.0 h1:lxCg3LAv+EUK6t1i0y1V6/SLeUi0eKEKdhQAlS8TVTI=

internal/gen/buf/validate/conformance/cases/bytes.pb.go

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

internal/gen/buf/validate/conformance/cases/bytes_protoopaque.pb.go

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

0 commit comments

Comments
 (0)