From 75c9b7a765767f0555e7642fc70e8df3160b65a1 Mon Sep 17 00:00:00 2001 From: Jonathan Chappelow Date: Wed, 18 Aug 2021 10:32:58 -0500 Subject: [PATCH] build: go [1.16,1.17], nodejs [14,16], golangci-lint 1.42 --- .github/workflows/build.yml | 6 +++--- README.md | 2 +- go.mod | 4 +--- go.sum | 4 ---- run_tests.sh | 6 +++--- 5 files changed, 8 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 024d61b87c..73ba200746 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,7 +6,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - go: [1.15, 1.16] + go: [1.16, 1.17] steps: - name: Set up Go uses: actions/setup-go@v2 @@ -16,7 +16,7 @@ jobs: - name: Check out source uses: actions/checkout@v2 - name: Install Linters - run: "curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.40.1" + run: "curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.42.0" - name: Test env: @@ -28,7 +28,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node-version: [14.x, 15.x] + node-version: [14.x, 16.x] steps: - uses: actions/checkout@v2 - name: Use nodejs ${{ matrix.node-version }} diff --git a/README.md b/README.md index 4b9a10a8b9..331af026a7 100644 --- a/README.md +++ b/README.md @@ -238,7 +238,7 @@ for more details about how atomic swaps work. ### Dependencies -1. [Go >= 1.15](https://golang.org/doc/install) +1. [Go >= 1.16](https://golang.org/doc/install) 2. [Node 14+](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) is used to bundle resources for the browser interface. It's important to note that the DEX client has no external javascript dependencies. The client doesn't import any Node packages. We only use Node to lint and compile our own javascript and css resources. 3. [dcrd](https://github.com/decred/dcrd/tree/master) and [dcrwallet](https://github.com/decred/dcrwallet/tree/master) (non-SPV), installed from the [v1.6.x release binaries](https://github.com/decred/decred-release/releases/tag/v1.6.1), or built from the `release-v1.6` branch. 4. [Bitcoin Core v0.20.x](https://bitcoincore.org/en/download/) (bitcoind or bitcoin-qt) wallet, **encrypted**. diff --git a/go.mod b/go.mod index 5dcd690bf3..bf60d8252a 100644 --- a/go.mod +++ b/go.mod @@ -1,8 +1,6 @@ module decred.org/dcrdex -go 1.15 - -replace decred.org/dcrdex/internal/eth/reentryattack => ./internal/eth/reentryattack +go 1.16 require ( decred.org/dcrwallet/v2 v2.0.0-20210714172147-8815838443cd diff --git a/go.sum b/go.sum index 2187702b73..2939c701ed 100644 --- a/go.sum +++ b/go.sum @@ -369,10 +369,8 @@ github.com/klauspost/pgzip v1.0.2-0.20170402124221-0bf5dcad4ada/go.mod h1:Ch1tH6 github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515 h1:T+h1c/A9Gawja4Y9mFVWj2vyii2bbUNDw3kt9VxK2EY= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= -github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/leanovate/gopter v0.2.9/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= @@ -732,7 +730,6 @@ google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlba gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= @@ -754,7 +751,6 @@ gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= diff --git a/run_tests.sh b/run_tests.sh index 01af5bc98a..11a4e972be 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -13,9 +13,9 @@ for m in $modules do cd "$dir/$m" - # run `go mod tidy` and fail if the git status of go.mod and/or - # go.sum changes - if [[ "$GV" =~ ^1.16 ]]; then + # Run `go mod tidy` and fail if the git status of go.mod and/or + # go.sum changes. Only do this for the latest Go version. + if [[ "$GV" =~ ^1.17 ]]; then MOD_STATUS=$(git status --porcelain go.mod go.sum) go mod tidy UPDATED_MOD_STATUS=$(git status --porcelain go.mod go.sum)