Skip to content

Commit

Permalink
Cherry-pick main and set version to 1.1.4 (#284)
Browse files Browse the repository at this point in the history
Cherry picks all changes to Steel since the last release of Steel.
Updates all versions to 1.1.4, including Steel.

**This PR marks the 1.0 release of Steel**

---------

Co-authored-by: capossele <angelocapossele@gmail.com>
Co-authored-by: Victor Graf <victor@risczero.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Sasha <33594434+sashaaldrick@users.noreply.github.com>
  • Loading branch information
5 people authored Oct 7, 2024
1 parent 35a6e27 commit 4fa7de0
Show file tree
Hide file tree
Showing 83 changed files with 5,505 additions and 5,096 deletions.
12 changes: 12 additions & 0 deletions .github/scripts/cargo-check.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash
set -e

fmt_sort(){
while read path; do
printf "Project: %s\n" "$path"
cargo fmt --all --check --manifest-path "$path"
(cd "${path%/*}"; cargo sort --workspace --check)
done
}

grep -rl --include "Cargo.toml" '\[workspace\]' | sort -u | fmt_sort
11 changes: 11 additions & 0 deletions .github/scripts/cargo-clippy.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/bash
set -e

clippy(){
while read path; do
printf "Project: %s\n" "$path"
cargo clippy --workspace --all-targets --all-features --manifest-path "$path"
done
}

grep -rl --include "Cargo.toml" '\[workspace\]' | sort -u | clippy
12 changes: 12 additions & 0 deletions .github/scripts/cargo-test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash
set -e

build_test(){
while read path; do
printf "Project: %s\n" "$path"
cargo build --workspace --all-features --manifest-path "$path"
cargo test --workspace --all-features --manifest-path "$path"
done
}

find . -maxdepth 2 -mindepth 2 -name 'Cargo.toml' | sort -u | build_test
11 changes: 11 additions & 0 deletions .github/scripts/forge-check.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/bash
set -e

fmt(){
while read path; do
printf "Project: %s\n" "$path"
(cd "${path%/*}"; forge fmt --check)
done
}

find . -maxdepth 2 -mindepth 2 -name 'foundry.toml' | sort -u | fmt
11 changes: 11 additions & 0 deletions .github/scripts/forge-test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/bash
set -e

test(){
while read path; do
printf "Project: %s\n" "$path"
(cd "${path%/*}"; forge test -vvvv)
done
}

find . -maxdepth 2 -mindepth 2 -name 'foundry.toml' | sort -u | test
59 changes: 0 additions & 59 deletions .github/workflows/bonsai.yml

This file was deleted.

101 changes: 101 additions & 0 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
name: Testnet

on:
merge_group:
pull_request:
branches: [main, "release-*"]
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

# this is needed to gain access via OIDC to the S3 bucket for caching
permissions:
id-token: write
contents: read

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RISC0_TOOLCHAIN_VERSION: r0.1.79.0-2
RISC0_MONOREPO_REF: "release-1.1"

jobs:
e2e-tests:
runs-on: [self-hosted, prod, "${{ matrix.os }}", "${{ matrix.device }}"]
strategy:
matrix:
prover: [bonsai, local]
release:
- ${{ startsWith(github.base_ref, 'release-') || startsWith(github.base_ref, 'refs/heads/release-') }}
# Run on Linux with GPU for faster local proving.
include:
- os: Linux
feature: cuda
device: nvidia_rtx_a5000
# Exclude Bonsai proving on non-release branches.
exclude:
- release: false
prover: bonsai
env:
RUST_BACKTRACE: full
steps:
# This is a workaround from: https://github.com/actions/checkout/issues/590#issuecomment-970586842
- run: "git checkout -f $(git -c user.name=x -c user.email=x@x commit-tree $(git hash-object -t tree /dev/null) < /dev/null) || :"
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Use Bonsai for release branches
if: matrix.prover == 'bonsai'
run: |
echo "BONSAI_API_URL=${{ secrets.BONSAI_API_URL }}" >> $GITHUB_ENV
echo "BONSAI_API_KEY=${{ secrets.BONSAI_API_KEY }}" >> $GITHUB_ENV
- if: matrix.feature == 'cuda'
uses: risc0/risc0/.github/actions/cuda@main
- uses: risc0/risc0/.github/actions/rustup@main
- uses: risc0/risc0/.github/actions/sccache@main
with:
key: ${{ matrix.os }}-${{ matrix.feature }}
- uses: risc0/foundry-toolchain@2fe7e70b520f62368a0e3c464f997df07ede420f
- uses: ./.github/actions/cargo-risczero-install
with:
ref: ${{ env.RISC0_MONOREPO_REF }}
toolchain-version: ${{ env.RISC0_TOOLCHAIN_VERSION }}
features: ${{ matrix.feature }}
- name: Setup Kurtosis
run: |
echo "deb [trusted=yes] https://apt.fury.io/kurtosis-tech/ /" | sudo tee /etc/apt/sources.list.d/kurtosis.list
sudo apt update
sudo apt install kurtosis-cli
kurtosis analytics disable
echo "$(dirname $(which kurtosis))" >> $GITHUB_PATH
shell: bash
- name: Start local Ethereum testnet
run: |
kurtosis --enclave local-eth-testnet run github.com/ethpandaops/ethereum-package@2e9e5a41784f792a206f1a108c2c96830b2c95ef
echo "ETH_TESTNET_EL_URL=http://$(kurtosis port print local-eth-testnet el-1-geth-lighthouse rpc)" >> $GITHUB_ENV
echo "ETH_TESTNET_CL_URL=$(kurtosis port print local-eth-testnet cl-1-lighthouse-geth http)" >> $GITHUB_ENV
- name: Wait for the local Ethereum testnet to come up
run: while [ $(cast rpc --rpc-url $ETH_TESTNET_EL_URL eth_blockNumber | jq -re) == "0x0" ]; do sleep 5; done
shell: bash
- run: cargo build
working-directory: examples/erc20-counter
- name: Run E2E test (Block Commitment)
run: ./e2e-test.sh
env:
ETH_RPC_URL: ${{ env.ETH_TESTNET_EL_URL }}
ETH_WALLET_ADDRESS: "0x802dCbE1B1A97554B4F50DB5119E37E8e7336417"
ETH_WALLET_PRIVATE_KEY: "0x5d2344259f42259f82d2c140aa66102ba89b57b4883ee441a8b312622bd42491"
working-directory: examples/erc20-counter
- name: Run E2E test (Beacon Commitment)
run: ./e2e-test.sh
env:
ETH_RPC_URL: ${{ env.ETH_TESTNET_EL_URL }}
BEACON_API_URL: ${{ env.ETH_TESTNET_CL_URL }}
ETH_WALLET_ADDRESS: "0x802dCbE1B1A97554B4F50DB5119E37E8e7336417"
ETH_WALLET_PRIVATE_KEY: "0x5d2344259f42259f82d2c140aa66102ba89b57b4883ee441a8b312622bd42491"
working-directory: examples/erc20-counter
- name: Stop local Ethereum testnet
if: always()
run: kurtosis enclave rm -f local-eth-testnet
- run: sccache --show-stats
Loading

0 comments on commit 4fa7de0

Please sign in to comment.