wealdtech / ethereal

Apache License 2.0
208 stars 41 forks source link

Current build fails on latest golang #11

Closed ralphreijs closed 5 years ago

ralphreijs commented 5 years ago

When trying to install / compile the current version of ethereal on the latest version of golang, the process crashes. This happens on macOS Mojave (latest version) and has been confirmed by a friend to happen as well on a docker container of golang:latest.

The error is:

MacBook-Pro:~ $ go get github.com/wealdtech/ethereal
# github.com/wealdtech/ethereal/util
go/src/github.com/wealdtech/ethereal/util/gasprice.go:61:38: block.Time().Int64 undefined (type uint64 has no field or method Int64)
# github.com/wealdtech/ethereal/cli
go/src/github.com/wealdtech/ethereal/cli/wallet.go:85:39: not enough arguments in call to accounts.NewManager
    have ([]accounts.Backend...)
    want (*accounts.Config, ...accounts.Backend)
go/src/github.com/wealdtech/ethereal/cli/wallet.go:103:39: not enough arguments in call to accounts.NewManager
    have ([]accounts.Backend...)
    want (*accounts.Config, ...accounts.Backend)
go/src/github.com/wealdtech/ethereal/cli/wallet.go:130:39: not enough arguments in call to accounts.NewManager
    have ([]accounts.Backend...)
    want (*accounts.Config, ...accounts.Backend)
go/src/github.com/wealdtech/ethereal/cli/wallet.go:159:39: not enough arguments in call to accounts.NewManager
    have ([]accounts.Backend...)
    want (*accounts.Config, ...accounts.Backend)
go/src/github.com/wealdtech/ethereal/cli/wallet.go:171:39: not enough arguments in call to accounts.NewManager
    have ([]accounts.Backend...)
    want (*accounts.Config, ...accounts.Backend)
ralphreijs commented 5 years ago

Manual go build also fails, same error.

mcdee commented 5 years ago

Unfortunately the upstream go-ethereum keeps tweaking their API so ethereal occasionally breaks as a result.

There is a v2 branch of ethereal that uses go modules to lock down versions. Please could you try fetch an up-to-date copy of ethereal, switching the to v2 branch, and seeing if that compiles with a go build? Thanks.

ralphreijs commented 5 years ago

So I'm on a bad wifi connection here and was trying to download all dependencies for the last hour. Finally the connection improved, but now it gives a different error almost immediately.

This is how far it came before:

