Skip to content
Open
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
60 changes: 60 additions & 0 deletions .github/workflows/bindings.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Bindings

on:
push:
branches:
- main
paths:
- "build/lint.go"
- "bindings/**"
- "contracts/**"
- ".github/workflows/bindings.yml"
pull_request:
paths:
- "build/lint.go"
- "bindings/**"
- "contracts/**"
- ".github/workflows/bindings.yml"

permissions:
contents: read

jobs:
generate-and-test:
name: generate and test
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: 1.24.x
- name: Install Node
uses: actions/setup-node@v4
with:
node-version: 18.x
cache: yarn
cache-dependency-path: contracts/yarn.lock
- name: Install pinned Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly-2024-02-23
- name: Install pinned abigen
run: |
mkdir -p "$RUNNER_TEMP/bin"
GOBIN="$RUNNER_TEMP/bin" go install github.com/ethereum/go-ethereum/cmd/abigen@v1.14.6
echo "$RUNNER_TEMP/bin" >> "$GITHUB_PATH"
- name: Regenerate bindings
run: |
yarn --cwd contracts verify:abi-archive
make -C bindings all
yarn --cwd contracts verify:abi-archive
- name: Verify generated files are committed
run: >-
git diff --exit-code --
bindings/bindings bindings/bin contracts/abi/archive
- name: Run bindings tests
run: make -C bindings test
- name: Lint bindings
run: make -C bindings lint
4 changes: 2 additions & 2 deletions .github/workflows/cherry-pick.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
if: ${{ contains(github.event.pull_request.labels.*.name, 'release/0.1.x') && github.event.pull_request.merged == true }}
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Cherry pick into release/0.1.x
Expand All @@ -31,7 +31,7 @@ jobs:
if: ${{ contains(github.event.pull_request.labels.*.name, 'release/0.2.x') && github.event.pull_request.merged == true }}
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Cherry pick into release/0.2.x
Expand Down
37 changes: 37 additions & 0 deletions .github/workflows/common.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Common

on:
push:
branches:
- main
paths:
- "bindings/**"
- "common/**"
- "node/derivation/testdata/rollup_calldata_fixtures.json"
- ".github/workflows/common.yml"
pull_request:
paths:
- "bindings/**"
- "common/**"
- "node/derivation/testdata/rollup_calldata_fixtures.json"
- ".github/workflows/common.yml"

permissions:
contents: read

defaults:
run:
working-directory: "common"

jobs:
test:
name: race tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: 1.24.x
- name: Run tests with race detector
run: go test -race ./...
21 changes: 14 additions & 7 deletions .github/workflows/contracts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,15 @@ on:
branches:
- main
paths:
- "build/**"
- "contracts/**"
- ".github/workflows/contracts.yaml"
- ".github/workflows/contracts.yml"
pull_request:
paths:
- "build/**"
- "contracts/**"
- "ops/l2-genesis/**"
- ".github/workflows/contracts.yaml"
- ".github/workflows/contracts.yml"

permissions:
contents: read
Expand All @@ -26,25 +27,31 @@ jobs:
if: github.event.pull_request.draft == false
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install Node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 18.x
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: 1.24.x
- name: Install Solhint
run: npm install -g solhint
- name: Lint
- name: Lint Solidity
run: make lint-sol
- name: Lint Go
run: make lint-go

test:
runs-on: ubuntu-latest
env:
FORCE_COLOR: 1
GAS: true
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install Node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 18.x
- name: Install Go
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/deployer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,16 @@ on:
branches:
- main
paths:
- "build/**"
- "ops/l2-genesis/**"
- ".github/workflows/deployer.yaml"
- ".github/workflows/deployer.yml"
pull_request:
paths:
- "build/**"
- "bindings/**"
- "node/**"
- "ops/l2-genesis/**"
- ".github/workflows/deployer.yaml"
- ".github/workflows/deployer.yml"

