Skip to content

Commit

Permalink
update version ethermint (#80)
Browse files Browse the repository at this point in the history
* deps: bump ethermint to 0.17.3-astra (#77)

* deps: bump ethermint to 0.17.3-astra

* refactor: update Makefile

* refactor: update test workflow

* build(deps): Bump github.com/onsi/gomega from 1.19.0 to 1.20.0 (#74)

Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.19.0 to 1.20.0.
- [Release notes](https://github.com/onsi/gomega/releases)
- [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md)
- [Commits](onsi/gomega@v1.19.0...v1.20.0)

---
updated-dependencies:
- dependency-name: github.com/onsi/gomega
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* fix: update version ethermint (#79)

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
  • Loading branch information
hoanguyenkh and dependabot[bot] authored Jul 27, 2022
1 parent 0558993 commit d742421
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 70 deletions.
19 changes: 1 addition & 18 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,29 +15,12 @@ jobs:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
if: "!startsWith(github.ref, 'refs/tags/') && github.ref != 'refs/heads/main'"

install-tparse:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-go@v3
with:
go-version: 1.17
check-latest: true
- name: Display Go Version
run: go version
- name: Install tparse
run: |
export GO111MODULE="on" && go get github.com/mfridman/tparse@latest
- uses: actions/cache@v3
with:
path: ~/go/bin
key: ${{ runner.os }}-go-tparse-binary

test-unit-cover:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-go@v3
with:
go-version: 1.17
go-version: 1.18
check-latest: true
- uses: actions/checkout@v3
- uses: technote-space/get-diff-action@v6.1.0
Expand Down
74 changes: 30 additions & 44 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -188,48 +188,47 @@ RUNSIM = $(TOOLS_DESTDIR)/runsim
runsim: $(RUNSIM)
$(RUNSIM):
@echo "Installing runsim..."
@(cd /tmp && ${GO_MOD} go get github.com/cosmos/tools/cmd/runsim@master)
@(cd /tmp && ${GO_MOD} go install github.com/cosmos/tools/cmd/runsim@master)

statik: $(STATIK)
$(STATIK):
@echo "Installing statik..."
@(cd /tmp && go get github.com/rakyll/statik@v0.1.6)
@(cd /tmp && go install github.com/rakyll/statik@v0.1.6)

contract-tools:
ifeq (, $(shell which stringer))
@echo "Installing stringer..."
@go get golang.org/x/tools/cmd/stringer
@go install golang.org/x/tools/cmd/stringer@latest
else
@echo "stringer already installed; skipping..."
endif

ifeq (, $(shell which go-bindata))
@echo "Installing go-bindata..."
@go get github.com/kevinburke/go-bindata/go-bindata
@go install github.com/kevinburke/go-bindata/go-bindata@latest
else
@echo "go-bindata already installed; skipping..."
endif

ifeq (, $(shell which gencodec))
@echo "Installing gencodec..."
@go get github.com/fjl/gencodec
@go install github.com/fjl/gencodec@latest
else
@echo "gencodec already installed; skipping..."
endif

ifeq (, $(shell which protoc-gen-go))
@echo "Installing protoc-gen-go..."
@go get github.com/fjl/gencodec github.com/golang/protobuf/protoc-gen-go
@go install github.com/fjl/gencodec@latest
@go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
else
@echo "protoc-gen-go already installed; skipping..."
endif

ifeq (, $(shell which protoc))
@echo "Please istalling protobuf according to your OS"
@echo "macOS: brew install protobuf"
@echo "linux: apt-get install -f -y protobuf-compiler"
ifeq (, $(shell which protoc-gen-go-grpc))
@go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
else
@echo "protoc already installed; skipping..."
@echo "protoc-gen-go-grpc already installed; skipping..."
endif

ifeq (, $(shell which solcjs))
Expand Down Expand Up @@ -286,7 +285,7 @@ update-swagger-docs: statik
.PHONY: update-swagger-docs

godocs:
@echo "--> Wait a few seconds and visit http://localhost:6060/pkg/github.com/tharsis/astra/types"
@echo "--> Wait a few seconds and visit http://localhost:6060/pkg/github.com/AstraProtocol/astra/types"
godoc -http=:6060

# Start docs site at localhost:8080
Expand Down Expand Up @@ -418,6 +417,7 @@ benchmark:

lint:
golangci-lint run --out-format=tab
solhint contracts/**/*.sol

lint-contracts:
@cd contracts && \
Expand All @@ -431,13 +431,14 @@ lint-fix-contracts:
@cd contracts && \
npm i && \
npm run lint-fix
solhint --fix contracts/**/*.sol

.PHONY: lint lint-fix

format:
find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" -not -name '*.pb.go' | xargs gofmt -w -s
find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" -not -name '*.pb.go' | xargs misspell -w
find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" -not -name '*.pb.go' | xargs goimports -w -local github.com/tharsis/astra
find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" -not -name '*.pb.go' | xargs goimports -w -local github.com/AstraProtocol/astra
.PHONY: format

###############################################################################
Expand All @@ -456,10 +457,6 @@ proto-gen:
@echo "Generating Protobuf files"
$(DOCKER) run --rm -v $(CURDIR):/workspace --workdir /workspace tendermintdev/sdk-proto-gen sh ./scripts/protocgen.sh

proto-swagger-gen:
@echo "Generating Protobuf Swagger"
@./scripts/protoc-swagger-gen.sh

proto-format:
@echo "Formatting Protobuf files"
find ./ -not -path "./third_party/*" -name *.proto -exec clang-format -i {} \;
Expand Down Expand Up @@ -520,20 +517,9 @@ localnet-build:
@$(MAKE) -C networks/local

# Start a 4-node testnet locally
localnet-start: localnet-stop
ifeq ($(OS),Windows_NT)
mkdir localnet-setup &
@$(MAKE) localnet-build

IF not exist "build/node0/$(ASTRA_BINARY)/config/genesis.json" docker run --rm -v $(CURDIR)/build\astra\Z astrad/node "./astrad testnet --v 4 -o /astra --keyring-backend=test --ip-addresses astradnode0,astradnode1,astradnode2,astradnode3"
docker-compose up -d
else
mkdir -p localnet-setup
@$(MAKE) localnet-build

if ! [ -f localnet-setup/node0/$(ASTRA_BINARY)/config/genesis.json ]; then docker run --rm -v $(CURDIR)/localnet-setup:/astra:Z astrad/node "./astrad testnet --v 4 -o /astra --keyring-backend=test --ip-addresses astradnode0,astradnode1,astradnode2,astradnode3"; fi
localnet-start: localnet-stop localnet-build
@if ! [ -f build/node0/$(ASTRA_BINARY)/config/genesis.json ]; then docker run --rm -v $(CURDIR)/build:/astra:Z astra/node "./astrad testnet init-files --v 4 -o /astra --keyring-backend=test --starting-ip-address 192.167.10.2"; fi
docker-compose up -d
endif

# Stop testnet
localnet-stop:
Expand All @@ -542,35 +528,35 @@ localnet-stop:
# Clean testnet
localnet-clean:
docker-compose down
sudo rm -rf localnet-setup
sudo rm -rf build/*

# Reset testnet
localnet-unsafe-reset:
docker-compose down
ifeq ($(OS),Windows_NT)
@docker run --rm -v $(CURDIR)\localnet-setup\node0\astrad:astra\Z astrad/node "./astrad unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)\localnet-setup\node1\astrad:astra\Z astrad/node "./astrad unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)\localnet-setup\node2\astrad:astra\Z astrad/node "./astrad unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)\localnet-setup\node3\astrad:astra\Z astrad/node "./astrad unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)\build\node0\astrad:/astra\Z astra/node "./astrad tendermint unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)\build\node1\astrad:/astra\Z astra/node "./astrad tendermint unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)\build\node2\astrad:/astra\Z astra/node "./astrad tendermint unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)\build\node3\astrad:/astra\Z astra/node "./astrad tendermint unsafe-reset-all --home=/astra"
else
@docker run --rm -v $(CURDIR)/localnet-setup/node0/astrad:/astra:Z astrad/node "./astrad unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)/localnet-setup/node1/astrad:/astra:Z astrad/node "./astrad unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)/localnet-setup/node2/astrad:/astra:Z astrad/node "./astrad unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)/localnet-setup/node3/astrad:/astra:Z astrad/node "./astrad unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)/build/node0/astrad:/astra:Z astra/node "./astrad tendermint unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)/build/node1/astrad:/astra:Z astra/node "./astrad tendermint unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)/build/node2/astrad:/astra:Z astra/node "./astrad tendermint unsafe-reset-all --home=/astra"
@docker run --rm -v $(CURDIR)/build/node3/astrad:/astra:Z astra/node "./astrad tendermint unsafe-reset-all --home=/astra"
endif

# Clean testnet
localnet-show-logstream:
docker-compose logs --tail=1000 -f

.PHONY: build-docker-local-astra localnet-start localnet-stop
.PHONY: localnet-build localnet-start localnet-stop

###############################################################################
### Releasing ###
###############################################################################

PACKAGE_NAME:=github.com/AstraProtocol/astra
GOLANG_CROSS_VERSION = v1.17.1
GOLANG_CROSS_VERSION = v1.18
GOPATH ?= '$(HOME)/go'
release-dry-run:
docker run \
Expand All @@ -581,7 +567,7 @@ release-dry-run:
-v `pwd`:/go/src/$(PACKAGE_NAME) \
-v ${GOPATH}/pkg:/go/pkg \
-w /go/src/$(PACKAGE_NAME) \
ghcr.io/troian/golang-cross:${GOLANG_CROSS_VERSION} \
ghcr.io/goreleaser/goreleaser-cross:${GOLANG_CROSS_VERSION} \
--rm-dist --skip-validate --skip-publish --snapshot

release:
Expand All @@ -597,7 +583,7 @@ release:
-v /var/run/docker.sock:/var/run/docker.sock \
-v `pwd`:/go/src/$(PACKAGE_NAME) \
-w /go/src/$(PACKAGE_NAME) \
ghcr.io/troian/golang-cross:${GOLANG_CROSS_VERSION} \
ghcr.io/goreleaser/goreleaser-cross:${GOLANG_CROSS_VERSION} \
release --rm-dist --skip-validate

.PHONY: release-dry-run release
Expand Down Expand Up @@ -656,4 +642,4 @@ create-contracts-json:
echo $$add_contract_name | jq --arg newval "$$abi_string" '.abi = $$newval' > $(TMP_JSON) ;\
mv $(TMP_JSON) $(COMPILED_DIR)/$${c}.json ;\
done
@rm -rf tmp
@rm -rf tmp
9 changes: 5 additions & 4 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ require (
github.com/cosmos/go-bip39 v1.0.0
github.com/cosmos/ibc-go/v3 v3.1.0
github.com/ethereum/go-ethereum v1.10.17
github.com/evmos/ethermint v0.17.0
github.com/evmos/evmos/v6 v6.0.0
github.com/evmos/ethermint v0.17.2
github.com/evmos/evmos/v6 v6.0.1
github.com/gogo/protobuf v1.3.3
github.com/golang/protobuf v1.5.2
github.com/gorilla/mux v1.8.0
github.com/grpc-ecosystem/grpc-gateway v1.16.0
github.com/onsi/ginkgo/v2 v2.1.4
github.com/onsi/gomega v1.19.0
github.com/onsi/gomega v1.20.0
github.com/pkg/errors v0.9.1
github.com/rakyll/statik v0.1.7
github.com/spf13/cast v1.5.0
Expand Down Expand Up @@ -76,6 +76,7 @@ require (
github.com/golang/glog v1.0.0 // indirect
github.com/golang/snappy v0.0.4 // indirect
github.com/google/btree v1.0.1 // indirect
github.com/google/go-cmp v0.5.8 // indirect
github.com/google/orderedcode v0.0.1 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/gorilla/handlers v1.5.1 // indirect
Expand Down Expand Up @@ -158,7 +159,7 @@ require (

replace (
github.com/99designs/keyring => github.com/cosmos/keyring v1.1.7-0.20210622111912-ef00f8ac3d76
github.com/evmos/ethermint => github.com/AstraProtocol/ethermint v0.17.1-astra
github.com/evmos/ethermint => github.com/AstraProtocol/ethermint v0.17.3-astra
github.com/evmos/evmos/v6 => github.com/AstraProtocol/evmos/v6 v6.0.3-astra
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
Expand Down
9 changes: 5 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ collectd.org v0.3.0/go.mod h1:A/8DzQBkF6abtvrT2j/AU/4tiBgJWYyh0y/oB/4MlWE=
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
filippo.io/edwards25519 v1.0.0-beta.2 h1:/BZRNzm8N4K4eWfK28dL4yescorxtO7YG1yun8fy+pI=
filippo.io/edwards25519 v1.0.0-beta.2/go.mod h1:X+pm78QAUPtFLi1z9PYIlS/bdDnvbCOGKtZ+ACWEf7o=
github.com/AstraProtocol/ethermint v0.17.1-astra h1:uTCUUGaevWtTB67mT8wg4NiX4oF9v8YGVoxYd5YEjB0=
github.com/AstraProtocol/ethermint v0.17.1-astra/go.mod h1:BmXULZy8lbld5KgNE0zM4b7Dy1irPpL6nsDH11SMNzQ=
github.com/AstraProtocol/ethermint v0.17.3-astra h1:WaxcyIhdRTqpJ5MpzdC0eUkb880mTcUiU2+aafone3w=
github.com/AstraProtocol/ethermint v0.17.3-astra/go.mod h1:F7SbOTTI3Gpbhn7rWWY7hTzUfb+aF+U+lQAMgdYTZiM=
github.com/AstraProtocol/evmos/v6 v6.0.3-astra h1:gkQxTnSCzOvhq4izepQ+nq4Z7m0Czff3jrK4fbbKa5A=
github.com/AstraProtocol/evmos/v6 v6.0.3-astra/go.mod h1:e/zM/ZQzNepW6k1G6M4v9++Q7uNgPkCkzeJYoPeN4Qs=
github.com/Azure/azure-pipeline-go v0.2.1/go.mod h1:UGSo8XybXnIGZ3epmeBw7Jdz+HiUVpqIlpz/HKHylF4=
Expand Down Expand Up @@ -511,6 +511,7 @@ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/
github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE=
github.com/google/go-cmp v0.5.8 h1:e6P7q2lk1O+qJJb4BtCQXlK8vWEO8V1ZeuEdJNOqZyg=
github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
github.com/google/gofuzz v0.0.0-20170612174753-24818f796faf/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI=
github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
github.com/google/gofuzz v1.1.1-0.20200604201612-c04b05f3adfa h1:Q75Upo5UN4JbPFURXZ8nLKYUvF85dyFRop/vQ0Rv+64=
Expand Down Expand Up @@ -871,8 +872,8 @@ github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1Cpa
github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY=
github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo=
github.com/onsi/gomega v1.13.0/go.mod h1:lRk9szgn8TxENtWd0Tp4c3wjlRfMTMH27I+3Je41yGY=
github.com/onsi/gomega v1.19.0 h1:4ieX6qQjPP/BfC3mpsAtIGGlxTWPeA3Inl/7DtXw1tw=
github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro=
github.com/onsi/gomega v1.20.0 h1:8W0cWlwFkflGPLltQvLRB7ZVD5HuP6ng320w2IS245Q=
github.com/onsi/gomega v1.20.0/go.mod h1:DtrZpjmvpn2mPm4YWQa0/ALMDj9v4YxLgojwPeREyVo=
github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk=
github.com/opencontainers/go-digest v1.0.0-rc1/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s=
github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U=
Expand Down

0 comments on commit d742421

Please sign in to comment.