Skip to content

Commit 0b5bb1a

Browse files
committed
Merge branch 'dev' into pr3563
2 parents 9ebf456 + b594347 commit 0b5bb1a

File tree

35 files changed

+17589
-8498
lines changed

35 files changed

+17589
-8498
lines changed

.circleci/config.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,19 @@ jobs:
194194
command: make citest fork=whisk
195195
- store_test_results:
196196
path: tests/core/pyspec/test-reports
197+
test-eip7594:
198+
docker:
199+
- image: circleci/python:3.9
200+
working_directory: ~/specs-repo
201+
steps:
202+
- restore_cache:
203+
key: v3-specs-repo-{{ .Branch }}-{{ .Revision }}
204+
- restore_pyspec_cached_venv
205+
- run:
206+
name: Run py-tests
207+
command: make citest fork=eip7594
208+
- store_test_results:
209+
path: tests/core/pyspec/test-reports
197210
table_of_contents:
198211
docker:
199212
- image: circleci/node:10.16.3
@@ -323,6 +336,9 @@ workflows:
323336
- test-whisk:
324337
requires:
325338
- install_pyspec_test
339+
- test-eip7594:
340+
requires:
341+
- install_pyspec_test
326342
- table_of_contents
327343
- codespell
328344
- lint:

.github/workflows/run-tests.yml

Lines changed: 1 addition & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -66,43 +66,12 @@ jobs:
6666
- name: Run linter for test generators
6767
run: make lint_generators
6868

69-
dockerfile-test:
70-
runs-on: self-hosted
71-
needs: preclear
72-
services:
73-
registry:
74-
image: registry:2
75-
ports:
76-
- 5000:5000
77-
steps:
78-
- name: Checkout this repo
79-
uses: actions/[email protected]
80-
- name: get git commit hash
81-
id: git_commit_hash
82-
shell: bash
83-
run: |
84-
echo "git_commit_hash=$(echo $(git log --pretty=format:'%h' -n 1))" >> $GITHUB_OUTPUT
85-
- name: Set up Docker Buildx
86-
uses: docker/setup-buildx-action@v2
87-
with:
88-
driver-opts: network=host
89-
- name: Build and push to local registry
90-
uses: docker/build-push-action@v4
91-
with:
92-
context: .
93-
file: ./docker/Dockerfile
94-
push: true
95-
tags: localhost:5000/consensus-specs-dockerfile-test:${{ steps.git_commit_hash.outputs.git_commit_hash }}
96-
- name: Test the image by running the linter
97-
run: |
98-
docker run localhost:5000/consensus-specs-dockerfile-test:${{ steps.git_commit_hash.outputs.git_commit_hash }} make lint
99-
10069
pyspec-tests:
10170
runs-on: self-hosted
10271
needs: [preclear,lint,codespell,table_of_contents]
10372
strategy:
10473
matrix:
105-
version: ["phase0", "altair", "bellatrix", "capella", "deneb", "eip6110", "eip7002", "whisk"]
74+
version: ["phase0", "altair", "bellatrix", "capella", "deneb", "eip6110", "eip7002", "whisk", "eip7594"]
10675
steps:
10776
- name: Checkout this repo
10877
uses: actions/[email protected]

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ tests/core/pyspec/eth2spec/deneb/
2424
tests/core/pyspec/eth2spec/eip6110/
2525
tests/core/pyspec/eth2spec/eip7002/
2626
tests/core/pyspec/eth2spec/whisk/
27+
tests/core/pyspec/eth2spec/eip7594/
2728

2829
# coverage reports
2930
.htmlcov

configs/mainnet.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,3 +154,7 @@ BLOB_SIDECAR_SUBNET_COUNT: 6
154154
WHISK_EPOCHS_PER_SHUFFLING_PHASE: 256
155155
# `Epoch(2)`
156156
WHISK_PROPOSER_SELECTION_GAP: 2
157+
158+
# EIP7594
159+
EIP7594_FORK_VERSION: 0x06000001
160+
EIP7594_FORK_EPOCH: 18446744073709551615

configs/minimal.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,3 +153,7 @@ BLOB_SIDECAR_SUBNET_COUNT: 6
153153
# Whisk
154154
WHISK_EPOCHS_PER_SHUFFLING_PHASE: 4
155155
WHISK_PROPOSER_SELECTION_GAP: 1
156+
157+
# EIP7594
158+
EIP7594_FORK_VERSION: 0x06000001
159+
EIP7594_FORK_EPOCH: 18446744073709551615

docker/README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
## Docker related information
2+
3+
This dockerfile sets up the dependencies required to run consensus-spec tests. The docker image can be locally built with:
4+
- `docker build ./ -t $IMAGE_NAME -f ./docker/Dockerfile`
5+
6+
7+
Handy commands:
8+
- `docker run -it $IMAGE_NAME /bin/sh` will give you a shell inside the docker container to manually run any tests
9+
- `docker run $IMAGE_NAME make citest` will run the make citest command inside the docker container
10+
11+
Ideally manual running of docker containers is for advanced users, we recommend the script based approach described below for most users.
12+
13+
The `scripts/build_run_docker_tests.sh` script will cover most usecases. The script allows the user to configure the fork(altair/bellatrix/capella..), `$IMAGE_NAME` (specifies the container to use), number of cores, preset type (mainnet/minimal), and test all forks flags. Ideally, this is the main way that users interact with the spec tests instead of running it locally with varying versions of dependencies.
14+
15+
E.g:
16+
- `./build_run_test.sh --p mainnet --n 16` will run the mainnet preset tests with 16 threads
17+
- `./build_run_test.sh --a` will run all the tests across all the forks
18+
- `./build_run_test.sh --f deneb --n 16` will only run deneb tests on 16 threads
19+
20+
Results are always placed in a folder called `./testResults`. The results are `.xml` files and contain the fork they represent and the date/time they were run at.

presets/mainnet/eip7594.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Mainnet preset - EIP7594
2+
3+
# Misc
4+
# ---------------------------------------------------------------
5+
# `uint64(2**6)` (= 64)
6+
FIELD_ELEMENTS_PER_CELL: 64

0 commit comments

Comments
 (0)