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

Backports for 0.20 #1374

Merged
merged 12 commits into from
Jan 24, 2024
Merged
5 changes: 1 addition & 4 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,4 @@ xfast = "run --package xtask --"
xtask = "run --package xtask --release --"

[build]
rustflags = [
"-Dclippy::all",
"-Dwarnings"
]
rustflags = ["-Dclippy::all", "-Dwarnings"]
2 changes: 0 additions & 2 deletions .github/workflows/bench_applications.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,6 @@ jobs:
# 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:
lfs: true
- if: matrix.feature == 'cuda'
uses: ./.github/actions/cuda
- uses: ./.github/actions/rustup
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/bench_datasheet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,6 @@ jobs:
# 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:
lfs: true
- if: matrix.feature == 'cuda'
uses: ./.github/actions/cuda
- uses: ./.github/actions/rustup
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/bench_pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ jobs:
# 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:
lfs: true
- if: matrix.feature == 'cuda'
uses: ./.github/actions/cuda
- uses: ./.github/actions/rustup
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/bench_trends.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,6 @@ jobs:
# 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:
lfs: true
- if: matrix.feature == 'cuda'
uses: ./.github/actions/cuda
- uses: ./.github/actions/rustup
Expand Down
26 changes: 4 additions & 22 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ jobs:
- run: cargo fmt --all --check --manifest-path bonsai/examples/governance/Cargo.toml
- run: cargo fmt --all --check --manifest-path examples/Cargo.toml
- run: cargo fmt --all --check --manifest-path tools/crates-validator/Cargo.toml
- run: cargo clippy -p risc0-zkvm
- run: cargo sort --workspace --check
- run: cargo sort --workspace --check benchmarks
- run: cargo sort --workspace --check bonsai
Expand Down Expand Up @@ -154,8 +155,6 @@ jobs:
# 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:
lfs: true
- if: matrix.feature == 'cuda'
uses: ./.github/actions/cuda
- uses: ./.github/actions/rustup
Expand All @@ -165,14 +164,14 @@ jobs:
- run: cargo run --bin cargo-risczero --no-default-features -- risczero install --version $RISC0_TOOLCHAIN_VERSION
- name: build workspace
run: |
cargo test -F $FEATURE -F fault-proof -F prove --workspace --timings --no-run \
cargo test -F $FEATURE -F prove --workspace --timings --no-run \
--exclude doc-test \
--exclude bonsai-ethereum-contracts \
--exclude bonsai-ethereum-relay \
--exclude bonsai-rest-api-mock
- name: test workspace
run: |
cargo test -F $FEATURE -F fault-proof -F prove --workspace --timings \
cargo test -F $FEATURE -F prove --workspace --timings \
--exclude doc-test \
--exclude bonsai-ethereum-contracts \
--exclude bonsai-ethereum-relay \
Expand Down Expand Up @@ -204,11 +203,6 @@ jobs:
- run: cargo check -p risc0-zkvm -F $FEATURE
- run: cargo check
working-directory: external/substrate
- uses: risc0/clippy-action@main
with:
reporter: "github-pr-check"
github_token: ${{ secrets.GITHUB_TOKEN }}
clippy_flags: --features $FEATURE --all-targets
- run: sccache --show-stats

