From 11d03e93753a64a4669663d5f0b228f7adb1e40e Mon Sep 17 00:00:00 2001 From: Guillaume Ballet <3272758+gballet@users.noreply.github.com> Date: Wed, 31 Jul 2024 19:21:49 +0200 Subject: [PATCH 1/5] add execution spec tests in CI --- .github/workflows/spectests.yml | 72 +++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 .github/workflows/spectests.yml diff --git a/.github/workflows/spectests.yml b/.github/workflows/spectests.yml new file mode 100644 index 000000000000..31333a5caa0f --- /dev/null +++ b/.github/workflows/spectests.yml @@ -0,0 +1,72 @@ +name: Execution spec tests + +on: + push: + branches: [ master ] + pull_request: + branches: [ master, kaustinen-with-shapella ] + workflow_dispatch: + +jobs: + spectests: + runs-on: self-hosted + steps: + - uses: actions/checkout@v2 + - name: Set up Go + uses: actions/setup-go@v2 + with: + go-version: 1.22.4 + - name: Setup Python + uses: actions/setup-python@v5 + with: + python-version: '3.10' + cache: '' + - name: Fill tests + run: | + | go build -v ./cmd/evm + | git clone https://github.com/ethereum/execution-spec-tests -b verkle/main + | cd execution-spec-tests + | python3 -m venv venv + | . ./venv/bin/activate + | pip install -e ".[docs,lint,test]" + | fill --fork EIP6800Transition -n 4 --evm-dump-dir=../tmp -v -m blockchain_test --evm-bin=../evm + - name: Consume tests + run: ./evm blocktest ./tmp + + lint: + runs-on: self-hosted + steps: + - uses: actions/checkout@v2 + - name: Set up Go + uses: actions/setup-go@v2 + with: + go-version: 1.21.1 + - name: Download golangci-lint + run: wget -O- -nv https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.54.2 + - name: Lint + run: ./bin/golangci-lint run + - name: Vet + run: go vet + + test: + runs-on: self-hosted + needs: [test-process-verkle] + steps: + - uses: actions/checkout@v2 + - name: Set up Go + uses: actions/setup-go@v2 + with: + go-version: 1.21.1 + - name: Test + run: go test ./... -timeout=20m + + test-process-verkle: + runs-on: self-hosted + steps: + - uses: actions/checkout@v2 + - name: Set up Go + uses: actions/setup-go@v2 + with: + go-version: 1.21.1 + - name: Test + run: go test ./core -run=TestProcessVerkle From 60f7553c020fc2c3c469fa7b60d5ce090caf2ffc Mon Sep 17 00:00:00 2001 From: Guillaume Ballet <3272758+gballet@users.noreply.github.com> Date: Fri, 2 Aug 2024 17:44:52 +0200 Subject: [PATCH 2/5] test: python setup before go setup --- .github/workflows/spectests.yml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/workflows/spectests.yml b/.github/workflows/spectests.yml index 31333a5caa0f..f9bcf1e6d29d 100644 --- a/.github/workflows/spectests.yml +++ b/.github/workflows/spectests.yml @@ -12,15 +12,14 @@ jobs: runs-on: self-hosted steps: - uses: actions/checkout@v2 + - name: Setup Python + uses: actions/setup-python@v5 + with: + python-version: "3.10" - name: Set up Go uses: actions/setup-go@v2 with: go-version: 1.22.4 - - name: Setup Python - uses: actions/setup-python@v5 - with: - python-version: '3.10' - cache: '' - name: Fill tests run: | | go build -v ./cmd/evm From 6d16e44066c4db69912044224dda6366a654e348 Mon Sep 17 00:00:00 2001 From: Guillaume Ballet <3272758+gballet@users.noreply.github.com> Date: Sat, 3 Aug 2024 09:53:34 +0200 Subject: [PATCH 3/5] try with pypy --- .github/workflows/spectests.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/spectests.yml b/.github/workflows/spectests.yml index f9bcf1e6d29d..5a2b39cc3954 100644 --- a/.github/workflows/spectests.yml +++ b/.github/workflows/spectests.yml @@ -15,20 +15,20 @@ jobs: - name: Setup Python uses: actions/setup-python@v5 with: - python-version: "3.10" + python-version: 'pypy3.10' - name: Set up Go uses: actions/setup-go@v2 with: go-version: 1.22.4 - name: Fill tests run: | - | go build -v ./cmd/evm - | git clone https://github.com/ethereum/execution-spec-tests -b verkle/main - | cd execution-spec-tests - | python3 -m venv venv - | . ./venv/bin/activate - | pip install -e ".[docs,lint,test]" - | fill --fork EIP6800Transition -n 4 --evm-dump-dir=../tmp -v -m blockchain_test --evm-bin=../evm + go build -v ./cmd/evm + git clone https://github.com/ethereum/execution-spec-tests -b verkle/main + cd execution-spec-tests + python3 -m venv venv + . ./venv/bin/activate + pip install -e ".[docs,lint,test]" + fill --fork EIP6800Transition -n 4 --evm-dump-dir=../tmp -v -m blockchain_test --evm-bin=../evm - name: Consume tests run: ./evm blocktest ./tmp From 748d50ed04c8ba2d66505f04f93704f445bcc7e1 Mon Sep 17 00:00:00 2001 From: Guillaume Ballet <3272758+gballet@users.noreply.github.com> Date: Sat, 3 Aug 2024 19:10:13 +0200 Subject: [PATCH 4/5] add cargo to path --- .github/workflows/spectests.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/spectests.yml b/.github/workflows/spectests.yml index 5a2b39cc3954..b0e522fc628c 100644 --- a/.github/workflows/spectests.yml +++ b/.github/workflows/spectests.yml @@ -22,6 +22,7 @@ jobs: go-version: 1.22.4 - name: Fill tests run: | + export PATH=$PATH:/home/devops/.cargo/bin go build -v ./cmd/evm git clone https://github.com/ethereum/execution-spec-tests -b verkle/main cd execution-spec-tests From 863c89c17a59002f8dfb6c080d8ad0bbaf074a49 Mon Sep 17 00:00:00 2001 From: Guillaume Ballet <3272758+gballet@users.noreply.github.com> Date: Sat, 3 Aug 2024 21:49:47 +0200 Subject: [PATCH 5/5] try reactivating cache --- .github/workflows/spectests.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/spectests.yml b/.github/workflows/spectests.yml index b0e522fc628c..e365e2e5b1a8 100644 --- a/.github/workflows/spectests.yml +++ b/.github/workflows/spectests.yml @@ -15,7 +15,9 @@ jobs: - name: Setup Python uses: actions/setup-python@v5 with: - python-version: 'pypy3.10' + python-version: '3.10' + # python-version: 'pypy3.10' + cache: '' - name: Set up Go uses: actions/setup-go@v2 with: