Skip to content

Commit

Permalink
Update to go1.20 (prysmaticlabs#12333)
Browse files Browse the repository at this point in the history
* Update to go1.20

* Update gohashtree

* fix build tags for bytesutil and add nilness exclusion

* more broad nilness exclusion

* Reset nogo config

* Update golang.org/x/tools

* update rules_go to 0.39.0

---------

Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
  • Loading branch information
prestonvanloon and prylabs-bulldozer[bot] authored Apr 27, 2023
1 parent cec631d commit 7dffee1
Show file tree
Hide file tree
Showing 7 changed files with 117 additions and 105 deletions.
8 changes: 4 additions & 4 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,10 @@ http_archive(
# Expose internals of go_test for custom build transitions.
"//third_party:io_bazel_rules_go_test.patch",
],
sha256 = "dd926a88a564a9246713a9c00b35315f54cbd46b31a26d5d8fb264c07045f05d",
sha256 = "6b65cb7917b4d1709f9410ffe00ecf3e160edf674b78c54a894471320862184f",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.38.1/rules_go-v0.38.1.zip",
"https://github.com/bazelbuild/rules_go/releases/download/v0.38.1/rules_go-v0.38.1.zip",
"https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.39.0/rules_go-v0.39.0.zip",
"https://github.com/bazelbuild/rules_go/releases/download/v0.39.0/rules_go-v0.39.0.zip",
],
)

Expand Down Expand Up @@ -164,7 +164,7 @@ load("@io_bazel_rules_go//go:deps.bzl", "go_register_toolchains", "go_rules_depe
go_rules_dependencies()

go_register_toolchains(
go_version = "1.19.8",
go_version = "1.20.3",
nogo = "@//:nogo",
)

Expand Down
155 changes: 83 additions & 72 deletions deps.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,12 @@ def prysm_deps():
sum = "h1:pv34s756C4pEXnjgPfGYgdhg/ZdajGhyOvzx8k+23nw=",
version = "v0.0.0-20170710044230-e206f873d14a",
)
go_repository(
name = "com_github_asaskevich_govalidator",
importpath = "github.com/asaskevich/govalidator",
sum = "h1:idn718Q4B6AGu/h5Sxe66HYVdqdGu2l9Iebqhi/AEoA=",
version = "v0.0.0-20190424111038-f61b66f89f4a",
)

go_repository(
name = "com_github_aws_aws_lambda_go",
Expand Down Expand Up @@ -281,42 +287,48 @@ def prysm_deps():
sum = "h1:Px2UA+2RvSSvv+RvJNuUB6n7rs5Wsel4dXLe90Um2n4=",
version = "v0.3.0",
)
go_repository(
name = "com_github_azure_go_autorest",
importpath = "github.com/Azure/go-autorest",
sum = "h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=",
version = "v14.2.0+incompatible",
)