permissions:
contents: read
Expand All @@ -27,7 +28,7 @@ jobs:
if: github.event.pull_request.draft == false
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install Go
uses: actions/setup-go@v5
with:
Expand All @@ -39,7 +40,7 @@ jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install Go
uses: actions/setup-go@v5
with:
Expand Down
22 changes: 19 additions & 3 deletions .github/workflows/gas-oracle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,15 @@ on:
- main
paths:
- "gas-oracle/**"
- ".github/workflows/gas-oracle.yaml"
- "node/derivation/testdata/rollup_calldata_fixtures.json"
- "ops/docker/Dockerfile.oracle"
- ".github/workflows/gas-oracle.yml"
pull_request:
paths:
- "gas-oracle/**"
- ".github/workflows/gas-oracle.yaml"
- "node/derivation/testdata/rollup_calldata_fixtures.json"
- "ops/docker/Dockerfile.oracle"
- ".github/workflows/gas-oracle.yml"

permissions:
contents: read
Expand All @@ -23,8 +27,20 @@ jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install pinned Rust toolchain
uses: dtolnay/rust-toolchain@master
with:
toolchain: 1.91.0
components: rustfmt, clippy
- name: Run build
run: make build
- name: Run tests
run: make test
- name: Check formatting
run: make fmt
- name: Run clippy
run: make clippy
- name: Build oracle container
working-directory: ${{ github.workspace }}
run: docker build -f ops/docker/Dockerfile.oracle .
9 changes: 5 additions & 4 deletions .github/workflows/node.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,16 @@ on:
branches:
- main
paths:
- "build/**"
- "node/**"
- ".github/workflows/node.yaml"
- ".github/workflows/node.yml"
pull_request:
paths:
- "build/**"
- "bindings/**"
- "node/**"
- "ops/l2-genesis/**"
- ".github/workflows/node.yaml"
- ".github/workflows/node.yml"

permissions:
contents: read
Expand All @@ -27,7 +28,7 @@ jobs:
if: github.event.pull_request.draft == false
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install Go
uses: actions/setup-go@v5
with:
Expand All @@ -39,7 +40,7 @@ jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install Go
uses: actions/setup-go@v5
with:
Expand Down
52 changes: 52 additions & 0 deletions .github/workflows/ops.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Ops

on:
push:
branches:
- main
paths:
- "build/**"
- "node/ops-morph/**"
- "ops/devnet-morph/**"
- "ops/docker/**"
- "ops/tools/**"
- ".github/workflows/ops.yml"
pull_request:
paths:
- "build/**"
- "node/ops-morph/**"
- "ops/devnet-morph/**"
- "ops/docker/**"
- "ops/tools/**"
- ".github/workflows/ops.yml"

permissions:
contents: read

jobs:
go-lint:
name: ops tools lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: 1.24.x
- name: Lint ops tools
run: make -C ops/tools lint

devnet-config:
name: devnet config tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run deterministic devnet tests
run: python3 -m unittest discover -s ops/devnet-morph/tests -v
- name: Validate Compose configuration
working-directory: ops/docker
run: >-
docker compose
-f docker-compose-devnet.yml
-f docker-compose-cluster.yml
config --quiet
35 changes: 27 additions & 8 deletions .github/workflows/prover.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@ on:
branches:
- main
paths:
- "node/derivation/testdata/rollup_calldata_fixtures.json"
- "prover/**"
- ".github/workflows/prover.yaml"
- ".github/workflows/prover.yml"
pull_request:
paths:
- "node/derivation/testdata/rollup_calldata_fixtures.json"
- "prover/**"
- ".github/workflows/prover.yaml"
- ".github/workflows/prover.yml"

permissions:
contents: read
Expand All @@ -26,15 +28,32 @@ jobs:
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: rustup component add rustfmt --toolchain nightly-2024-07-07
- run: cargo fmt --all --check
- uses: dtolnay/rust-toolchain@master
with:
toolchain: nightly-2024-07-07
components: rustfmt
- name: Check shadow-prove formatting
run: cargo +nightly-2024-07-07 fmt --package shadow-proving --check
- name: Check challenge formatting
run: >-
cargo +nightly-2024-07-07 fmt
--manifest-path bin/challenge/Cargo.toml
--check

build:
name: build
runs-on: ubuntu-latest
timeout-minutes: 30
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: make build-shadow-prove && make build-shadow-prove
- uses: dtolnay/rust-toolchain@master
with:
toolchain: 1.91.0
- name: Build shadow-prove
run: make build-shadow-prove
- name: Test shadow-prove
run: cargo test --manifest-path bin/shadow-prove/Cargo.toml
- name: Build challenge
run: make build-challenge
- name: Test challenge
run: cargo test --manifest-path bin/challenge/Cargo.toml
Loading
Loading