From 0c9e981b185ffe9b94c766845d9cfd8dab5d9369 Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Tue, 23 Aug 2022 02:20:29 +0000 Subject: [PATCH 01/17] Upgrade golang version to 1.18 --- go.mod | 117 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++- go.sum | 21 ----------- 2 files changed, 116 insertions(+), 22 deletions(-) diff --git a/go.mod b/go.mod index 3a3d2eb9..99fd693b 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/line/lbm -go 1.15 +go 1.18 require ( github.com/gorilla/mux v1.8.0 @@ -15,6 +15,121 @@ require ( github.com/tendermint/tm-db v0.6.7 ) +require ( + filippo.io/edwards25519 v1.0.0-rc.1 // indirect + github.com/99designs/keyring v1.1.6 // indirect + github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d // indirect + github.com/VictoriaMetrics/fastcache v1.10.0 // indirect + github.com/Workiva/go-datastructures v1.0.52 // indirect + github.com/armon/go-metrics v0.4.0 // indirect + github.com/beorn7/perks v1.0.1 // indirect + github.com/bgentry/speakeasy v0.1.0 // indirect + github.com/btcsuite/btcd v0.22.1 // indirect + github.com/cenkalti/backoff/v4 v4.1.3 // indirect + github.com/cespare/xxhash v1.1.0 // indirect + github.com/cespare/xxhash/v2 v2.1.2 // indirect + github.com/coinbase/rosetta-sdk-go v0.7.10 // indirect + github.com/confio/ics23/go v0.7.0 // indirect + github.com/coniks-sys/coniks-go v0.0.0-20180722014011-11acf4819b71 // indirect + github.com/cosmos/btcutil v1.0.4 // indirect + github.com/cosmos/go-bip39 v1.0.0 // indirect + github.com/cosmos/gorocksdb v1.2.0 // indirect + github.com/cosmos/iavl v0.17.3 // indirect + github.com/cosmos/ledger-cosmos-go v0.11.1 // indirect + github.com/cosmos/ledger-go v0.9.2 // indirect + github.com/danieljoos/wincred v1.0.2 // indirect + github.com/davecgh/go-spew v1.1.1 // indirect + github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect + github.com/dgraph-io/badger/v2 v2.2007.4 // indirect + github.com/dgraph-io/ristretto v0.1.0 // indirect + github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 // indirect + github.com/dustin/go-humanize v1.0.0 // indirect + github.com/dvsekhvalnov/jose2go v0.0.0-20200901110807-248326c1351b // indirect + github.com/felixge/httpsnoop v1.0.1 // indirect + github.com/fsnotify/fsnotify v1.5.4 // indirect + github.com/go-kit/kit v0.12.0 // indirect + github.com/go-kit/log v0.2.1 // indirect + github.com/go-logfmt/logfmt v0.5.1 // indirect + github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect + github.com/gogo/gateway v1.1.0 // indirect + github.com/gogo/protobuf v1.3.3 // indirect + github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b // indirect + github.com/golang/protobuf v1.5.2 // indirect + github.com/golang/snappy v0.0.4 // indirect + github.com/google/btree v1.0.0 // indirect + github.com/google/gofuzz v1.1.1-0.20200604201612-c04b05f3adfa // indirect + github.com/google/orderedcode v0.0.1 // indirect + github.com/gorilla/handlers v1.5.1 // indirect + github.com/gorilla/websocket v1.5.0 // indirect + github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 // indirect + github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect + github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c // indirect + github.com/gtank/merlin v0.1.1 // indirect + github.com/gtank/ristretto255 v0.1.2 // indirect + github.com/hashicorp/go-immutable-radix v1.3.1 // indirect + github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d // indirect + github.com/hashicorp/hcl v1.0.0 // indirect + github.com/hdevalence/ed25519consensus v0.0.0-20220222234857-c00d1f31bab3 // indirect + github.com/herumi/bls-eth-go-binary v0.0.0-20220509081320-2d8ab06de53c // indirect + github.com/improbable-eng/grpc-web v0.15.0 // indirect + github.com/inconshreveable/mousetrap v1.0.0 // indirect + github.com/jmhodges/levigo v1.0.0 // indirect + github.com/josharian/intern v1.0.0 // indirect + github.com/keybase/go-keychain v0.0.0-20190712205309-48d3d31d256d // indirect + github.com/klauspost/compress v1.13.6 // indirect + github.com/lib/pq v1.10.6 // indirect + github.com/libp2p/go-buffer-pool v0.1.0 // indirect + github.com/line/tm-db/v2 v2.0.0-init.1.0.20220121012851-61d2bc1d9486 // indirect + github.com/line/wasmvm v1.0.0-0.10.0 // indirect + github.com/magiconair/properties v1.8.6 // indirect + github.com/mailru/easyjson v0.7.7 // indirect + github.com/mattn/go-colorable v0.1.12 // indirect + github.com/mattn/go-isatty v0.0.14 // indirect + github.com/matttproud/golang_protobuf_extensions v1.0.1 // indirect + github.com/mimoo/StrobeGo v0.0.0-20181016162300-f8f6d4d2b643 // indirect + github.com/minio/highwayhash v1.0.2 // indirect + github.com/mitchellh/go-homedir v1.1.0 // indirect + github.com/mitchellh/mapstructure v1.5.0 // indirect + github.com/mtibben/percent v0.2.1 // indirect + github.com/pelletier/go-toml v1.9.5 // indirect + github.com/pelletier/go-toml/v2 v2.0.1 // indirect + github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5 // indirect + github.com/pkg/errors v0.9.1 // indirect + github.com/pmezard/go-difflib v1.0.0 // indirect + github.com/prometheus/client_model v0.2.0 // indirect + github.com/prometheus/common v0.37.0 // indirect + github.com/prometheus/procfs v0.7.3 // indirect + github.com/r2ishiguro/vrf v0.0.0-20180716233122-192de52975eb // indirect + github.com/rcrowley/go-metrics v0.0.0-20200313005456-10cdbea86bc0 // indirect + github.com/regen-network/cosmos-proto v0.3.1 // indirect + github.com/rs/cors v1.8.2 // indirect + github.com/rs/zerolog v1.27.0 // indirect + github.com/sasha-s/go-deadlock v0.2.1-0.20190427202633-1595213edefa // indirect + github.com/spf13/afero v1.8.2 // indirect + github.com/spf13/jwalterweatherman v1.1.0 // indirect + github.com/spf13/pflag v1.0.5 // indirect + github.com/subosito/gotenv v1.3.0 // indirect + github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect + github.com/tendermint/btcd v0.1.1 // indirect + github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 // indirect + github.com/tendermint/go-amino v0.16.0 // indirect + github.com/tendermint/tendermint v0.34.14 // indirect + github.com/zondax/hid v0.9.0 // indirect + go.etcd.io/bbolt v1.3.6 // indirect + golang.org/x/crypto v0.0.0-20220525230936-793ad666bf5e // indirect + golang.org/x/net v0.0.0-20220617184016-355a448f1bc9 // indirect + golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c // indirect + golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 // indirect + golang.org/x/text v0.3.7 // indirect + google.golang.org/genproto v0.0.0-20220519153652-3a47de7e79bd // indirect + google.golang.org/grpc v1.48.0 // indirect + google.golang.org/protobuf v1.28.1 // indirect + gopkg.in/ini.v1 v1.66.4 // indirect + gopkg.in/yaml.v2 v2.4.0 // indirect + gopkg.in/yaml.v3 v3.0.1 // indirect + nhooyr.io/websocket v1.8.6 // indirect +) + replace ( github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 google.golang.org/grpc => google.golang.org/grpc v1.33.2 diff --git a/go.sum b/go.sum index d9c7a39c..663fb287 100644 --- a/go.sum +++ b/go.sum @@ -81,7 +81,6 @@ github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d/go.mod h1:URdX5+vg25ts3aCh8H5IFZybJYKWhJHYMTnf+ULtoC4= github.com/DATA-DOG/go-sqlmock v1.3.3/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= -github.com/DATA-DOG/go-sqlmock v1.5.0 h1:Shsta01QNfFxHCfpW6YH2STWB0MudeXXEWMr20OEh60= github.com/DATA-DOG/go-sqlmock v1.5.0/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= github.com/DataDog/zstd v1.4.1/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= @@ -271,7 +270,6 @@ github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsr github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/cyberdelia/templates v0.0.0-20141128023046-ca7fffd4298c/go.mod h1:GyV+0YP4qX0UQ7r2MoYZ+AvYDp12OF5yg4q8rGnyNh4= github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4= @@ -289,7 +287,6 @@ github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeC github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= github.com/deepmap/oapi-codegen v1.8.2/go.mod h1:YLgSKSDv/bZQB7N4ws6luhozi3cEdRktEqrX88CvjIw= -github.com/denisenkom/go-mssqldb v0.12.0 h1:VtrkII767ttSPNRfFekePK3sctr+joXgO58stqQbtUA= github.com/denisenkom/go-mssqldb v0.12.0/go.mod h1:iiK0YP1ZeepvmBQk/QpLEhhTNJgfzrpArPY/aFvc9yU= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f/go.mod h1:xH/i4TFMt8koVQZ6WFms69WAsDWr2XsYL3Hkl7jkoLE= @@ -310,11 +307,9 @@ github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91/go.mod h1:2pZnwu github.com/dnaeon/go-vcr v1.1.0/go.mod h1:M7tiix8f0r6mKKJ3Yq/kqU1OYf3MnfmBWVbPx/yU9ko= github.com/dnaeon/go-vcr v1.2.0/go.mod h1:R4UdLID7HZT3taECzJs4YgbbH6PIGXB6W/sc5OLb6RQ= github.com/docker/cli v20.10.14+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= -github.com/docker/cli v20.10.17+incompatible h1:eO2KS7ZFeov5UJeaDmIs1NFEDRf32PaqRpvoEkKBy5M= github.com/docker/cli v20.10.17+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/docker v1.6.2/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/docker v20.10.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/docker v20.10.17+incompatible h1:JYCuMrWaVNophQTOrMMoSwudOVEfcegoZZrleKc1xwE= github.com/docker/docker v20.10.17+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= @@ -406,7 +401,6 @@ github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34 github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= github.com/go-pdf/fpdf v0.5.0/go.mod h1:HzcnA+A23uwogo0tp9yU+l3V+KXhiESpt1PMayhOh5M= github.com/go-pdf/fpdf v0.6.0/go.mod h1:HzcnA+A23uwogo0tp9yU+l3V+KXhiESpt1PMayhOh5M= -github.com/go-playground/assert/v2 v2.0.1 h1:MsBgLAaY856+nPRTKrp3/OZK38U/wa0CcBYNjji3q3A= github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.13.0 h1:HyWk6mgj5qFqCT5fjGBuRArbVDfE4hi8+e8ceBS/t7Q= github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= @@ -417,7 +411,6 @@ github.com/go-playground/validator/v10 v10.2.0/go.mod h1:uOYAAleCW8F/7oMFd6aG0GO github.com/go-sourcemap/sourcemap v2.1.3+incompatible/go.mod h1:F8jJfvm2KbVjc5NqelyYJmf/v5J0dwNLS2mL4sNA1Jg= github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= github.com/go-sql-driver/mysql v1.4.1/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= -github.com/go-sql-driver/mysql v1.6.0 h1:BCTh4TKNUYmOmMUcQ3IipzF5prigylS7XXjEkfCHuOE= github.com/go-sql-driver/mysql v1.6.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= @@ -437,9 +430,7 @@ github.com/gogo/gateway v1.1.0 h1:u0SuhL9+Il+UbjM9VIE3ntfRujKbvVpFvNB4HbjeVQ0= github.com/gogo/gateway v1.1.0/go.mod h1:S7rR8FRQyG3QFESeSv4l2WnsyzlCLG0CzBbUUo/mbic= github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= github.com/golang-jwt/jwt/v4 v4.3.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= -github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe h1:lXe2qZdvpiX5WZkZR4hgp4KJVfY3nMkvmwbVkpv1rVY= github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0= -github.com/golang-sql/sqlexp v0.0.0-20170517235910-f1bb20e5a188 h1:+eHOFJl1BaXrQxKX+T06f78590z4qA2ZzBTqahsKSE4= github.com/golang-sql/sqlexp v0.0.0-20170517235910-f1bb20e5a188/go.mod h1:vXjM/+wXQnTPR4KqTKDgJukSZ6amVRtWMPEjE6sQoK8= github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= github.com/golang/geo v0.0.0-20190916061304-5b978397cfec/go.mod h1:QZ0nwyI2jOfgRAoBvP+ab5aRr7c9x7lhGEJrKvBwjWI= @@ -531,7 +522,6 @@ github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLe github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= -github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 h1:El6M4kTTCOh6aBiKaUGG7oYTSPP8MxqL4YI3kZKwcP4= github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= @@ -559,7 +549,6 @@ github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/ad github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/gotestyourself/gotestyourself v2.2.0+incompatible h1:AQwinXlbQR2HvPjQZOmDhRqsv5mZf+Jb1RnSLxcqZcI= github.com/gotestyourself/gotestyourself v2.2.0+incompatible/go.mod h1:zZKM6oeNM8k+FRljX1mnzVYeS8wiGgQyvST1/GafPbY= github.com/graph-gophers/graphql-go v1.3.0/go.mod h1:9CQHMSxwO4MprSdzoIEobiHpoLtHm77vfxsvsIN5Vuc= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= @@ -644,7 +633,6 @@ github.com/huin/goutil v0.0.0-20170803182201-1ca381bf3150/go.mod h1:PpLOETDnJ0o3 github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= -github.com/imdario/mergo v0.3.13 h1:lFzP57bqS/wsqKssCGmtLAb8A0wKjLGrve2q3PPVcBk= github.com/imdario/mergo v0.3.13/go.mod h1:4lJ1jqUDcsbIECGy0RUJAXNIhg+6ocWgb1ALK2O4oXg= github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= github.com/improbable-eng/grpc-web v0.15.0/go.mod h1:1sy9HKV4Jt9aEs9JSnkWlRJPuPtwNr0l57L4f878wP8= @@ -784,7 +772,6 @@ github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzp github.com/mattn/go-runewidth v0.0.3/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= github.com/mattn/go-sqlite3 v1.11.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= -github.com/mattn/go-sqlite3 v1.14.9 h1:10HX2Td0ocZpYEjhilsuo6WWtUqttj2Kb0KtD86/KYA= github.com/mattn/go-sqlite3 v1.14.9/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU= github.com/mattn/go-tty v0.0.0-20180907095812-13ff1204f104/go.mod h1:XPvLUNfbS4fJH25nqRHfWLMa1ONC8Amw+mIA639KxkE= github.com/matttproud/golang_protobuf_extensions v1.0.1 h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU= @@ -817,7 +804,6 @@ github.com/mitchellh/pointerstructure v1.2.0/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8oh github.com/moby/sys/mountinfo v0.4.1/go.mod h1:rEr8tzG/lsIZHBtN/JjGG+LMYx9eXgW2JI+6q0qou+A= github.com/moby/sys/mountinfo v0.5.0/go.mod h1:3bMD3Rg+zkqx8MRYPi7Pyb0Ie97QEBmdxbhnCLlSvSU= github.com/moby/term v0.0.0-20201216013528-df9cb8a40635/go.mod h1:FBS0z0QWA44HXygs7VXDUOGoN/1TV3RuWkLO04am3wc= -github.com/moby/term v0.0.0-20210619224110-3f7ff695adc6 h1:dcztxKSvZ4Id8iPpHERQBbIJfabdt4wUm5qy3wOL2Zc= github.com/moby/term v0.0.0-20210619224110-3f7ff695adc6/go.mod h1:E2VnQOmVuvZB6UYnnDB0qG5Nq/1tD9acaOpo6xmt0Kw= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= @@ -869,7 +855,6 @@ github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9k github.com/onsi/ginkgo v1.16.2/go.mod h1:CObGmKUOKaSC0RjmoAK7tKyn4Azo5P2IWuoMnvwxz1E= github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= -github.com/onsi/ginkgo/v2 v2.0.0 h1:CcuG/HvWNkkaqCUpJifQY8z7qEMBJya6aLPx6ftGyjQ= github.com/onsi/ginkgo/v2 v2.0.0/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c= github.com/onsi/gomega v1.4.1/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= @@ -907,7 +892,6 @@ github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnh github.com/openzipkin/zipkin-go v0.2.5/go.mod h1:KpXfKdgRDnnhsxw4pNIH9Md5lyFqKUa4YDFlwRYAMyE= github.com/ory/dockertest v3.3.5+incompatible h1:iLLK6SQwIhcbrG783Dghaaa3WPzGc+4Emza6EbVUUGA= github.com/ory/dockertest v3.3.5+incompatible/go.mod h1:1vX4m9wsvi00u5bseYwXaSnhNrne+V0E6LAcBILJdPs= -github.com/ory/dockertest/v3 v3.9.1 h1:v4dkG+dlu76goxMiTT2j8zV7s4oPPEppKT8K8p2f1kY= github.com/ory/dockertest/v3 v3.9.1/go.mod h1:42Ir9hmvaAPm0Mgibk6mBPi7SFvTXxEcnztDYOJ//uM= github.com/pact-foundation/pact-go v1.0.4/go.mod h1:uExwJY4kCzNPcHRj+hCR/HBbOOIwwtUjcrb0b5/5kLM= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= @@ -1147,11 +1131,8 @@ github.com/vmihailenco/msgpack/v5 v5.3.5/go.mod h1:7xyJ9e+0+9SaZT0Wt1RGleJXzli6Q github.com/vmihailenco/tagparser/v2 v2.0.0/go.mod h1:Wri+At7QHww0WTrCBeu4J6bNtoV6mEfg5OIWRZA9qds= github.com/willf/bitset v1.1.3/go.mod h1:RjeCKbqT1RxIR/KWY6phxZiaY1IyutSBfGjNPySAYV4= github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb h1:zGWFAtiMcyryUHoUjUJX0/lt1H2+i2Ka2n+D3DImSNo= github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 h1:EzJWgHovont7NscjpAxXsDA8S8BMYve8Y5+7cuRE7R0= github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xeipuuv/gojsonschema v1.2.0 h1:LhYJRs+L4fBtjZUfuSZIKGeVu0QRy8e5Xi7D17UxZ74= github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/xlab/treeprint v0.0.0-20180616005107-d6fb6747feb6/go.mod h1:ce1O1j6UtZfjr22oyGxGLbauSBp2YVXpARAosm7dHBg= @@ -1814,10 +1795,8 @@ gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.0/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/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= gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= -gotest.tools/v3 v3.2.0 h1:I0DwBVMGAx26dttAj1BtJLAkVGncrkkUXfJLC4Flt/I= gotest.tools/v3 v3.2.0/go.mod h1:Mcr9QNxkg0uMvy/YElmo4SpXgJKWgQvYrT7Kw5RzJ1A= 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= From fc9dad9e7af64691f4f60294c5d0c4cde403c697 Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Tue, 23 Aug 2022 02:03:03 +0000 Subject: [PATCH 02/17] Upgrade golang version in Dockerfiles --- Dockerfile | 2 +- builders/Dockerfile.static | 2 +- builders/Dockerfile.static_centos7 | 4 ++-- contrib/Dockerfile.test | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index a921bf9f..525fcfe2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ # > docker build --platform="linux/amd64" -t line/lbm . # > docker run -it -p 26656:26656 -p 26657:26657 -v ~/.lbm:/root/.lbm -v line/lbm lbm init # > docker run -it -p 26656:26656 -p 26657:26657 -v ~/.lbm:/root/.lbm -v line/lbm lbm start --rpc.laddr=tcp://0.0.0.0:26657 --p2p.laddr=tcp://0.0.0.0:26656 -FROM golang:1.15-alpine3.13 AS build-env +FROM golang:1.18.3-alpine AS build-env ARG LBM_BUILD_OPTIONS="" # Set up OS dependencies diff --git a/builders/Dockerfile.static b/builders/Dockerfile.static index 48d037de..7c5b9f74 100644 --- a/builders/Dockerfile.static +++ b/builders/Dockerfile.static @@ -2,7 +2,7 @@ # > docker build --platform="linux/amd64" -t line/lbm -f builders/Dockerfile.static . --build-arg ARCH=x86_64 # > docker run -it -p 26656:26656 -p 26657:26657 -v ~/.lbm:/root/.lbm -v line/lbm lbm init # > docker run -it -p 26656:26656 -p 26657:26657 -v ~/.lbm:/root/.lbm -v line/lbm lbm start --rpc.laddr=tcp://0.0.0.0:26657 --p2p.laddr=tcp://0.0.0.0:26656 -FROM golang:1.15-alpine3.13 AS build-env +FROM golang:1.18-alpine AS build-env ARG LBM_BUILD_OPTIONS="" ARG ARCH=$ARCH diff --git a/builders/Dockerfile.static_centos7 b/builders/Dockerfile.static_centos7 index e0970baf..0dbf6587 100644 --- a/builders/Dockerfile.static_centos7 +++ b/builders/Dockerfile.static_centos7 @@ -45,8 +45,8 @@ ENV PATH=$HOME/.cargo/bin:$PATH # install go WORKDIR /tmp -ADD https://golang.org/dl/go1.15.15.linux-amd64.tar.gz . -RUN tar -C /usr/local -xzf go1.15.15.linux-amd64.tar.gz +ADD https://golang.org/dl/go1.18.3.linux-amd64.tar.gz . +RUN tar -C /usr/local -xzf go1.18.3.linux-amd64.tar.gz ENV PATH=/usr/local/go/bin:$PATH # install cmake3(required by snappy, If use yum, it installs as version 2) diff --git a/contrib/Dockerfile.test b/contrib/Dockerfile.test index 5d230be8..6b1ad705 100644 --- a/contrib/Dockerfile.test +++ b/contrib/Dockerfile.test @@ -2,7 +2,7 @@ # > docker build -t link . # > docker run -it -p 46657:46657 -p 46656:46656 -v ~/.lbm:/root/.lbm -v ~/.linkcli:/root/.linkcli link lbm init # > docker run -it -p 46657:46657 -p 46656:46656 -v ~/.lbm:/root/.lbm -v ~/.linkcli:/root/.linkcli link lbm start -FROM golang:1.15-alpine AS build-env +FROM golang:1.18.3-alpine AS build-env # Set up dependencies ENV PACKAGES curl make git libc-dev bash gcc linux-headers eudev-dev python3 From 965f4e93e03f506a7efd4cc3ec1e0b9f539a9912 Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Tue, 23 Aug 2022 02:07:30 +0000 Subject: [PATCH 03/17] Update golang version in docs --- CONTRIBUTING.md | 2 +- README.md | 2 +- docs/lbm-tutorials/installation.md | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 6bf2abb6..ea91b93c 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -74,7 +74,7 @@ Please don't make Pull Requests from `main`. ## Dependencies -We use [Go 1.15 Modules](https://github.com/golang/go/wiki/Modules) to manage +We use [Go 1.18 Modules](https://github.com/golang/go/wiki/Modules) to manage dependency versions. The `main` branch of every LBM repository should just build with `go get`, diff --git a/README.md b/README.md index 031ae87c..d50608b1 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ This repository hosts `LBM(LINE Blockchain Mainnet)`. This repository is forked from [gaia](https://github.com/cosmos/gaia) at 2021-03-15. LBM is a mainnet app implementation using [lbm-sdk](https://github.com/line/lbm-sdk) and [ostracon](https://github.com/line/ostracon). -**Node**: Requires [Go 1.15+](https://golang.org/dl/) +**Node**: Requires [Go 1.18+](https://golang.org/dl/) **Warnings**: Initial development is in progress, but there has not yet been a stable. diff --git a/docs/lbm-tutorials/installation.md b/docs/lbm-tutorials/installation.md index 1a2b9439..6e375ef4 100644 --- a/docs/lbm-tutorials/installation.md +++ b/docs/lbm-tutorials/installation.md @@ -21,7 +21,7 @@ source ~/.bash_profile ``` ::: tip -**Go 1.15+** is required for the Cosmos SDK. +**Go 1.18+** is required for the LBM SDK. ::: ## Install the binaries @@ -66,7 +66,7 @@ server_name: lbm version: 1.0.0 commit: 8692310a5361006f8c02d44cd7df2d41f130089b build_tags: netgo,goleveldb -go: go version go1.15.2 darwin/amd64 +go: go version go1.18.3 darwin/amd64 build_deps: - github.com/... - github.com/... From 0302f62f468af383f632dc607f891ebfc98095a2 Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Tue, 23 Aug 2022 02:42:03 +0000 Subject: [PATCH 04/17] Update workflows --- .github/workflows/autopr.yml | 2 +- .github/workflows/docker.yml | 2 +- .github/workflows/lint.yml | 4 ++-- .github/workflows/sims.yml | 14 +++++++------- .github/workflows/tag.yml | 8 ++++---- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/autopr.yml b/.github/workflows/autopr.yml index d2b7cd9e..57fe6ba8 100644 --- a/.github/workflows/autopr.yml +++ b/.github/workflows/autopr.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Check out repository code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: pull-request uses: repo-sync/pull-request@v2 diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index ba22a569..f1699938 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -14,7 +14,7 @@ jobs: build: runs-on: self-hosted steps: - - uses: actions/checkout@master + - uses: actions/checkout@v3 with: fetch-depth: 0 diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index ffe99dbc..3d61c682 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -13,8 +13,8 @@ jobs: runs-on: self-hosted timeout-minutes: 6 steps: - - uses: actions/checkout@v2 - - uses: technote-space/get-diff-action@v4 + - uses: actions/checkout@v3 + - uses: technote-space/get-diff-action@v6.1.0 with: PATTERNS: | **/**.go diff --git a/.github/workflows/sims.yml b/.github/workflows/sims.yml index fca646fb..95a68159 100644 --- a/.github/workflows/sims.yml +++ b/.github/workflows/sims.yml @@ -21,10 +21,10 @@ jobs: runs-on: self-hosted if: "!contains(github.event.head_commit.message, 'skip-sims')" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: actions/setup-go@v2.1.3 with: - go-version: 1.15 + go-version: 1.18 - name: Display go version run: go version - run: make build @@ -35,7 +35,7 @@ jobs: steps: - uses: actions/setup-go@v2.1.3 with: - go-version: 1.15 + go-version: 1.18 - name: Display go version run: go version - name: Install runsim @@ -52,7 +52,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-go@v2.1.3 with: - go-version: 1.15 + go-version: 1.18 - name: Display go version run: go version - uses: technote-space/get-diff-action@v4 @@ -78,7 +78,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-go@v2.1.3 with: - go-version: 1.15 + go-version: 1.18 - name: Display go version run: go version - uses: technote-space/get-diff-action@v4 @@ -106,7 +106,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-go@v2.1.3 with: - go-version: 1.15 + go-version: 1.18 - name: Display go version run: go version - uses: technote-space/get-diff-action@v4 @@ -134,7 +134,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-go@v2.1.3 with: - go-version: 1.15 + go-version: 1.18 - name: Display go version run: go version - uses: technote-space/get-diff-action@v4 diff --git a/.github/workflows/tag.yml b/.github/workflows/tag.yml index 56d3a786..0ba65dcb 100644 --- a/.github/workflows/tag.yml +++ b/.github/workflows/tag.yml @@ -11,15 +11,15 @@ jobs: release: runs-on: self-hosted steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Install Go - uses: actions/setup-go@v2.1.3 + uses: actions/setup-go@v3.2.1 with: - go-version: 1.15 + go-version: 1.18 # - name: Unshallow # run: git fetch --prune --unshallow - name: Create release - uses: goreleaser/goreleaser-action@v2 + uses: goreleaser/goreleaser-action@v3 with: args: release --rm-dist --release-notes ./RELEASE_CHANGELOG.md env: From f5a0f498046d8d95ccff531e4bb5ca24f257bff6 Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Tue, 23 Aug 2022 04:37:50 +0000 Subject: [PATCH 05/17] Update golang 1.18.3 to 1.18.5 --- Dockerfile | 2 +- builders/Dockerfile.static_centos7 | 4 ++-- contrib/Dockerfile.test | 2 +- docs/lbm-tutorials/installation.md | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 525fcfe2..b6bdd9d1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ # > docker build --platform="linux/amd64" -t line/lbm . # > docker run -it -p 26656:26656 -p 26657:26657 -v ~/.lbm:/root/.lbm -v line/lbm lbm init # > docker run -it -p 26656:26656 -p 26657:26657 -v ~/.lbm:/root/.lbm -v line/lbm lbm start --rpc.laddr=tcp://0.0.0.0:26657 --p2p.laddr=tcp://0.0.0.0:26656 -FROM golang:1.18.3-alpine AS build-env +FROM golang:1.18.5-alpine AS build-env ARG LBM_BUILD_OPTIONS="" # Set up OS dependencies diff --git a/builders/Dockerfile.static_centos7 b/builders/Dockerfile.static_centos7 index 0dbf6587..fd85a75e 100644 --- a/builders/Dockerfile.static_centos7 +++ b/builders/Dockerfile.static_centos7 @@ -45,8 +45,8 @@ ENV PATH=$HOME/.cargo/bin:$PATH # install go WORKDIR /tmp -ADD https://golang.org/dl/go1.18.3.linux-amd64.tar.gz . -RUN tar -C /usr/local -xzf go1.18.3.linux-amd64.tar.gz +ADD https://golang.org/dl/go1.18.5.linux-amd64.tar.gz . +RUN tar -C /usr/local -xzf go1.18.5.linux-amd64.tar.gz ENV PATH=/usr/local/go/bin:$PATH # install cmake3(required by snappy, If use yum, it installs as version 2) diff --git a/contrib/Dockerfile.test b/contrib/Dockerfile.test index 6b1ad705..d10c0b11 100644 --- a/contrib/Dockerfile.test +++ b/contrib/Dockerfile.test @@ -2,7 +2,7 @@ # > docker build -t link . # > docker run -it -p 46657:46657 -p 46656:46656 -v ~/.lbm:/root/.lbm -v ~/.linkcli:/root/.linkcli link lbm init # > docker run -it -p 46657:46657 -p 46656:46656 -v ~/.lbm:/root/.lbm -v ~/.linkcli:/root/.linkcli link lbm start -FROM golang:1.18.3-alpine AS build-env +FROM golang:1.18.5-alpine AS build-env # Set up dependencies ENV PACKAGES curl make git libc-dev bash gcc linux-headers eudev-dev python3 diff --git a/docs/lbm-tutorials/installation.md b/docs/lbm-tutorials/installation.md index 6e375ef4..596d4d1b 100644 --- a/docs/lbm-tutorials/installation.md +++ b/docs/lbm-tutorials/installation.md @@ -66,7 +66,7 @@ server_name: lbm version: 1.0.0 commit: 8692310a5361006f8c02d44cd7df2d41f130089b build_tags: netgo,goleveldb -go: go version go1.18.3 darwin/amd64 +go: go version go1.18.5 darwin/amd64 build_deps: - github.com/... - github.com/... From 272514cb10ca8593a6a38f071672eb56af3c565d Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Tue, 23 Aug 2022 04:39:29 +0000 Subject: [PATCH 06/17] Update CHANGELOG.md --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d069f26d..407c801c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -53,6 +53,7 @@ This version based on [lbm-sdk v0.46.0-rc6](https://github.com/line/lbm-sdk/rele ### Build, CI * (ci) [\#80](https://github.com/line/lbm/pull/80) remove stale github action +* (build) [\#89](https://github.com/line/lbm/pull/89) upgrade golang to 1.18 From b3c1d64c5522bca35beb924d9c30101f365f6652 Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Fri, 26 Aug 2022 06:19:37 +0000 Subject: [PATCH 07/17] Install required packages in the workflows --- .github/workflows/tests.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 6920d812..80e24ae7 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -278,6 +278,8 @@ jobs: - uses: actions/setup-go@v3.2.1 with: go-version: 1.18 + - name: Install docker-compose + run: sudo apt-get update && sudo apt-get install -y docker-compose - name: Start localnet run: | make localnet-start From 439c92e43fd037ff417b9dfcdd190da3cb7231af Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Fri, 26 Aug 2022 07:02:45 +0000 Subject: [PATCH 08/17] Revert "Disable diff" This reverts commit 94735842cae408edbd770f845a34141706d66c4f. --- .github/workflows/tests.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 80e24ae7..fc73955c 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -50,6 +50,7 @@ jobs: go.sum - name: Build run: GOARCH=${{ matrix.go-arch }} LEDGER_ENABLED=false make build + if: env.GIT_DIFF split-test-files: runs-on: self-hosted @@ -101,9 +102,11 @@ jobs: - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-${{ matrix.part }}" + if: env.GIT_DIFF - name: test & coverage report creation run: | cat pkgs.txt.part.${{ matrix.part }} | xargs go test -mod=readonly -timeout 30m -coverprofile=${{ matrix.part }}profile.out -covermode=atomic -tags='ledger test_ledger_mock goleveldb' + if: env.GIT_DIFF - uses: actions/upload-artifact@v3 with: name: "${{ github.sha }}-${{ matrix.part }}-coverage" @@ -123,17 +126,22 @@ jobs: - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-00-coverage" + if: env.GIT_DIFF - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-01-coverage" + if: env.GIT_DIFF - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-02-coverage" + if: env.GIT_DIFF - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-03-coverage" + if: env.GIT_DIFF - run: | cat ./*profile.out | grep -v "mode: atomic" >> coverage.txt + if: env.GIT_DIFF - name: filter out DONTCOVER run: | excludelist="$(find ./ -type f -name '*.go' | xargs grep -l 'DONTCOVER')" @@ -145,10 +153,12 @@ jobs: echo "Excluding ${filename} from coverage report..." sed -i.bak "/$(echo $filename | sed 's/\//\\\//g')/d" coverage.txt done + if: env.GIT_DIFF - uses: codecov/codecov-action@v3.1.0 with: token: ${{ secrets.CODECOV_TOKEN }} file: ./coverage.txt + if: env.GIT_DIFF test-integration: runs-on: self-hosted @@ -171,9 +181,11 @@ jobs: - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-${{ matrix.part }}" + if: env.GIT_DIFF - name: test & coverage report creation run: | xargs --arg-file=pkgs.txt.part.${{ matrix.part }} go test -mod=readonly -json -timeout 30m -tags='cli_test goleveldb' | tee ${{ matrix.part }}-integration-output.txt + if: env.GIT_DIFF - uses: actions/upload-artifact@v3 with: name: "${{ github.sha }}-${{ matrix.part }}-integration-output" @@ -194,21 +206,27 @@ jobs: - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-00-integration-output" + if: env.GIT_DIFF - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-01-integration-output" + if: env.GIT_DIFF - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-02-integration-output" + if: env.GIT_DIFF - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-03-integration-output" + if: env.GIT_DIFF - uses: actions/cache@v3.0.5 with: path: ~/go/bin key: ${{ runner.os }}-go-tparse-binary + if: env.GIT_DIFF - name: Generate integration test report run: cat ./*-integration-output.txt | ~/go/bin/tparse + if: env.GIT_DIFF test-integration-multi-node: runs-on: self-hosted @@ -231,9 +249,11 @@ jobs: - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-${{ matrix.part }}" + if: env.GIT_DIFF - name: test report creation run: | xargs --arg-file=pkgs.txt.part.${{ matrix.part }} go test -mod=readonly -json -timeout 30m -tags='cli_multi_node_test goleveldb' | tee ${{ matrix.part }}-integration-multi-node-output.txt + if: env.GIT_DIFF - uses: actions/upload-artifact@v3 with: name: "${{ github.sha }}-${{ matrix.part }}-integration-multi-node-output" @@ -254,21 +274,27 @@ jobs: - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-00-integration-multi-node-output" + if: env.GIT_DIFF - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-01-integration-multi-node-output" + if: env.GIT_DIFF - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-02-integration-multi-node-output" + if: env.GIT_DIFF - uses: actions/download-artifact@v3 with: name: "${{ github.sha }}-03-integration-multi-node-output" + if: env.GIT_DIFF - uses: actions/cache@v3.0.5 with: path: ~/go/bin key: ${{ runner.os }}-go-tparse-binary + if: env.GIT_DIFF - name: Generate multi node integration test report run: cat ./*-integration-multi-node-output.txt | ~/go/bin/tparse + if: env.GIT_DIFF test-localnet-blocks: runs-on: self-hosted From 27a9ccef29c6028ad6dc7fa4a4aef45ddd9c5f63 Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Fri, 26 Aug 2022 07:21:30 +0000 Subject: [PATCH 09/17] Set up go before golangci-lint --- .github/workflows/lint.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 3d61c682..63d48c99 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -20,6 +20,9 @@ jobs: **/**.go go.mod go.sum + - uses: actions/setup-go@v3.2.1 + with: + go-version: 1.18 - uses: golangci/golangci-lint-action@master with: # Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version. From 3d2687fbd6fe0e09b5d39228eabf8db6445b63df Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Fri, 26 Aug 2022 07:16:44 +0000 Subject: [PATCH 10/17] Update docker workflow --- .github/workflows/docker.yml | 70 ++++++++++++++++++++---------------- 1 file changed, 40 insertions(+), 30 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index f1699938..8b0070ae 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -1,15 +1,17 @@ name: Build & Push -# Build & Push builds the simapp docker image on every push to master and +# Build & Push builds the lbm docker image on every tag push, # and pushes the image to https://docker-registry.linecorp.com/link-network/v2/lbm on: pull_request: - push: branches: - main - tags: - - "v[0-9]+.[0-9]+.[0-9]+" # Push events to matching v*, i.e. v1.0, v20.15.10 - - "v[0-9]+.[0-9]+.[0-9]+-rc*" # Push events to matching v*, i.e. v1.0-rc1, v20.15.10-rc5 - + # push: + # tags: + # - "v[0-9]+.[0-9]+.[0-9]+" # Push events to matching v*, i.e. v1.0, v20.15.10 + # - "v[0-9]+.[0-9]+.[0-9]+-rc*" # Push events to matching v*, i.e. v1.0-rc1, v20.15.10-rc5 +env: + registry: docker-registry.linecorp.com + repository: link-network/v2/lbm jobs: build: runs-on: self-hosted @@ -17,27 +19,35 @@ jobs: - uses: actions/checkout@v3 with: fetch-depth: 0 - - - name: Prepare - id: prep - run: | - DOCKER_IMAGE=line/lbm - VERSION=noop - if [[ $GITHUB_REF == refs/tags/* ]]; then - VERSION=${GITHUB_REF#refs/tags/} - elif [[ $GITHUB_REF == refs/heads/* ]]; then - VERSION=$(echo ${GITHUB_REF#refs/heads/} | sed -r 's#/+#-#g') - if [ "${{ github.event.repository.default_branch }}" = "$VERSION" ]; then - VERSION=latest - fi - fi - TAGS="${DOCKER_IMAGE}:${VERSION}" - if [[ $VERSION =~ ^v[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$ ]]; then - TAGS="$TAGS,${DOCKER_IMAGE}:${VERSION}" - fi - echo ::set-output name=version::${VERSION} - echo ::set-output name=tags::${TAGS} - echo ::set-output name=created::$(date -u +'%Y-%m-%dT%H:%M:%SZ') - - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v1 + - name: Create a context for buildx + run: docker context create buildx + - name: Set up docker buildx + id: buildx + uses: docker/setup-buildx-action@v2 + with: + endpoint: buildx + config-inline: | + [registry."docker.io"] + mirrors = ["docker-hub-mirror.linecorp.com"] + - name: login to the registry + uses: docker/login-action@v2 + if: github.event_name != 'pull_request' + with: + registry: ${{env.registry}} + username: ${{secrets.DOCKERHUB_USERNAME}} + password: ${{secrets.DOCKERHUB_TOKEN}} + - name: extract metadata for docker + id: meta + uses: docker/metadata-action@v4 + with: + images: ${{env.registry}}/${{env.repository}} + tags: | + type=semver,pattern={{version}} + - name: docker build + uses: docker/build-push-action@v3 + with: + push: ${{github.event_name != 'pull_request'}} + build-args: ARCH=x86_64 + tags: ${{steps.meta.outputs.tags}} + labels: ${{steps.meta.outputs.labels}} + platforms: linux/amd64 From 958841aff9052c4099eeffd00220aed861c643bc Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Mon, 29 Aug 2022 01:46:03 +0000 Subject: [PATCH 11/17] Run autopr on self-hosted --- .github/workflows/autopr.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/autopr.yml b/.github/workflows/autopr.yml index 57fe6ba8..d397e3b2 100644 --- a/.github/workflows/autopr.yml +++ b/.github/workflows/autopr.yml @@ -3,14 +3,12 @@ on: push: branches: - release/* - jobs: create-pull-request: - runs-on: ubuntu-latest + runs-on: self-hosted steps: - name: Check out repository code uses: actions/checkout@v3 - - name: pull-request uses: repo-sync/pull-request@v2 with: From 617629319a2da26cf99e0301d7124ab4af18f15a Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Mon, 29 Aug 2022 01:48:41 +0000 Subject: [PATCH 12/17] Update sims workflow --- .github/workflows/sims.yml | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/sims.yml b/.github/workflows/sims.yml index 95a68159..c02cd05f 100644 --- a/.github/workflows/sims.yml +++ b/.github/workflows/sims.yml @@ -22,7 +22,7 @@ jobs: if: "!contains(github.event.head_commit.message, 'skip-sims')" steps: - uses: actions/checkout@v3 - - uses: actions/setup-go@v2.1.3 + - uses: actions/setup-go@v3.2.1 with: go-version: 1.18 - name: Display go version @@ -33,7 +33,7 @@ jobs: runs-on: self-hosted needs: build steps: - - uses: actions/setup-go@v2.1.3 + - uses: actions/setup-go@v3.2.1 with: go-version: 1.18 - name: Display go version @@ -49,13 +49,13 @@ jobs: runs-on: self-hosted needs: [build, install-runsim] steps: - - uses: actions/checkout@v2 - - uses: actions/setup-go@v2.1.3 + - uses: actions/checkout@v3 + - uses: actions/setup-go@v3.2.1 with: go-version: 1.18 - name: Display go version run: go version - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v6.1.0 with: PATTERNS: | **/**.go @@ -75,13 +75,13 @@ jobs: runs-on: self-hosted needs: [build, install-runsim] steps: - - uses: actions/checkout@v2 - - uses: actions/setup-go@v2.1.3 + - uses: actions/checkout@v3 + - uses: actions/setup-go@v3.2.1 with: go-version: 1.18 - name: Display go version run: go version - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v6.1.0 with: SUFFIX_FILTER: | **/**.go @@ -103,13 +103,13 @@ jobs: runs-on: self-hosted needs: [build, install-runsim] steps: - - uses: actions/checkout@v2 - - uses: actions/setup-go@v2.1.3 + - uses: actions/checkout@v3 + - uses: actions/setup-go@v3.2.1 with: go-version: 1.18 - name: Display go version run: go version - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v6.1.0 with: SUFFIX_FILTER: | **/**.go @@ -131,13 +131,13 @@ jobs: runs-on: self-hosted needs: [build, install-runsim] steps: - - uses: actions/checkout@v2 - - uses: actions/setup-go@v2.1.3 + - uses: actions/checkout@v3 + - uses: actions/setup-go@v3.2.1 with: go-version: 1.18 - name: Display go version run: go version - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v6.1.0 with: SUFFIX_FILTER: | **/**.go From 5f4a626f6fb536459eadc865bb8697c113738b5d Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Mon, 29 Aug 2022 02:32:20 +0000 Subject: [PATCH 13/17] Upgrade lint version --- .github/workflows/lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 63d48c99..3a0dc54c 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -26,7 +26,7 @@ jobs: - uses: golangci/golangci-lint-action@master with: # Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version. - version: v1.39 + version: v1.47.0 args: --timeout 10m github-token: ${{ secrets.TOKEN }} if: env.GIT_DIFF From 4f31cec6c6a5859d6cb35f3b6b988bbbbd53cf96 Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Mon, 29 Aug 2022 03:26:32 +0000 Subject: [PATCH 14/17] Add tags into lint --- .golangci.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.golangci.yml b/.golangci.yml index 1ec5a363..f2913eb6 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -81,3 +81,7 @@ run: # include test files or not, default is true tests: true + # set tags for the integration tests + build-tags: + - cli_test + - cli_multi_test From 0b86cda45522073e6dc744560a7cec967bb7d02b Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Mon, 29 Aug 2022 02:43:55 +0000 Subject: [PATCH 15/17] Lint --- cli_test/cli_test.go | 31 ++++++++++++++++++++----------- cmd/lbm/cmd/root.go | 4 ++-- cmd/lbm/cmd/testnet.go | 2 +- 3 files changed, 23 insertions(+), 14 deletions(-) diff --git a/cli_test/cli_test.go b/cli_test/cli_test.go index 51e32fbd..2b8bc29f 100644 --- a/cli_test/cli_test.go +++ b/cli_test/cli_test.go @@ -554,13 +554,15 @@ func TestLBMSubmitProposal(t *testing.T) { // Query the vote vote := f.QueryGovVote(1, fooAddr) require.Equal(t, uint64(1), vote.ProposalId) - require.Equal(t, gov.OptionYes, vote.Option) + require.Equal(t, 1, len(vote.Options)) + require.Equal(t, gov.OptionYes, vote.Options[0].Option) // Query the votes votes := f.QueryGovVotes(1) require.Len(t, votes.GetVotes(), 1) require.Equal(t, uint64(1), votes.GetVotes()[0].ProposalId) - require.Equal(t, gov.OptionYes, votes.GetVotes()[0].Option) + require.Equal(t, 1, len(votes.GetVotes()[0].Options)) + require.Equal(t, gov.OptionYes, votes.GetVotes()[0].Options[0].Option) // Ensure tags are applied to voting transaction properly searchResult = f.QueryTxs(1, 50, fmt.Sprintf("--events='message.action=%s&message.sender=%s'", sdk.MsgTypeURL(&gov.MsgVote{}), fooAddr)) @@ -1236,7 +1238,8 @@ func TestLBMWasmContract(t *testing.T) { flagFromFoo := fmt.Sprintf("--from=%s", fooAddr) flagGas := "--gas=auto" flagGasAdjustment := "--gas-adjustment=1.2" - workDir, _ := os.Getwd() + workDir, err := os.Getwd() + require.NoError(t, err) tmpDir := path.Join(workDir, "tmp-dir-for-test-queue") dirContract := path.Join(workDir, "contracts", "queue") hashFile := path.Join(dirContract, "hash.txt") @@ -1251,7 +1254,8 @@ func TestLBMWasmContract(t *testing.T) { enqueueValue := 2 // make tmpDir - os.Mkdir(tmpDir, os.ModePerm) + err = os.Mkdir(tmpDir, os.ModePerm) + require.NoError(t, err) // validate that there are no code in the chain { @@ -1273,8 +1277,9 @@ func TestLBMWasmContract(t *testing.T) { queryCodesResponse := f.QueryListCodeWasm() require.Len(t, queryCodesResponse.CodeInfos, 1) - //validate the hash is the same - expectedRow, _ := ioutil.ReadFile(hashFile) + // validate the hash is the same + expectedRow, err := ioutil.ReadFile(hashFile) + require.NoError(t, err) expected, err := hex.DecodeString(string(expectedRow[:64])) require.NoError(t, err) actual := queryCodesResponse.CodeInfos[0].DataHash.Bytes() @@ -1285,14 +1290,18 @@ func TestLBMWasmContract(t *testing.T) { { outputPath := path.Join(tmpDir, "queue-tmp.wasm") f.QueryCodeWasm(codeID, outputPath) - fLocal, _ := os.Open(wasmQueue) - fChain, _ := os.Open(outputPath) + fLocal, err := os.Open(wasmQueue) + require.NoError(t, err) + fChain, err := os.Open(outputPath) + require.NoError(t, err) // 2000000 is enough length dataLocal := make([]byte, 2000000) dataChain := make([]byte, 2000000) - fLocal.Read(dataLocal) - fChain.Read(dataChain) + _, err = fLocal.Read(dataLocal) + require.NoError(t, err) + _, err = fChain.Read(dataChain) + require.NoError(t, err) require.Equal(t, dataLocal, dataChain) } @@ -1304,7 +1313,7 @@ func TestLBMWasmContract(t *testing.T) { // instantiate a contract with the code queue { - msgJSON := fmt.Sprintf("{}") + msgJSON := "{}" flagLabel := "--label=queue-test" flagAmount := fmt.Sprintf("--amount=%d%s", amountSend, denomSend) _, err := f.TxInstantiateWasm(codeID, msgJSON, flagFromFoo, flagGasAdjustment, flagGas, flagLabel, flagAmount, flagFromFoo, "-y", "--no-admin") diff --git a/cmd/lbm/cmd/root.go b/cmd/lbm/cmd/root.go index 3d95dbfc..7cfa4ff8 100644 --- a/cmd/lbm/cmd/root.go +++ b/cmd/lbm/cmd/root.go @@ -149,8 +149,8 @@ lru_size = 0` func initRootCmd(rootCmd *cobra.Command, encodingConfig params.EncodingConfig) { // Todo This is applied to https://github.com/cosmos/cosmos-sdk/pull/9299. // But it is failed in `make localnet-start`. Let's check it later. - //cfg := sdk.GetConfig() - //cfg.Seal() + // cfg := sdk.GetConfig() + // cfg.Seal() rootCmd.AddCommand( genutilcli.InitCmd(app.ModuleBasics, app.DefaultNodeHome), diff --git a/cmd/lbm/cmd/testnet.go b/cmd/lbm/cmd/testnet.go index 6e49bb67..5607c75a 100644 --- a/cmd/lbm/cmd/testnet.go +++ b/cmd/lbm/cmd/testnet.go @@ -384,7 +384,7 @@ func calculateIP(ip string, i int) (string, error) { } func writeFile(name string, dir string, contents []byte) error { - writePath := filepath.Join(dir) + writePath := dir file := filepath.Join(writePath, name) err := ostos.EnsureDir(writePath, 0755) From 1ec3b4966e794c81af509c28d3fcbb23490a0384 Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Thu, 1 Sep 2022 02:27:02 +0000 Subject: [PATCH 16/17] Use latest golang 1.18 image --- Dockerfile | 2 +- contrib/Dockerfile.test | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index b6bdd9d1..7c0f5c56 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ # > docker build --platform="linux/amd64" -t line/lbm . # > docker run -it -p 26656:26656 -p 26657:26657 -v ~/.lbm:/root/.lbm -v line/lbm lbm init # > docker run -it -p 26656:26656 -p 26657:26657 -v ~/.lbm:/root/.lbm -v line/lbm lbm start --rpc.laddr=tcp://0.0.0.0:26657 --p2p.laddr=tcp://0.0.0.0:26656 -FROM golang:1.18.5-alpine AS build-env +FROM golang:1.18-alpine AS build-env ARG LBM_BUILD_OPTIONS="" # Set up OS dependencies diff --git a/contrib/Dockerfile.test b/contrib/Dockerfile.test index d10c0b11..ed03aaec 100644 --- a/contrib/Dockerfile.test +++ b/contrib/Dockerfile.test @@ -2,7 +2,7 @@ # > docker build -t link . # > docker run -it -p 46657:46657 -p 46656:46656 -v ~/.lbm:/root/.lbm -v ~/.linkcli:/root/.linkcli link lbm init # > docker run -it -p 46657:46657 -p 46656:46656 -v ~/.lbm:/root/.lbm -v ~/.linkcli:/root/.linkcli link lbm start -FROM golang:1.18.5-alpine AS build-env +FROM golang:1.18-alpine AS build-env # Set up dependencies ENV PACKAGES curl make git libc-dev bash gcc linux-headers eudev-dev python3 From a350284a44027a7179c62a70128a1230ae0e0b6c Mon Sep 17 00:00:00 2001 From: Youngtaek Yoon Date: Thu, 1 Sep 2022 03:20:24 +0000 Subject: [PATCH 17/17] Use versioned lint-action --- .github/workflows/lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 3a0dc54c..8d41004d 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -23,7 +23,7 @@ jobs: - uses: actions/setup-go@v3.2.1 with: go-version: 1.18 - - uses: golangci/golangci-lint-action@master + - uses: golangci/golangci-lint-action@v3 with: # Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version. version: v1.47.0