Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tracking: Cosmos sdk 0.39 #146

Closed
wants to merge 6 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
69 changes: 40 additions & 29 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,20 @@ version: 2.1
executors:
golang:
docker:
- image: circleci/golang:1.13
working_directory: /go/src/github.com/cosmwasm/wasmd
- image: circleci/golang:1.14
working_directory: /go/src/github.com/CosmWasm/wasmd
mac:
macos:
xcode: "10.3.0"
working_directory: /Users/distiller/project/src/github.com/cosmwasm/wasmd
working_directory: /Users/distiller/project/src/github.com/CosmWasm/wasmd
environment:
GO_VERSION: "1.13"
GO_VERSION: "1.14"
docs:
docker:
- image: tendermintdev/jq_curl
environment:
AWS_REGION: us-east-1


commands:
make:
parameters:
Expand Down Expand Up @@ -93,18 +92,12 @@ jobs:
paths:
- "."

integration-tests:
test-sim-multi-seed-long:
executor: golang
steps:
- checkout
- restore_cache:
keys:
- go-mod-v1-{{ checksum "go.sum" }}
- run:
name: Test CLI integration
command: |
export BUILDDIR=`pwd`/build
make test-build
- make:
target: test-sim-multi-seed-long
description: "Test Gaia multi-seed simulation (long-lived)"

test-cover:
executor: golang
Expand Down Expand Up @@ -162,14 +155,14 @@ jobs:
command: bash <(curl -s https://codecov.io/bash) -f coverage.txt

localnet:
working_directory: /home/circleci/.go_workspace/src/github.com/cosmwasm/wasmd
working_directory: /home/circleci/.go_workspace/src/github.com/CosmWasm/wasmd
machine:
image: circleci/classic:latest
environment:
GOPATH: /home/circleci/.go_workspace/
GOOS: linux
GOARCH: amd64
GO_VERSION: "1.13"
GO_VERSION: "1.14"
parallelism: 1
steps:
- checkout
Expand All @@ -184,7 +177,7 @@ jobs:
popd
set -x
make clean localnet-start
./contrib/localnet-blocks-test.sh 40 5 10 localhost
./contrib/localnet-blocks-test.sh 100 5 50 localhost



Expand Down Expand Up @@ -237,17 +230,11 @@ jobs:
no_output_timeout: 20m
command: |
sudo apt-get install -y ruby
bash -x ./contrib/gitian-build.sh all
for os in darwin linux windows; do
cp gitian-build-${os}/result/gaia-${os}-res.yml .
rm -rf gitian-build-${os}/
done
- store_artifacts:
path: /go/src/github.com/cosmwasm/wasmd/gaia-darwin-res.yml
bash -x ./contrib/gitian-build.sh multi
cp gitian-build-multi/result/gaia-multi-res.yml .
rm -rf gitian-build-multi/
- store_artifacts:
path: /go/src/github.com/cosmwasm/wasmd/gaia-linux-res.yml
- store_artifacts:
path: /go/src/github.com/cosmwasm/wasmd/gaia-windows-res.yml
path: /go/src/github.com/CosmWasm/wasmd/gaia-multi-res.yml

# FIXME: The `setup-contract-tests-data` make target is broken as it completely
# overrides the .wasmd directory.
Expand Down Expand Up @@ -292,15 +279,39 @@ workflows:
- /.*/
requires:
- setup-dependencies
# - macos-ci:
# filters:
# branches:
# only:
# - master
# - deploy-docs:
# context: gaia-docs-deployment-staging
# filters:
# branches:
# only:
# - docs-update
# - deploy-docs:
# context: gaia-docs-deployment
# filters:
# branches:
# only:
# - master
- setup-dependencies:
# filters here are needed to enable this job also for tags
filters:
tags:
only:
- /^v.*/
# - integration-tests:
# - test-sim-multi-seed-long:
# requires:
# - setup-dependencies
# # These filters ensure that the long sim only runs during release
# filters:
# branches:
# ignore: /.*/
# tags:
# only:
# - /^v.*/
- test-cover:
requires:
- setup-dependencies
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug-report.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ v Please also ensure that this is not a duplicate issue :)

## Version

<!-- git commit hash, output of `wasmcli --version`, output of `wasmd --version` -->
<!-- git commit hash, output of `wasmcli version`, output of `wasmd version` -->

## Steps to Reproduce

Expand Down
12 changes: 12 additions & 0 deletions .github/disabled_lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: Lint
on: [pull_request]
jobs:
golangci-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: golangci-lint
uses: reviewdog/action-golangci-lint@v1
with:
github_token: ${{ secrets.github_token }}
reporter: github-pr-review
17 changes: 9 additions & 8 deletions .github/workflows/linkchecker.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
name: Check links
on: [pull_request]
name: Check Markdown links
on:
schedule:
- cron: '* */24 * * *'
jobs:
link-check:
markdown-link-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Link Checker
uses: peter-evans/link-checker@v1
with:
args: -v -r *
- uses: actions/checkout@master
- uses: gaurav-nelson/github-action-markdown-link-check@0.6.0
with:
folder-path: "docs"
125 changes: 125 additions & 0 deletions .github/workflows/sims.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
name: Sims
on: [pull_request]
jobs:
cleanup-runs:
runs-on: ubuntu-latest
steps:
- uses: rokroskar/workflow-run-cleanup-action@master
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
if: "!startsWith(github.ref, 'refs/tags/') && github.ref != 'refs/heads/master'"