MacBook-Pro:test $ git clone --single-branch --branch v2 https://github.com/wealdtech/ethereal.git
MacBook-Pro:test $ cd ethereum
MacBook-Pro:ethereal $ go build
go: finding github.com/ethereum/go-ethereum v1.8.23
go: finding github.com/shurcooL/issuesapp v0.0.0-20181229001453-b8198a402c58
go: finding github.com/gogo/protobuf v1.2.1
go: finding github.com/sirupsen/logrus v1.3.0
go: finding github.com/coreos/etcd v3.3.12+incompatible
go: finding github.com/mattn/go-colorable v0.1.1
go: finding golang.org/x/build v0.0.0-20190307215223-c78805dbabc8
go: finding golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a
go: finding golang.org/x/text v0.3.0
go: finding cloud.google.com/go v0.36.0
go: finding github.com/huin/goupnp v1.0.0
go: finding github.com/shurcooL/highlight_go v0.0.0-20181215221002-9d8641ddf2e1
go: finding github.com/russross/blackfriday v2.0.0+incompatible
go: finding github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6
go: finding github.com/coreos/go-etcd v2.0.0+incompatible
go: finding golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563
go: finding golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33
go: finding github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57
go: finding github.com/spf13/jwalterweatherman v1.0.0
go: finding golang.org/x/net v0.0.0-20190301231341-16b79f2e4e95
go: finding github.com/gopherjs/gopherjs v0.0.0-20181103185306-d547d1d9531e
go: finding github.com/fsnotify/fsnotify v1.4.7
go: finding golang.org/x/sys v0.0.0-20190308023053-584f3b12f43e
go: finding github.com/BurntSushi/toml v0.3.1
go: finding github.com/konsorten/go-windows-terminal-sequences v1.0.1
go: finding golang.org/x/crypto v0.0.0-20181030102418-4d3f4d9ffa16
go: finding github.com/shurcooL/notifications v0.0.0-20181007000457-627ab5aea122
go: finding github.com/shurcooL/issues v0.0.0-20181008053335-6292fdc1e191
go: finding golang.org/x/perf v0.0.0-20180704124530-6e6d33e29852
go: finding dmitri.shuralyov.com/app/changes v0.0.0-20181114035150-5af16e21babb
go: finding github.com/coreos/etcd v3.3.10+incompatible
go: finding dmitri.shuralyov.com/service/change v0.0.0-20181023043359-a85b471d5412
go: finding github.com/antlr/antlr4 v0.0.0-20190223165740-dade65a895c2
go: finding golang.org/x/net v0.0.0-20181220203305-927f97764cc3
go: finding github.com/googleapis/gax-go/v2 v2.0.3
go: finding github.com/neelance/astrewrite v0.0.0-20160511093645-99348263ae86
go: finding github.com/shurcooL/highlight_diff v0.0.0-20170515013008-09bb4053de1b
go: finding google.golang.org/appengine v1.2.0
go: finding github.com/magiconair/properties v1.8.0
go: finding github.com/stretchr/testify v1.2.2
go: finding github.com/shurcooL/home v0.0.0-20181020052607-80b7ffcb30f9
go: finding dmitri.shuralyov.com/app/changes v0.0.0-20180602232624-0a106ad413e3
go: finding github.com/golang/mock v1.2.0
go: finding github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7
go: finding google.golang.org/api v0.0.0-20181030000543-1d582fd0359e
go: finding go4.org v0.0.0-20180809161055-417644f6feb5
go: finding cloud.google.com/go v0.31.0
go: finding github.com/tarm/serial v0.0.0-20180830185346-98f6abe2eb07
go: finding go.opencensus.io v0.18.0
go: finding github.com/stretchr/objx v0.1.1
go: finding google.golang.org/grpc v1.16.0
go: finding github.com/googleapis/gax-go v2.0.0+incompatible
go: finding github.com/mattn/go-isatty v0.0.5
go: finding github.com/client9/misspell v0.3.4
go: finding golang.org/x/net v0.0.0-20181029044818-c44066c5c816
go: finding github.com/prometheus/common v0.0.0-20180801064454-c7de2306084e
go: finding dmitri.shuralyov.com/state v0.0.0-20180228185332-28bcc343414c
go: finding github.com/prometheus/prometheus v2.1.0+incompatible
go: finding golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9
go: finding cloud.google.com/go v0.34.0
go: finding github.com/google/go-cmp v0.2.0
go: finding github.com/kisielk/errcheck v1.1.0
go: finding github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8
go: finding golang.org/x/tools v0.0.0-20190308142131-b40df0fb21c3
go: finding github.com/google/martian v2.1.0+incompatible
go: finding github.com/neelance/sourcemap v0.0.0-20151028013722-8c68805598ab
go: finding github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77
go: finding github.com/microcosm-cc/bluemonday v1.0.1
go: finding github.com/spf13/afero v1.1.2
go: finding google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8
go: finding github.com/shurcooL/issuesapp v0.0.0-20180602232740-048589ce2241
go: finding google.golang.org/genproto v0.0.0-20190201180003-4b09977fb922
go: finding github.com/shurcooL/gopherjslib v0.0.0-20160914041154-feb6d3990c2c
go: finding sourcegraph.com/sourcegraph/go-diff v0.5.0
go: finding google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19
go: finding github.com/grpc-ecosystem/grpc-gateway v1.5.0
go: finding golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223
go: finding cloud.google.com/go v0.26.0
go: finding github.com/ghodss/yaml v1.0.0
go: finding github.com/jellevandenhooff/dkim v0.0.0-20150330215556-f50fe3d243e1
go: finding github.com/spf13/cast v1.3.0
go: finding github.com/openzipkin/zipkin-go v0.1.3
go: finding github.com/sergi/go-diff v1.0.0
go: finding golang.org/x/sys v0.0.0-20180830151530-49385e6e1522
go: finding gopkg.in/inf.v0 v0.9.1
go: finding github.com/mitchellh/mapstructure v1.1.2
go: finding github.com/prometheus/client_golang v0.9.3-0.20190127221311-3c4408c8b829
go: finding gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127
go: finding github.com/prometheus/client_golang v0.8.0
go: finding google.golang.org/appengine v1.1.0
go: finding golang.org/x/net v0.0.0-20190125091013-d26f9f9a57f3
go: finding github.com/mr-tron/base58 v1.1.0
go: finding golang.org/x/net v0.0.0-20190213061140-3a22650c66bd
go: finding golang.org/x/sys v0.0.0-20181029174526-d69651ed3497
go: finding google.golang.org/genproto v0.0.0-20180831171423-11092d34479b
go: finding github.com/prometheus/procfs v0.0.0-20190306233201-d0f344d83b0c
go: finding google.golang.org/appengine v1.4.0
go: finding google.golang.org/grpc v1.17.0
go: finding github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1
go: finding github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af
go: finding github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568
go: finding golang.org/x/lint v0.0.0-20180702182130-06c8688daad7
go: finding golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52
go: finding git.apache.org/thrift.git v0.12.0
go: finding github.com/kisielk/gotool v1.0.0
go: finding git.apache.org/thrift.git v0.0.0-20180902110319-2566ecd5d999
go: finding gopkg.in/yaml.v2 v2.2.1
go: finding github.com/prometheus/procfs v0.0.0-20180725123919-05ee40e3a273
go: finding github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e
go: finding golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f
go: finding github.com/hashicorp/hcl v1.0.0
go: finding golang.org/x/tools v0.0.0-20181030000716-a0a13e073c7b
go: finding github.com/ugorji/go/codec v0.0.0-20190204201341-e444a5086c43
go: finding github.com/gogo/protobuf v1.1.1
go: finding gopkg.in/resty.v1 v1.12.0
go: finding github.com/wealdtech/go-erc1820 v1.1.0
go: github.com/wealdtech/go-erc1820@v1.1.0: unknown revision v1.1.0
go: finding github.com/gliderlabs/ssh v0.1.1
go: finding github.com/hashicorp/golang-lru v0.5.0
go: finding google.golang.org/grpc v1.14.0
go: finding golang.org/x/sys v0.0.0-20181218192612-074acd46bca6
go: finding github.com/wealdtech/go-ens v1.0.0
go: github.com/wealdtech/go-ens@v1.0.0: unknown revision v1.0.0
go: finding golang.org/x/net v0.0.0-20180826012351-8a410e7b638d
go: finding github.com/gxed/hashland/keccakpg v0.0.1
go: finding github.com/shurcooL/component v0.0.0-20170202220835-f88ec8f54cc4
go: finding golang.org/x/build v0.0.0-20190111050920-041ab4dc3f9d
go: finding github.com/shurcooL/highlight_go v0.0.0-20181028180052-98c3abbbae20
go: finding golang.org/x/net v0.0.0-20180906233101-161cd47e91fd
go: finding google.golang.org/api v0.1.0
go: finding github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1
go: finding google.golang.org/api v0.0.0-20180910000450-7ca32eb868bf
go: finding github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973
go: finding github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041
go: finding golang.org/x/time v0.0.0-20181108054448-85acf8d2951c
go: finding github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a
go: finding github.com/shurcooL/octicon v0.0.0-20181028054416-fa4f57f9efb2
go: finding github.com/eapache/go-resiliency v1.1.0
go: finding github.com/ugorji/go v1.1.2
go: finding github.com/shurcooL/github_flavored_markdown v0.0.0-20181002035957-2122de532470
go: finding github.com/pmezard/go-difflib v1.0.0
go: finding golang.org/x/oauth2 v0.0.0-20181017192945-9dcd33a902f4
go: finding github.com/pierrec/lz4 v2.0.5+incompatible
go: finding golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be
go: finding google.golang.org/appengine v1.3.0
go: finding gopkg.in/yaml.v2 v2.2.2
go: finding github.com/coreos/go-systemd v0.0.0-20181012123002-c6f51f82210d
go: finding github.com/kr/pty v1.1.3
go: finding github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db
go: finding gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7
go: finding github.com/shurcooL/httperror v0.0.0-20170206035902-86b7830d14cc
go: finding google.golang.org/genproto v0.0.0-20181219182458-5a97ab628bfb
go: finding google.golang.org/genproto v0.0.0-20181029155118-b69ba1387ce2
go: finding golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2
go: finding github.com/huin/goutil v0.0.0-20170803182201-1ca381bf3150
go: finding github.com/DataDog/zstd v1.3.5
go: finding golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4
go: finding github.com/anmitsu/go-shlex v0.0.0-20161002113705-648efa622239
go: finding github.com/shurcooL/webdavfs v0.0.0-20170829043945-18c3829fa133
go: finding github.com/shurcooL/events v0.0.0-20181021180414-410e4ca65f48
go: finding github.com/dustin/go-humanize v1.0.0
go: finding golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8
go: finding github.com/google/go-querystring v1.0.0
go: finding honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a
go: finding github.com/sourcegraph/annotate v0.0.0-20160123013949-f4cad6c6324d
go: finding github.com/eapache/queue v1.1.0
go: finding gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405
go: finding github.com/golang/lint v0.0.0-20180702182130-06c8688daad7
go: finding github.com/davecgh/go-spew v1.1.1
go: finding golang.org/x/crypto v0.0.0-20190211182817-74369b46fc67
go: finding github.com/openzipkin/zipkin-go v0.1.1
go: finding github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c
go: finding github.com/shurcooL/gofontwoff v0.0.0-20180329035133-29b52fc0a18d
go: finding honnef.co/go/tools v0.0.0-20180920025451-e3ad64cb4ed3
go: finding github.com/shurcooL/home v0.0.0-20190204141146-5c8ae21d4240
go: finding github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f
go: finding golang.org/x/crypto v0.0.0-20190228161510-8dd112bcdc25
go: finding github.com/shurcooL/httpfs v0.0.0-20171119174359-809beceb2371
go: finding github.com/kr/pretty v0.1.0
go: finding golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8
go: finding golang.org/x/oauth2 v0.0.0-20181203162652-d668ce993890
go: finding honnef.co/go/tools v0.0.0-20180728063816-88497007e858
go: finding golang.org/x/net v0.0.0-20181011144130-49bb7cea24b1
go: finding github.com/stretchr/testify v1.3.0
go: finding github.com/shurcooL/users v0.0.0-20180125191416-49c67e49c537
go: finding github.com/google/go-github v17.0.0+incompatible
go: finding github.com/minio/sha256-simd v0.0.0-20190131020904-2d45a736cd16
go: finding github.com/google/uuid v1.0.0
go: finding golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e
go: finding google.golang.org/api v0.0.0-20181220000619-583d854617af
go: finding github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910
go: finding github.com/shurcooL/sanitized_anchor_name v0.0.0-20170918181015-86672fcb3f95
go: finding github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1
go: finding github.com/gxed/hashland/murmur3 v0.0.1
go: finding github.com/pelletier/go-toml v1.2.0
go: finding github.com/bradfitz/go-smtpd v0.0.0-20170404230938-deb6d6237625
go: finding github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b
go: finding golang.org/x/tools v0.0.0-20180221164845-07fd8470d635
go: finding github.com/coreos/go-semver v0.2.0
go: finding golang.org/x/lint v0.0.0-20181217174547-8f45f776aaf1
go: finding github.com/grpc-ecosystem/grpc-gateway v1.6.2
go: finding github.com/shurcooL/htmlg v0.0.0-20170918183704-d01228ac9e50
go: finding github.com/matttproud/golang_protobuf_extensions v1.0.1
go: finding github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21
go: finding golang.org/x/tools v0.0.0-20181219222714-6e267b5cc78e
go: finding google.golang.org/grpc v1.19.0
go: finding golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e
go: finding github.com/shurcooL/reactions v0.0.0-20181006231557-f2e0b4ca5b82
go: finding golang.org/x/crypto v0.0.0-20180904163835-0709b304e793
go: finding golang.org/x/sys v0.0.0-20190219092855-153ac476189d
go: finding github.com/shurcooL/gofontwoff v0.0.0-20181114050219-180f79e6909d
go: finding github.com/prometheus/common v0.2.0
go: finding github.com/gorilla/mux v1.7.0
go: finding golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2
go: finding github.com/sourcegraph/syntaxhighlight v0.0.0-20170531221838-bd320f5d308e
go: finding github.com/Shopify/toxiproxy v2.1.4+incompatible
go: finding golang.org/x/net v0.0.0-20180724234803-3673e40ba225
go: finding github.com/shurcooL/httpgzip v0.0.0-20180522190206-b1c53ac65af9
go: finding sourcegraph.com/sqs/pbtypes v0.0.0-20180604144634-d3ebe8f20ae4
go: finding dmitri.shuralyov.com/html/belt v0.0.0-20180602232347-f7d459c86be0
go: finding github.com/golang/mock v1.1.1
go: finding grpc.go4.org v0.0.0-20170609214715-11d0a25b4919
go: error loading module requirements

The error it is giving right now is this one:

MacBook-Pro:ethereal $ go build
go: finding github.com/wealdtech/go-ens v1.0.0
go: finding github.com/wealdtech/go-erc1820 v1.2.0
go: github.com/wealdtech/go-erc1820@v1.2.0: unknown revision v1.2.0
go: github.com/wealdtech/go-ens@v1.0.0: unknown revision v1.0.0
go: error loading module requirements
ralphreijs commented 5 years ago

I am unfamiliar with Go and dependencies but I presume it has cached them ones that were successful and I'm only seeing the errors now? I looked at the two repos mentioned in the current error and don't see them. Guess they might have changed to private?

mcdee commented 5 years ago

Sorry yeah they were private. I've made them public so they should be available now.

ralphreijs commented 5 years ago

Worked :) I can build and install. Thanks a lot!