Skip to content

Commit

Permalink
feat: bump go to 1.23, adjust for new copyloopvar features
Browse files Browse the repository at this point in the history
  • Loading branch information
m4mm4r committed Nov 14, 2024
1 parent e7880d9 commit 6ffd1b2
Show file tree
Hide file tree
Showing 10 changed files with 31 additions and 39 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- name: Setup Sage
uses: einride/sage/actions/setup@master
with:
go-version: "1.20"
go-version: "1.23"

- name: Make
run: make
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
- name: Setup Sage
uses: einride/sage/actions/setup@master
with:
go-version: "1.20"
go-version: "1.23"

- name: Make
run: make
2 changes: 1 addition & 1 deletion .sage/go.mod
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module sage

go 1.17
go 1.23

require go.einride.tech/sage v0.328.0
2 changes: 0 additions & 2 deletions encoding/protoavro/encoding_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,6 @@ func Test_JSON(t *testing.T) {
},
},
} {
tt := tt
t.Run(tt.name, func(t *testing.T) {
// t.Parallel()
got, err := tt.opts.encodeJSON(tt.msg)
Expand Down Expand Up @@ -1114,7 +1113,6 @@ func Test_OmitRoot_JSON(t *testing.T) {
},
},
} {
tt := tt
t.Run(tt.name, func(t *testing.T) {
tt.opts = SchemaOptions{OmitRootElement: true}
// t.Parallel()
Expand Down
3 changes: 0 additions & 3 deletions encoding/protoavro/map_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,6 @@ func Test_MapSchema(t *testing.T) {
}),
},
} {
tt := tt
t.Run(tt.name, func(t *testing.T) {
schema, err := tt.opts.newSchemaInferrer().inferMapSchema(
tt.msg.ProtoReflect().Descriptor().Fields().ByName(tt.fieldName),
Expand Down Expand Up @@ -249,7 +248,6 @@ func Test_MapEncode(t *testing.T) {
},
},
} {
tt := tt
t.Run(tt.name, func(t *testing.T) {
desc := tt.msg.ProtoReflect().Descriptor().Fields().ByName(tt.fieldName)
val := tt.msg.ProtoReflect().Get(desc)
Expand Down Expand Up @@ -322,7 +320,6 @@ func Test_MapDecode(t *testing.T) {
expectErr: "missing 'value' in map entry for 'string_to_string'",
},
} {
tt := tt
t.Run(tt.name, func(t *testing.T) {
desc := tt.msg.ProtoReflect().Descriptor().Fields().ByName(tt.fieldName)
val := tt.msg.ProtoReflect().Mutable(desc)
Expand Down
1 change: 0 additions & 1 deletion encoding/protoavro/marshal_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ func Test_MarshalSymmetric(t *testing.T) {
},
},
} {
tt := tt
t.Run(tt.name, func(t *testing.T) {
var b bytes.Buffer

Expand Down
2 changes: 0 additions & 2 deletions encoding/protoavro/schema_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,6 @@ func TestInferSchema(t *testing.T) {
}),
},
} {
tt := tt
t.Run(tt.name, func(t *testing.T) {
t.Parallel()
got, err := InferSchema(tt.msg.ProtoReflect().Descriptor())
Expand Down Expand Up @@ -1116,7 +1115,6 @@ func TestInferRootSchema(t *testing.T) {
},
},
} {
tt := tt
t.Run(tt.name, func(t *testing.T) {
t.Parallel()
got, err := SchemaOptions{OmitRootElement: true}.InferSchema(tt.msg.ProtoReflect().Descriptor())
Expand Down
2 changes: 0 additions & 2 deletions encoding/protoavro/wkt_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ func Test_WKT(t *testing.T) {
durationpb.New(time.Microsecond),
durationpb.New(time.Minute*59 + time.Second*43),
} {
tt := tt
t.Run(string(tt.ProtoReflect().Descriptor().FullName()), func(t *testing.T) {
encoded, err := SchemaOptions{}.encodeWKT(tt.ProtoReflect())
assert.NilError(t, err)
Expand Down Expand Up @@ -139,7 +138,6 @@ func Test_DecodeWKTErr(t *testing.T) {
errContains: "google.type.TimeOfDay: expected key 'long.time-micros'",
},
} {
tt := tt
t.Run(tt.name, func(t *testing.T) {
err := decodeWKT(tt.data, tt.msg.ProtoReflect())
assert.ErrorContains(t, err, tt.errContains)
Expand Down
20 changes: 11 additions & 9 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,22 +1,24 @@
module go.einride.tech/protobuf-avro

go 1.20
go 1.23

toolchain go1.23.1

require (
cloud.google.com/go v0.115.1
cloud.google.com/go v0.116.0
github.com/google/go-cmp v0.6.0
github.com/linkedin/goavro/v2 v2.13.0
google.golang.org/genproto v0.0.0-20240730163845-b1a4ccb954bf
google.golang.org/genproto v0.0.0-20240903143218-8af14fe29dc1
google.golang.org/protobuf v1.34.2
gotest.tools/v3 v3.5.1
)

require (
github.com/golang/snappy v0.0.4 // indirect
golang.org/x/net v0.27.0 // indirect
golang.org/x/sys v0.22.0 // indirect
golang.org/x/text v0.16.0 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240725223205-93522f1f2a9f // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240730163845-b1a4ccb954bf // indirect
google.golang.org/grpc v1.64.1 // indirect
golang.org/x/net v0.29.0 // indirect
golang.org/x/sys v0.25.0 // indirect
golang.org/x/text v0.18.0 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 // indirect
google.golang.org/grpc v1.66.2 // indirect
)
34 changes: 17 additions & 17 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
cloud.google.com/go v0.115.1 h1:Jo0SM9cQnSkYfp44+v+NQXHpcHqlnRJk2qxh6yvxxxQ=
cloud.google.com/go v0.115.1/go.mod h1:DuujITeaufu3gL68/lOFIirVNJwQeyf5UXyi+Wbgknc=
cloud.google.com/go v0.116.0 h1:B3fRrSDkLRt5qSHWe40ERJvhvnQwdZiHu0bJOpldweE=
cloud.google.com/go v0.116.0/go.mod h1:cEPSRWPzZEswwdr9BxE6ChEn01dWlTaF05LiC2Xs70U=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
Expand All @@ -15,22 +15,22 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.5 h1:s5PTfem8p8EbKQOctVV53k6jCJt3UX4IEJzwh+C324Q=
github.com/stretchr/testify v1.7.5/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg=
golang.org/x/net v0.27.0 h1:5K3Njcw06/l2y9vpGCSdcxWOYHOUk3dVNGDXN+FvAys=
golang.org/x/net v0.27.0/go.mod h1:dDi0PyhWNoiUOrAS8uXv/vnScO4wnHQO4mj9fn/RytE=
golang.org/x/sys v0.22.0 h1:RI27ohtqKCnwULzJLqkv897zojh5/DwS/ENaMzUOaWI=
golang.org/x/sys v0.22.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/text v0.16.0 h1:a94ExnEXNtEwYLGJSIUxnWoxoRz/ZcCsV63ROupILh4=
golang.org/x/text v0.16.0/go.mod h1:GhwF1Be+LQoKShO3cGOHzqOgRrGaYc9AvblQOmPVHnI=
google.golang.org/genproto v0.0.0-20240730163845-b1a4ccb954bf h1:OqdXDEakZCVtDiZTjcxfwbHPCT11ycCEsTKesBVKvyY=
google.golang.org/genproto v0.0.0-20240730163845-b1a4ccb954bf/go.mod h1:mCr1K1c8kX+1iSBREvU3Juo11CB+QOEWxbRS01wWl5M=
google.golang.org/genproto/googleapis/api v0.0.0-20240725223205-93522f1f2a9f h1:b1Ln/PG8orm0SsBbHZWke8dDp2lrCD4jSmfglFpTZbk=
google.golang.org/genproto/googleapis/api v0.0.0-20240725223205-93522f1f2a9f/go.mod h1:AHT0dDg3SoMOgZGnZk29b5xTbPHMoEC8qthmBLJCpys=
google.golang.org/genproto/googleapis/rpc v0.0.0-20240730163845-b1a4ccb954bf h1:liao9UHurZLtiEwBgT9LMOnKYsHze6eA6w1KQCMVN2Q=
google.golang.org/genproto/googleapis/rpc v0.0.0-20240730163845-b1a4ccb954bf/go.mod h1:Ue6ibwXGpU+dqIcODieyLOcgj7z8+IcskoNIgZxtrFY=
google.golang.org/grpc v1.64.1 h1:LKtvyfbX3UGVPFcGqJ9ItpVWW6oN/2XqTxfAnwRRXiA=
google.golang.org/grpc v1.64.1/go.mod h1:hiQF4LFZelK2WKaP6W0L92zGHtiQdZxk8CrSdvyjeP0=
golang.org/x/net v0.29.0 h1:5ORfpBpCs4HzDYoodCDBbwHzdR5UrLBZ3sOnUJmFoHo=
golang.org/x/net v0.29.0/go.mod h1:gLkgy8jTGERgjzMic6DS9+SP0ajcu6Xu3Orq/SpETg0=
golang.org/x/sys v0.25.0 h1:r+8e+loiHxRqhXVl6ML1nO3l1+oFoWbnlu2Ehimmi34=
golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/text v0.18.0 h1:XvMDiNzPAl0jr17s6W9lcaIhGUfUORdGCNsuLmPG224=
golang.org/x/text v0.18.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY=
google.golang.org/genproto v0.0.0-20240903143218-8af14fe29dc1 h1:BulPr26Jqjnd4eYDVe+YvyR7Yc2vJGkO5/0UxD0/jZU=
google.golang.org/genproto v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:hL97c3SYopEHblzpxRL4lSs523++l8DYxGM1FQiYmb4=
google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1 h1:hjSy6tcFQZ171igDaN5QHOw2n6vx40juYbC/x67CEhc=
google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:qpvKtACPCQhAdu3PyQgV4l3LMXZEtft7y8QcarRsp9I=
google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 h1:pPJltXNxVzT4pK9yD8vR9X75DaWYYmLGMsEvBfFQZzQ=
google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:UqMtugtsSgubUsoxbuAoiCXvqvErP7Gf0so0mK9tHxU=
google.golang.org/grpc v1.66.2 h1:3QdXkuq3Bkh7w+ywLdLvM56cmGvQHUMZpiCzt6Rqaoo=
google.golang.org/grpc v1.66.2/go.mod h1:s3/l6xSSCURdVfAnL+TqCNMyTDAGN6+lZeVxnZR128Y=
google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg=
google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
Expand Down

0 comments on commit 6ffd1b2

Please sign in to comment.