go_repository(
name = "com_github_azure_go_autorest_autorest",
importpath = "github.com/Azure/go-autorest/autorest",
sum = "h1:MRvx8gncNaXJqOoLmhNjUAKh33JJF8LyxPhomEtOsjs=",
version = "v0.9.0",
sum = "h1:eVvIXUKiTgv++6YnWb42DUA1YL7qDugnKP0HljexdnQ=",
version = "v0.11.1",
)
go_repository(
name = "com_github_azure_go_autorest_autorest_adal",
importpath = "github.com/Azure/go-autorest/autorest/adal",
sum = "h1:q2gDruN08/guU9vAjuPWff0+QIrpH6ediguzdAzXAUU=",
version = "v0.5.0",
sum = "h1:Y3bBUV4rTuxenJJs41HU3qmqsb+auo+a3Lz+PlJPpL0=",
version = "v0.9.5",
)
go_repository(
name = "com_github_azure_go_autorest_autorest_date",
importpath = "github.com/Azure/go-autorest/autorest/date",
sum = "h1:YGrhWfrgtFs84+h0o46rJrlmsZtyZRg470CqAXTZaGM=",
version = "v0.1.0",
sum = "h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=",
version = "v0.3.0",
)
go_repository(
name = "com_github_azure_go_autorest_autorest_mocks",
importpath = "github.com/Azure/go-autorest/autorest/mocks",
sum = "h1:Ww5g4zThfD/6cLb4z6xxgeyDa7QDkizMkJKe0ysZXp0=",
version = "v0.2.0",
sum = "h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=",
version = "v0.4.1",
)
go_repository(
name = "com_github_azure_go_autorest_logger",
importpath = "github.com/Azure/go-autorest/logger",
sum = "h1:ruG4BSDXONFRrZZJ2GUXDiUyVpayPmb1GnWeHDdaNKY=",
version = "v0.1.0",
sum = "h1:e4RVHVZKC5p6UANLJHkM4OfR1UKZPj8Wt8Pcx+3oqrE=",
version = "v0.2.0",
)
go_repository(
name = "com_github_azure_go_autorest_tracing",
importpath = "github.com/Azure/go-autorest/tracing",
sum = "h1:TRn4WjSnkcSy5AEG3pnbtFSwNtwzjr4VYyQflFE619k=",
version = "v0.5.0",
sum = "h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=",
version = "v0.6.0",
)
go_repository(
name = "com_github_bazelbuild_rules_go",
Expand Down Expand Up @@ -837,6 +849,12 @@ def prysm_deps():
sum = "h1:cenwrSVm+Z7QLSV/BsnenAOcDXdX4cMv4wP0B/5QbPg=",
version = "v0.0.0-20160310174837-449fdfce4d96",
)
go_repository(
name = "com_github_docopt_docopt_go",
importpath = "github.com/docopt/docopt-go",
sum = "h1:bWDMxwH3px2JBh6AyO7hdCn/PkvCZXii8TGj7sbtEbQ=",
version = "v0.0.0-20180111231733-ee0de3bc6815",
)