examples:
Expand Down Expand Up @@ -236,8 +230,6 @@ jobs:
# 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:
lfs: true
- if: matrix.feature == 'cuda'
uses: ./.github/actions/cuda
- uses: ./.github/actions/rustup
Expand Down Expand Up @@ -306,8 +298,6 @@ jobs:
# 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:
lfs: true
- uses: ./.github/actions/rustup
- uses: ./.github/actions/sccache
with:
Expand Down Expand Up @@ -341,11 +331,6 @@ jobs:
- uses: ./.github/actions/sccache
with:
key: macOS-default
- uses: risc0/clippy-action@main
with:
reporter: 'github-pr-check'
github_token: ${{ secrets.GITHUB_TOKEN }}
clippy_flags: --manifest-path tools/crates-validator/Cargo.toml
- run: cargo test
working-directory: tools/crates-validator
- run: sccache --show-stats
Expand All @@ -360,8 +345,6 @@ jobs:
# 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:
lfs: true
- uses: browser-actions/setup-firefox@v1
- run: firefox --version
- uses: ./.github/actions/rustup
Expand All @@ -388,8 +371,6 @@ jobs:
# 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:
lfs: true
- uses: ./.github/actions/rustup
- uses: ./.github/actions/sccache
with:
Expand All @@ -411,6 +392,7 @@ jobs:
- uses: actions/checkout@v4
with:
lfs: true
- run: git lfs pull
- uses: ./.github/actions/rustup
- uses: ./.github/actions/sccache
with:
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@ jobs:
# 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:
lfs: true
- uses: ./.github/actions/rustup
- name: Set the variables
env:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- uses: actions/checkout@v4
with:
lfs: true
- run: git lfs checkout
- run: git lfs pull
- uses: ./.github/actions/rustup
- uses: ./.github/actions/sccache
with:
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/website-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ jobs:
steps:
- uses: actions/checkout@v4
with:
lfs: true
# Recursive checkout required to build Solidity contracts and bindings.
submodules: recursive
- uses: ./.github/actions/rustup
Expand Down
1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ members = [
"risc0/circuit/rv32im",
"risc0/circuit/rv32im-sys",
"risc0/core",
"risc0/fault",
"risc0/r0vm",
"risc0/sys",
"risc0/tools",
Expand Down
2 changes: 2 additions & 0 deletions benchmarks/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions benchmarks/methods/guest/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions bonsai/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions bonsai/ethereum/contracts/BonsaiCheats.sol
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ import {CommonBase} from "forge-std/Base.sol";
import {console2} from "forge-std/console2.sol";
import {Strings2} from "murky_differential_testing/test/utils/Strings2.sol";

import {IBonsaiRelay} from "./IBonsaiRelay.sol";
import {BonsaiTestRelay} from "./BonsaiTestRelay.sol";
import {IBonsaiRelay} from "./relay/IBonsaiRelay.sol";
import {BonsaiTestRelay} from "./relay/BonsaiTestRelay.sol";

/// @notice A base contract for testing a Bonsai callback receiver contract
abstract contract BonsaiCheats is StdCheatsSafe, CommonBase {
Expand Down
8 changes: 4 additions & 4 deletions bonsai/ethereum/contracts/BonsaiTest.sol
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ import {Test} from "forge-std/Test.sol";
import {console2} from "forge-std/console2.sol";
import {Strings2} from "lib/murky/differential_testing/test/utils/Strings2.sol";

import {IBonsaiRelay, Callback, CallbackAuthorization} from "./IBonsaiRelay.sol";
import {BonsaiRelay} from "./BonsaiRelay.sol";
import {BonsaiRelayQueueWrapper} from "./BonsaiRelayQueueWrapper.sol";
import {BonsaiTestRelay} from "./BonsaiTestRelay.sol";
import {IBonsaiRelay, Callback, CallbackAuthorization} from "./relay/IBonsaiRelay.sol";
import {BonsaiRelay} from "./relay/BonsaiRelay.sol";
import {BonsaiRelayQueueWrapper} from "./relay/BonsaiRelayQueueWrapper.sol";
import {BonsaiTestRelay} from "./relay/BonsaiTestRelay.sol";
import {BonsaiCheats} from "./BonsaiCheats.sol";
import {IRiscZeroVerifier} from "./IRiscZeroVerifier.sol";
import {ControlID, RiscZeroGroth16Verifier} from "./groth16/RiscZeroGroth16Verifier.sol";
Expand Down
46 changes: 0 additions & 46 deletions bonsai/ethereum/contracts/CallbackDummy.sol

This file was deleted.