build:
runs-on: ubuntu-latest
if: "!contains(github.event.head_commit.message, 'skip-sims')"
steps:
- uses: actions/setup-go@v1
id: go
with:
go-version: 1.14
- name: Setup env for GO
# this is only used until the setup-go action is updated
run: |
echo "::set-env name=GOPATH::$(go env GOPATH)"
echo "::add-path::$(go env GOPATH)/bin"
echo "::set-env name=GO111MODULE::"on""
shell: bash
- name: install runsim
run: |
go get github.com/cosmos/tools/cmd/runsim@v1.0.0
- uses: actions/cache@v1
with:
path: ~/go/bin
key: ${{ runner.os }}-go-runsim-binary

test-sim-nondeterminism:
runs-on: ubuntu-latest
needs: Build
steps:
- uses: actions/setup-go@v1
id: go
with:
go-version: 1.14
- name: Setup env for GO
# this is only used until the setup-go action is updated
run: |
echo "::set-env name=GOPATH::$(go env GOPATH)"
echo "::add-path::$(go env GOPATH)/bin"
shell: bash
- uses: actions/checkout@v2
- uses: actions/cache@v1
with:
path: ~/go/bin
key: ${{ runner.os }}-go-runsim-binary
- name: test nondeterminism
run: |
make test-sim-nondeterminism

test-sim-import-export:
runs-on: ubuntu-latest
needs: Build
steps:
- uses: actions/setup-go@v1
id: go
with:
go-version: 1.14
- name: Setup env for GO
# this is only used until the setup-go action is updated
run: |
echo "::set-env name=GOPATH::$(go env GOPATH)"
echo "::add-path::$(go env GOPATH)/bin"
shell: bash
- uses: actions/checkout@v2
- uses: actions/cache@v1
with:
path: ~/go/bin
key: ${{ runner.os }}-go-runsim-binary
- name: test-sim-import-export
run: |
make test-sim-import-export

test-sim-after-import:
runs-on: ubuntu-latest
needs: Build
steps:
- uses: actions/setup-go@v1
id: go
with:
go-version: 1.14
- name: Setup env for GO
# this is only used until the setup-go action is updated
run: |
echo "::set-env name=GOPATH::$(go env GOPATH)"
echo "::add-path::$(go env GOPATH)/bin"
shell: bash
- uses: actions/checkout@v2
- uses: actions/cache@v1
with:
path: ~/go/bin
key: ${{ runner.os }}-go-runsim-binary
- name: test after import
run: |
make test-sim-after-import

test-sim-multi-seed-short:
runs-on: ubuntu-latest
needs: Build
steps:
- uses: actions/setup-go@v1
id: go
with:
go-version: 1.14
- name: Setup env for GO
# this is only used until the setup-go action is updated
run: |
echo "::set-env name=GOPATH::$(go env GOPATH)"
echo "::add-path::$(go env GOPATH)/bin"
shell: bash
- uses: actions/checkout@v2
- uses: actions/cache@v1
with:
path: ~/go/bin
key: ${{ runner.os }}-go-runsim-binary
- name: test-sim-multi-seed-short
run: |
make test-sim-multi-seed-short
56 changes: 56 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Build & Test
on: [pull_request]
jobs:
cleanup-runs:
runs-on: ubuntu-latest
steps:
- uses: rokroskar/workflow-run-cleanup-action@master
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
if: "!startsWith(github.ref, 'refs/tags/') && github.ref != 'refs/heads/master'"

test-coverage-upload:
runs-on: ubuntu-latest
if: "!contains(github.event.head_commit.message, 'skip-tests')"
steps:
- uses: actions/setup-go@v2-beta
- uses: actions/checkout@v2
- name: build
run: |
make build
- name: test & coverage report creation
run: |
go test ./... -mod=readonly -timeout 12m -race -coverprofile=coverage.txt -covermode=atomic -tags='ledger test_ledger_mock'
- name: filter out DONTCOVER
run: |
excludelist="$(find ./ -type f -name '*.go' | xargs grep -l 'DONTCOVER')"
excludelist+=" $(find ./ -type f -name '*.pb.go')"
excludelist+=" $(find ./ -type f -path './tests/mocks/*.go')"
for filename in ${excludelist}; do
filename=$(echo $filename | sed 's/^./github.com\/cosmos\/cosmos-sdk/g')
echo "Excluding ${filename} from coverage report..."
sed -i.bak "/$(echo $filename | sed 's/\//\\\//g')/d" coverage.txt
done
- uses: codecov/codecov-action@v1
with:
file: ./coverage.txt # optional
fail_ci_if_error: true

integration-tests:
runs-on: ubuntu-latest
if: "!contains(github.event.head_commit.message, 'skip-tests')"
steps:
- uses: actions/setup-go@v1
id: go
with:
go-version: 1.14
- name: Setup env for GO
# this is only used until the setup-go action is updated
run: |
echo "::set-env name=GOPATH::$(go env GOPATH)"
echo "::add-path::$(go env GOPATH)/bin"
shell: bash
- uses: actions/checkout@v2
- name: Test CLI integration
run: |
make test-build
Loading