Skip to content

Commit

Permalink
Update release/1.1.0 branch for Go 1.14.x (ethereum#1222) (ethereum#1226
Browse files Browse the repository at this point in the history
)

* go.mod: update golang.org/x/crypto to fix a Go 1.14 race rejection

Cherry-pick conflicts:
  go.mod
  go.sum

* p2p/discv5: fix test on go 1.14 (ethereum#20724)

Cherry-picked to celo-blockchain

* travis, appveyor, build, Dockerfile: bump Go to 1.14.2 (ethereum#20913)

* travis, appveyor, build, Dockerfile: bump Go to 1.14.2

* travis, appveyor: force GO111MODULE=on for every build

Cherry-pick conflicts:
  .travis.yml
  appveyor.yml
  build/checksums.txt

* Update CircleCI and dockerfiles to use Go 1.14

* Revert ios build CI config to work with Go 1.13

* Update golang download links to 1.14.12

Co-authored-by: Péter Szilágyi <[email protected]>
Co-authored-by: Felix Lange <[email protected]>

Co-authored-by: Péter Szilágyi <[email protected]>
Co-authored-by: Felix Lange <[email protected]>
  • Loading branch information
3 people authored Nov 13, 2020
1 parent c767f8c commit bd6a4a4
Show file tree
Hide file tree
Showing 14 changed files with 56 additions and 28 deletions.
6 changes: 3 additions & 3 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ version: 2.1
executors:
golang:
docker:
- image: circleci/golang:1.13
- image: circleci/golang:1.14
working_directory: ~/repos/geth
e2e:
docker:
- image: celohq/node10-gcloud:v3
working_directory: ~/repos/celo-monorepo/packages/celotool
environment:
GO_VERSION: "1.13.7"
GO_VERSION: "1.14.12"
CELO_MONOREPO_BRANCH_TO_TEST: master
GITHUB_RSA_FINGERPRINT: SHA256:nThbg6kXUpJWGl7E1IGOCspRomTxdCARLviKw6E5SY8
jobs:
Expand Down Expand Up @@ -108,7 +108,7 @@ jobs:
command: |
HOMEBREW_NO_AUTO_UPDATE=1 brew install go
# Check that homebrew installed the expected go version
if [[ "$(go version)" != "go version go1.13"* ]]; then
if [[ "$(go version)" != "go version go1.13"* ]]; then
echo "go1.13 is required"
exit 1
fi
Expand Down
44 changes: 33 additions & 11 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
- stage: lint
os: linux
dist: xenial
go: 1.13.x
go: 1.14.x
env:
- lint
git:
Expand All @@ -25,12 +25,24 @@ jobs:
- go run build/ci.go install
- go run build/ci.go test -coverage $TEST_PACKAGES

- stage: build
os: linux
dist: xenial
go: 1.13.x
env:
- GO111MODULE=on
script:
- go run build/ci.go install
- go run build/ci.go test -coverage $TEST_PACKAGES

# These are the latest Go versions.
- stage: build
os: linux
arch: amd64
dist: xenial
go: 1.13.x
go: 1.14.x
env:
- GO111MODULE=on
script:
- go run build/ci.go install
- go run build/ci.go test -coverage $TEST_PACKAGES
Expand All @@ -40,15 +52,19 @@ jobs:
os: linux
arch: arm64
dist: xenial
go: 1.13.x
go: 1.14.x
env:
- GO111MODULE=on
script:
- go run build/ci.go install
- go run build/ci.go test -coverage $TEST_PACKAGES

- stage: build
os: osx
osx_image: xcode11.3
go: 1.13.x
go: 1.14.x
env:
- GO111MODULE=on
script:
- echo "Increase the maximum number of open file descriptors on macOS"
- NOFILE=20480
Expand All @@ -67,9 +83,10 @@ jobs:
if: type = push
os: linux
dist: xenial
go: 1.13.x
go: 1.14.x
env:
- ubuntu-ppa
- GO111MODULE=on
git:
submodules: false # avoid cloning ethereum/tests
addons:
Expand All @@ -83,17 +100,18 @@ jobs:
- python-paramiko
script:
- echo '|1|7SiYPr9xl3uctzovOTj4gMwAC1M=|t6ReES75Bo/PxlOPJ6/GsGbTrM0= ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEA0aKz5UTUndYgIGG7dQBV+HaeuEZJ2xPHo2DS2iSKvUL4xNMSAY4UguNW+pX56nAQmZKIZZ8MaEvSj6zMEDiq6HFfn5JcTlM80UwlnyKe8B8p7Nk06PPQLrnmQt5fh0HmEcZx+JU9TZsfCHPnX7MNz4ELfZE6cFsclClrKim3BHUIGq//t93DllB+h4O9LHjEUsQ1Sr63irDLSutkLJD6RXchjROXkNirlcNVHH/jwLWR5RcYilNX7S5bIkK8NlWPjsn/8Ua5O7I9/YoE97PpO6i73DTGLh5H9JN/SITwCKBkgSDWUt61uPK3Y11Gty7o2lWsBjhBUm2Y38CBsoGmBw==' >> ~/.ssh/known_hosts
- go run build/ci.go debsrc -goversion 1.13.6 -upload ethereum/ethereum -sftp-user geth-ci -signer "Go Ethereum Linux Builder <[email protected]>"
- go run build/ci.go debsrc -goversion 1.14.2 -upload ethereum/ethereum -sftp-user geth-ci -signer "Go Ethereum Linux Builder <[email protected]>"

# This builder does the Linux Azure uploads
- stage: build
if: type = push
os: linux
dist: xenial
sudo: required
go: 1.13.x
go: 1.14.x
env:
- azure-linux
- GO111MODULE=on
git:
submodules: false # avoid cloning ethereum/tests
addons:
Expand Down Expand Up @@ -127,9 +145,10 @@ jobs:
dist: xenial
services:
- docker
go: 1.13.x
go: 1.14.x
env:
- azure-linux-mips
- GO111MODULE=on
git:
submodules: false # avoid cloning ethereum/tests
script:
Expand Down Expand Up @@ -170,10 +189,11 @@ jobs:
env:
- azure-android
- maven-android
- GO111MODULE=on
git:
submodules: false # avoid cloning ethereum/tests
before_install:
- curl https://dl.google.com/go/go1.13.6.linux-amd64.tar.gz | tar -xz
- curl https://dl.google.com/go/go1.14.2.linux-amd64.tar.gz | tar -xz
- export PATH=`pwd`/go/bin:$PATH
- export GOROOT=`pwd`/go
- export GOPATH=$HOME/go
Expand All @@ -191,11 +211,12 @@ jobs:
- stage: build
if: type = push
os: osx
go: 1.13.x
go: 1.14.x
env:
- azure-osx
- azure-ios
- cocoapods-ios
- GO111MODULE=on
git:
submodules: false # avoid cloning ethereum/tests
script:
Expand All @@ -222,9 +243,10 @@ jobs:
if: type = cron
os: linux
dist: xenial
go: 1.13.x
go: 1.14.x
env:
- azure-purge
- GO111MODULE=on
git:
submodules: false # avoid cloning ethereum/tests
script:
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
# To use this image for testing, modify GETH_NODE_DOCKER_IMAGE_TAG in celo-monorepo/.env file

# Build Geth in a stock Go builder container
FROM golang:1.13-alpine as builder
FROM golang:1.14-alpine as builder

RUN apk add --no-cache make gcc musl-dev linux-headers git

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.alltools
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Build Geth in a stock Go builder container
FROM golang:1.13-alpine as builder
FROM golang:1.14-alpine as builder

RUN apk add --no-cache make gcc musl-dev linux-headers git

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.android
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ RUN rustup target add x86_64-linux-android
# go and node installations command expect to run as root
USER root

RUN curl https://dl.google.com/go/go1.13.5.linux-amd64.tar.gz | tar -xz
RUN curl https://dl.google.com/go/go1.14.12.linux-amd64.tar.gz | tar -xz
ENV PATH=/go/bin:$PATH
ENV GOROOT=/go
ENV GOPATH=$HOME/go
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile.arm64
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ RUN apt update && \
rm -rf /var/lib/apt/lists/*

RUN rustup target add aarch64-unknown-linux-gnu
RUN wget https://dl.google.com/go/go1.13.5.linux-amd64.tar.gz && \
tar xf go1.13.5.linux-amd64.tar.gz -C /usr/local
RUN wget https://dl.google.com/go/go1.14.12.linux-amd64.tar.gz && \
tar xf go1.14.12.linux-amd64.tar.gz -C /usr/local

COPY . /go-ethereum
WORKDIR /go-ethereum
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.binaries
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
# In the CI flow these are then uploaded to cloud storage as artefacts.

# Build Geth binaries in the xgo builder container
FROM techknowlogick/xgo:go-1.13.x
FROM techknowlogick/xgo:go-1.14.x
# techknowlogic/xgo is a fork of karalabe/xgo updated to ubunut-18, it is more maintained
# by the community and allows us to backport mingw in order to build for windows
# See discussion in PR celo-blockchain#<number> about downsides of this image
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Most functionality of this client is similar to `go-ethereum`, also known as `ge

## Building the source

Building `geth` requires both a Go (version 1.13) and a C compiler.
Building `geth` requires both a Go (version 1.14) and a C compiler.
You can install them using your favourite package manager. Once the dependencies are installed, run

```shell
Expand Down
5 changes: 3 additions & 2 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ clone_depth: 5
version: "{branch}.{build}"
environment:
global:
GO111MODULE: on
GOPATH: C:\gopath
CC: gcc.exe
matrix:
Expand All @@ -23,8 +24,8 @@ environment:
install:
- git submodule update --init
- rmdir C:\go /s /q
- appveyor DownloadFile https://dl.google.com/go/go1.13.6.windows-%GETH_ARCH%.zip
- 7z x go1.13.6.windows-%GETH_ARCH%.zip -y -oC:\ > NUL
- appveyor DownloadFile https://dl.google.com/go/go1.14.2.windows-%GETH_ARCH%.zip
- 7z x go1.14.2.windows-%GETH_ARCH%.zip -y -oC:\ > NUL
- go version
- gcc --version

Expand Down
2 changes: 1 addition & 1 deletion build/checksums.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This file contains sha256 checksums of optional build dependencies.

aae5be954bdc40bcf8006eb77e8d8a5dde412722bc8effcdaf9772620d06420c go1.13.6.src.tar.gz
98de84e69726a66da7b4e58eac41b99cbe274d7e8906eeb8a5b7eb0aadee7f7c go1.14.2.src.tar.gz

1fcbc9e36f4319eeed02beb8cfd1b3d425ffc2f90ddf09a80f18d5064c51e0cb golangci-lint-1.21.0-linux-386.tar.gz
267b4066e67139a38d29499331a002d6a29ad5be7aafc83db3b1e88f1b027f90 golangci-lint-1.21.0-linux-armv6.tar.gz
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/_developers/devguide.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ These early PRs should indicate 'in progress' status.

## Building and Testing

We assume that you have Go installed. Please use Go version 1.13 or later. We use the gc
We assume that you have Go installed. Please use Go version 1.14 or later. We use the gc
toolchain for development, which you can get from the [Go downloads page][go-install].

go-ethereum is a Go module, and uses the [Go modules system][go-modules] to manage
Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,9 @@ require (
github.com/syndtr/goleveldb v1.0.1-0.20190923125748-758128399b1d
github.com/tyler-smith/go-bip39 v1.0.1-0.20181017060643-dbb3b84ba2ef
github.com/wsddn/go-ecdh v0.0.0-20161211032359-48726bab9208
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550
golang.org/x/crypto v0.0.0-20200311171314-f7b00557c8c4
golang.org/x/mobile v0.0.0-20200801112145-973feb4309de // indirect
golang.org/x/net v0.0.0-20190628185345-da137c7871d7 // indirect
golang.org/x/net v0.0.0-20200301022130-244492dfa37a // indirect
golang.org/x/sync v0.0.0-20190423024810-112230192c58
golang.org/x/sys v0.0.0-20200519105757-fe76b779f299
golang.org/x/text v0.3.2
Expand Down
5 changes: 5 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,8 @@ golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACk
golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550 h1:ObdrDkeb4kJdCP557AjRjq69pTHfNouLtWZG7j9rPN8=
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20200311171314-f7b00557c8c4 h1:QmwruyY+bKbDDL0BaglrbZABEali68eoMFhTZpCjYVA=
golang.org/x/crypto v0.0.0-20200311171314-f7b00557c8c4/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/exp v0.0.0-20190731235908-ec7cb31e5a56/go.mod h1:JhuoJpWY28nO4Vef9tZUw9qufEGTyX1+7lmHxV5q5G4=
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
Expand All @@ -215,9 +217,12 @@ golang.org/x/mod v0.1.1-0.20191209134235-331c550502dd/go.mod h1:s0Qsj1ACt9ePp/hM
golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20190628185345-da137c7871d7 h1:rTIdg5QFRR7XCaK4LCjBiPbx8j4DQRpdYMnGn/bJUEU=
golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20200301022130-244492dfa37a h1:GuSPYbZzB5/dcLNCwLQLsg3obCJtX9IJhpXkvY7kzk0=
golang.org/x/net v0.0.0-20200301022130-244492dfa37a/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f h1:Bl/8QSvNqXvPGPGXa2z5xUTmV7VDcZyvRZ+QQXkXTZQ=
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
Expand Down
2 changes: 1 addition & 1 deletion p2p/discv5/node_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ var parseNodeTests = []struct {
{
// This test checks that errors from url.Parse are handled.
rawurl: "://foo",
wantError: `parse ://foo: missing protocol scheme`,
wantError: `missing protocol scheme`,
},
}

Expand Down

0 comments on commit bd6a4a4

Please sign in to comment.