go_repository(
name = "com_github_dop251_goja",
Expand Down Expand Up @@ -971,8 +989,8 @@ def prysm_deps():
go_repository(
name = "com_github_evanphx_json_patch",
importpath = "github.com/evanphx/json-patch",
sum = "h1:fUDGZCv/7iAN7u0puUVhvKCcsR6vRfwrJatElLBEf0I=",
version = "v4.2.0+incompatible",
sum = "h1:kLcOMZeuLAJvL2BPWLMIj5oaZQobrkAqrL+WFZwQses=",
version = "v4.9.0+incompatible",
)
go_repository(
name = "com_github_fasthttp_contrib_websocket",
Expand Down Expand Up @@ -1040,6 +1058,12 @@ def prysm_deps():
sum = "h1:WXb3TSNmHp2vHoCroCIB1foO/yQ36swABL8aOVeDpgg=",
version = "v1.2.1-0.20190220221249-0403632d5b90",
)
go_repository(
name = "com_github_form3tech_oss_jwt_go",
importpath = "github.com/form3tech-oss/jwt-go",
sum = "h1:TcekIExNqud5crz4xD2pavyTgWiPvpYe4Xau31I0PRk=",
version = "v3.2.2+incompatible",
)

go_repository(
name = "com_github_fortytw2_leaktest",
Expand Down Expand Up @@ -1262,14 +1286,14 @@ def prysm_deps():
go_repository(
name = "com_github_go_openapi_jsonreference",
importpath = "github.com/go-openapi/jsonreference",
sum = "h1:tF+augKRWlWx0J0B7ZyyKSiTyV6E1zZe+7b3qQlcEf8=",
version = "v0.0.0-20160704190145-13c6e3589ad9",
sum = "h1:5cxNfTy0UVC3X8JL5ymxzyoUZmo8iZb+jeTWn7tUa8o=",
version = "v0.19.3",
)
go_repository(
name = "com_github_go_openapi_spec",
importpath = "github.com/go-openapi/spec",
sum = "h1:C1JKChikHGpXwT5UQDFaryIpDtyyGL/CR6C2kB7F1oc=",
version = "v0.0.0-20160808142527-6aced65f8501",
sum = "h1:0XRyw8kguri6Yw4SxhsQA/atC88yqrk0+G4YhI2wabc=",
version = "v0.19.3",
)
go_repository(
name = "com_github_go_openapi_swag",
Expand Down Expand Up @@ -1580,15 +1604,10 @@ def prysm_deps():
],
build_naming_convention = "go_default_library",
importpath = "github.com/googleapis/gnostic",
sum = "h1:rVsPeBmXbYv4If/cumu1AzZPwV58q433hvONV1UEZoI=",
version = "v0.1.0",
)
go_repository(
name = "com_github_gophercloud_gophercloud",
importpath = "github.com/gophercloud/gophercloud",
sum = "h1:P/nh25+rzXouhytV2pUHBb65fnds26Ghl8/391+sT5o=",
version = "v0.1.0",
sum = "h1:DLJCy1n/vrD4HPjOvYcT8aYQXpPIzoRZONaYwyycI+I=",
version = "v0.4.1",
)

go_repository(
name = "com_github_gopherjs_gopherjs",
importpath = "github.com/gopherjs/gopherjs",
Expand Down Expand Up @@ -2358,8 +2377,8 @@ def prysm_deps():
go_repository(
name = "com_github_kr_pty",
importpath = "github.com/kr/pty",
sum = "h1:/Um6a/ZmD5tF7peoOJ5oN5KMQ0DrGVQSXLNwyckutPk=",
version = "v1.1.3",
sum = "h1:hyz3dwM5QLc1Rfoz4FuWJQG5BN7tc6K1MndAUnGpQr4=",
version = "v1.1.5",
)
go_repository(
name = "com_github_kr_text",
Expand Down Expand Up @@ -3284,8 +3303,8 @@ def prysm_deps():
go_repository(
name = "com_github_prysmaticlabs_gohashtree",
importpath = "github.com/prysmaticlabs/gohashtree",
sum = "h1:hk5ZsDQuSkyUMhTd55qB396P1+dtyIKiSwMmYE/hyEU=",
version = "v0.0.2-alpha",
sum = "h1:1EVinCWdb3Lorq7xn8DYQHf48nCcdAM3Vb18KsFlRWY=",
version = "v0.0.3-alpha",
)

go_repository(
Expand All @@ -3304,14 +3323,14 @@ def prysm_deps():
go_repository(
name = "com_github_puerkitobio_purell",
importpath = "github.com/PuerkitoBio/purell",
sum = "h1:0GoNN3taZV6QI81IXgCbxMyEaJDXMSIjArYBCYzVVvs=",
version = "v1.0.0",
sum = "h1:WEQqlqaGbrPkxLJWfBwQmfEAE1Z7ONdDLqrN38tNFfI=",
version = "v1.1.1",
)
go_repository(
name = "com_github_puerkitobio_urlesc",
importpath = "github.com/PuerkitoBio/urlesc",
sum = "h1:JCHLVE3B+kJde7bIEo5N4J+ZbLhp0J1Fs+ulyRws4gE=",
version = "v0.0.0-20160726150825-5bd2802263f2",
sum = "h1:d+Bc7a5rLufV/sSk/8dngufqelfh6jnri85riMAaF/M=",
version = "v0.0.0-20170810143723-de5bf2ad4578",
)
go_repository(
name = "com_github_quic_go_qpack",
Expand Down Expand Up @@ -3356,7 +3375,6 @@ def prysm_deps():
build_directives = [
"gazelle:exclude mockgen.go",
"gazelle:exclude tools.go",
"gazelle:exclude internal/qtls/go120.go", # Disabled until go1.20 is supported in Prysm.
],
importpath = "github.com/quic-go/quic-go",
sum = "h1:ItNoTDN/Fm/zBlq769lLJc8ECe9gYaW40veHCCco7y0=",
Expand Down Expand Up @@ -3899,8 +3917,8 @@ def prysm_deps():
go_repository(
name = "com_github_trailofbits_go_mutexasserts",
importpath = "github.com/trailofbits/go-mutexasserts",
sum = "h1:8LRP+2JK8piIUU16ZDgWDXwjJcuJNTtCzadjTZj8Jf0=",
version = "v0.0.0-20200708152505-19999e7d3cef",
sum = "h1:+LynomhWB+14Plp/bOONEAZCtvCZk4leRbTvNzNVkL0=",
version = "v0.0.0-20230328101604-8cdbc5f3d279",
)
go_repository(
name = "com_github_twitchtv_twirp",
Expand Down Expand Up @@ -4474,37 +4492,31 @@ def prysm_deps():
name = "io_k8s_api",
build_file_proto_mode = "disable_global",
importpath = "k8s.io/api",
sum = "h1:2AJaUQdgUZLoDZHrun21PW2Nx9+ll6cUzvn3IKhSIn0=",
version = "v0.18.3",
sum = "h1:WwrYoZNM1W1aQEbyl8HNG+oWGzLpZQBlcerS9BQw9yI=",
version = "v0.20.0",
)
go_repository(
name = "io_k8s_apimachinery",
build_file_proto_mode = "disable_global",
importpath = "k8s.io/apimachinery",
sum = "h1:pOGcbVAhxADgUYnjS08EFXs9QMl8qaH5U4fr5LGUrSk=",
version = "v0.18.3",
sum = "h1:jjzbTJRXk0unNS71L7h3lxGDH/2HPxMPaQY+MjECKL8=",
version = "v0.20.0",
)
go_repository(
name = "io_k8s_client_go",
build_extra_args = ["-exclude=vendor"],
build_naming_convention = "go_default_library",
importpath = "k8s.io/client-go",
sum = "h1:QaJzz92tsN67oorwzmoB0a9r9ZVHuD5ryjbCKP0U22k=",
version = "v0.18.3",
sum = "h1:Xlax8PKbZsjX4gFvNtt4F5MoJ1V5prDvCuoq9B7iax0=",
version = "v0.20.0",
)
go_repository(
name = "io_k8s_gengo",
importpath = "k8s.io/gengo",
sum = "h1:4s3/R4+OYYYUKptXPhZKjQ04WJ6EhQQVFdjOFvCazDk=",
version = "v0.0.0-20190128074634-0689ccc1d7d6",
sum = "h1:sAvhNk5RRuc6FNYGqe7Ygz3PSo/2wGWbulskmzRX8Vs=",
version = "v0.0.0-20200413195148-3a45101e95ac",
)

go_repository(
name = "io_k8s_klog",
importpath = "k8s.io/klog",
sum = "h1:Pt+yjF5aB1xDSVbau4VsWe+dQNzA0qv1LlXdC2dF6Q8=",
version = "v1.0.0",
)
go_repository(
name = "io_k8s_klog_v2",
importpath = "k8s.io/klog/v2",
Expand All @@ -4514,15 +4526,14 @@ def prysm_deps():
go_repository(
name = "io_k8s_kube_openapi",
importpath = "k8s.io/kube-openapi",
sum = "h1:Oh3Mzx5pJ+yIumsAD0MOECPVeXsVot0UkiaCGVyfGQY=",
version = "v0.0.0-20200410145947-61e04a5be9a6",
sum = "h1:sOHNzJIkytDF6qadMNKhhDRpc6ODik8lVC6nOur7B2c=",
version = "v0.0.0-20201113171705-d219536bb9fd",
)

go_repository(
name = "io_k8s_sigs_structured_merge_diff_v3",
importpath = "sigs.k8s.io/structured-merge-diff/v3",
sum = "h1:dOmIZBMfhcHS09XZkMyUgkq5trg3/jRyJYFZUiaOp8E=",
version = "v3.0.0",
name = "io_k8s_sigs_structured_merge_diff_v4",
importpath = "sigs.k8s.io/structured-merge-diff/v4",
sum = "h1:YHQV7Dajm86OuqnIR6zAelnDWBRjo+YhYV9PmGrh1s8=",
version = "v4.0.2",
)

go_repository(
Expand All @@ -4534,8 +4545,8 @@ def prysm_deps():
go_repository(
name = "io_k8s_utils",
importpath = "k8s.io/utils",
sum = "h1:ZtTUW5+ZWaoqjR3zOpRa7oFJ5d4aA22l4me/xArfOIc=",
version = "v0.0.0-20200520001619-278ece378a50",
sum = "h1:CbnUZsM497iRC5QMVkHwyl8s2tB3g7yaSHkYPkpgelw=",
version = "v0.0.0-20201110183641-67b214c5f920",
)
go_repository(
name = "io_nhooyr_websocket",
Expand Down Expand Up @@ -4701,15 +4712,15 @@ def prysm_deps():
go_repository(
name = "org_golang_x_mod",
importpath = "golang.org/x/mod",
sum = "h1:LUYupSeNrTNCGzR/hVBk2NHZO4hXcVaW1k4Qx7rjPx8=",
version = "v0.8.0",
sum = "h1:lFO9qtOdlre5W1jxS3r/4szv2/6iXxScdzjoBMXNhYk=",
version = "v0.10.0",
)

go_repository(
name = "org_golang_x_net",
importpath = "golang.org/x/net",
sum = "h1:rJrUqqhjsgNp7KqAIc25s9pZnjU7TUcSY7HcVZjdn1g=",
version = "v0.7.0",
sum = "h1:aWJ/m6xSmxWBx+V0XRHTlrYrPG56jKsLdTFmsSsCzOM=",
version = "v0.9.0",
)
go_repository(
name = "org_golang_x_oauth2",
Expand All @@ -4733,21 +4744,21 @@ def prysm_deps():
go_repository(
name = "org_golang_x_sys",
importpath = "golang.org/x/sys",
sum = "h1:MUK/U/4lj1t1oPg0HfuXDN/Z1wv31ZJ/YcPiGccS4DU=",
version = "v0.5.0",
sum = "h1:3jlCCIQZPdOYu1h8BkNvLz8Kgwtae2cagcG/VamtZRU=",
version = "v0.7.0",
)
go_repository(
name = "org_golang_x_term",
importpath = "golang.org/x/term",
sum = "h1:n2a8QNdAb0sZNpU9R1ALUXBbY+w51fCQDN+7EdxNBsY=",
version = "v0.5.0",
sum = "h1:BEvjmm5fURWqcfbSKTdpkDXYBrUS1c0m8agp14W48vQ=",
version = "v0.7.0",
)

go_repository(
name = "org_golang_x_text",
importpath = "golang.org/x/text",
sum = "h1:4BRB4x83lYWy72KwLD/qYDuTu7q9PjSagHvijDw7cLo=",
version = "v0.7.0",
sum = "h1:2sjJmO8cDvYveuX97RDLsxlyUxLl+GHoLxBiRdHllBE=",
version = "v0.9.0",
)
go_repository(
name = "org_golang_x_time",
Expand All @@ -4758,8 +4769,8 @@ def prysm_deps():
go_repository(
name = "org_golang_x_tools",
importpath = "golang.org/x/tools",
sum = "h1:BOw41kyTf3PuCW1pVQf8+Cyg8pMlkYB1oo9iJ6D/lKM=",
version = "v0.6.0",
sum = "h1:vSDcovVPld282ceKgDimkRSC8kpaH1dgyc9UMzlt84Y=",
version = "v0.8.0",
)

go_repository(
Expand Down
1 change: 1 addition & 0 deletions encoding/bytesutil/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ go_library(
srcs = [
"bits.go",
"bytes.go",
"bytes_go120.go",
"bytes_legacy.go",
"eth_types.go",
"hex.go",
Expand Down
4 changes: 2 additions & 2 deletions encoding/bytesutil/bytes_go120.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//go:build prysmAt1.20
// +build prysmAt1.20
//go:build go1.20
// +build go1.20

package bytesutil

Expand Down
4 changes: 2 additions & 2 deletions encoding/bytesutil/bytes_legacy.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//go:build !prysmAt1.20
// +build !prysmAt1.20
//go:build !go1.20
// +build !go1.20

package bytesutil

Expand Down
Loading

0 comments on commit 7dffee1

Please sign in to comment.