From 4330d606fda4d8e1962c511f91e5c90dd19f21c3 Mon Sep 17 00:00:00 2001 From: Tom van der Woerdt Date: Thu, 3 Oct 2024 11:01:55 +0100 Subject: [PATCH] encoding/protobuf: update txtpbfmt dependency The API changed in a backwards incompatible way, so we need to update to ensure compatibility with other modules sharing the same dependency. Closes #3475 as merged as of commit 60c93013. Signed-off-by: Tom van der Woerdt Change-Id: Ieb60adf19acc04b950ff1b7fb0a303d1be15552b Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1202171 TryBot-Result: CUEcueckoo Unity-Result: CUE porcuepine Reviewed-by: Roger Peppe --- encoding/protobuf/textproto/decoder.go | 2 +- go.mod | 2 +- go.sum | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/encoding/protobuf/textproto/decoder.go b/encoding/protobuf/textproto/decoder.go index d8962bef66f..01f63efc160 100644 --- a/encoding/protobuf/textproto/decoder.go +++ b/encoding/protobuf/textproto/decoder.go @@ -393,7 +393,7 @@ func (d *decoder) decodeValue(f *fieldInfo, n *pbast.Node) (x ast.Expr) { switch f.ValueType { case pbinternal.String, pbinternal.Bytes: - s, err := unquote.Unquote(n) + s, _, err := unquote.Unquote(n) if err != nil { d.addErrf(n.Start, "invalid string or bytes: %v", err) } diff --git a/go.mod b/go.mod index e122fac8bd5..9ceaf184476 100644 --- a/go.mod +++ b/go.mod @@ -14,7 +14,7 @@ require ( github.com/opencontainers/go-digest v1.0.0 github.com/opencontainers/image-spec v1.1.0 github.com/pelletier/go-toml/v2 v2.2.3 - github.com/protocolbuffers/txtpbfmt v0.0.0-20230328191034-3462fbc510c0 + github.com/protocolbuffers/txtpbfmt v0.0.0-20240823084532-8e6b51fa9bef github.com/rogpeppe/go-internal v1.13.1 github.com/spf13/cobra v1.8.1 github.com/spf13/pflag v1.0.5 diff --git a/go.sum b/go.sum index 6f3c65084af..88d029701f8 100644 --- a/go.sum +++ b/go.sum @@ -37,8 +37,8 @@ github.com/pelletier/go-toml/v2 v2.2.3/go.mod h1:MfCQTFTvCcUyyvvwm1+G6H/jORL20Xl github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/protocolbuffers/txtpbfmt v0.0.0-20230328191034-3462fbc510c0 h1:sadMIsgmHpEOGbUs6VtHBXRR1OHevnj7hLx9ZcdNGW4= -github.com/protocolbuffers/txtpbfmt v0.0.0-20230328191034-3462fbc510c0/go.mod h1:jgxiZysxFPM+iWKwQwPR+y+Jvo54ARd4EisXxKYpB5c= +github.com/protocolbuffers/txtpbfmt v0.0.0-20240823084532-8e6b51fa9bef h1:ej+64jiny5VETZTqcc1GFVAPEtaSk6U1D0kKC2MS5Yc= +github.com/protocolbuffers/txtpbfmt v0.0.0-20240823084532-8e6b51fa9bef/go.mod h1:jgxiZysxFPM+iWKwQwPR+y+Jvo54ARd4EisXxKYpB5c= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/rogpeppe/go-internal v1.13.1 h1:KvO1DLK/DRN07sQ1LQKScxyZJuNnedQ5/wKSR38lUII= github.com/rogpeppe/go-internal v1.13.1/go.mod h1:uMEvuHeurkdAXX61udpOXGD/AzZDWNMNyH2VO9fmH0o=