Skip to content

Commit

Permalink
chore: update foundry to v0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
dancoombs committed Jan 10, 2025
1 parent d7a2a7e commit a46042f
Show file tree
Hide file tree
Showing 11 changed files with 17 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: "nightly-fe2acca4e379793539db80e032d76ffe0110298b"
version: "v0.3.0"

# Build to generate the ABI bindings.
- name: cargo build
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/compliance.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: "nightly-fe2acca4e379793539db80e032d76ffe0110298b"
version: "v0.3.0"

- uses: KengoTODA/actions-setup-docker-compose@v1
with:
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/compliance_v06.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ jobs:
path: rundler
submodules: recursive

- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: "v0.3.0"

- uses: KengoTODA/actions-setup-docker-compose@v1
with:
version: '2.14.2'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ jobs:
if: contains( ${{ matrix.target }}, 'apple')
uses: foundry-rs/foundry-toolchain@v1
with:
version: "nightly-fe2acca4e379793539db80e032d76ffe0110298b"
version: "v0.3.0"

- name: Install protobuf
if: contains( ${{ matrix.target }}, 'apple')
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/unit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: "nightly-fe2acca4e379793539db80e032d76ffe0110298b"
version: "v0.3.0"

- name: Install latest nextest release
uses: taiki-e/install-action@nextest
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ RUN apt-get update && apt-get -y upgrade && apt-get install -y libclang-dev pkg-
SHELL ["/bin/bash", "-c"]
RUN curl -L https://foundry.paradigm.xyz | bash
ENV PATH="/root/.foundry/bin:${PATH}"
RUN foundryup -i nightly-fe2acca4e379793539db80e032d76ffe0110298b
RUN foundryup -i v0.3.0

RUN cargo install cargo-chef --locked

Expand Down
3 changes: 1 addition & 2 deletions Dockerfile.build
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ARG CROSS_BASE_IMAGE

FROM ghcr.io/foundry-rs/foundry:nightly-fe2acca4e379793539db80e032d76ffe0110298b as foundry
FROM ghcr.io/foundry-rs/foundry:v0.3.0 as foundry

FROM $CROSS_BASE_IMAGE
COPY --from=foundry /usr/local/bin/forge /usr/local/bin/forge
Expand All @@ -19,4 +19,3 @@ RUN apt-get update && apt-get install -y unzip
RUN curl -LO https://github.com/protocolbuffers/protobuf/releases/download/v3.15.8/protoc-3.15.8-linux-x86_64.zip \
&& unzip protoc-3.15.8-linux-x86_64.zip -d /usr/local \
&& chmod +x /usr/local/bin/protoc

4 changes: 2 additions & 2 deletions crates/contracts/src/v0_7.rs
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ const __ENTRY_POINT_SIMULATIONS_V0_7_DEPLOYED_BYTECODE_HEX: &[u8] = include_byte
"../contracts/out/v0_7/EntryPointSimulations.sol/EntryPointSimulations_deployedBytecode.txt"
);

const __ENTRY_POINT_SIMULATIONS_V0_7_DEPLOYED_BYTECODE: [u8; 16893] = {
const __ENTRY_POINT_SIMULATIONS_V0_7_DEPLOYED_BYTECODE: [u8; 16494] = {
match const_hex::const_decode_to_array(__ENTRY_POINT_SIMULATIONS_V0_7_DEPLOYED_BYTECODE_HEX) {
Ok(a) => a,
Err(_) => panic!("Failed to decode entry point simulations hex"),
Expand All @@ -263,7 +263,7 @@ const __CALL_GAS_ESTIMATION_PROXY_V0_7_DEPLOYED_BYTECODE_HEX: &[u8] = include_by
"../contracts/out/v0_7/CallGasEstimationProxy.sol/CallGasEstimationProxy_deployedBytecode.txt"
);

const __CALL_GAS_ESTIMATION_PROXY_V0_7_DEPLOYED_BYTECODE: [u8; 3558] = {
const __CALL_GAS_ESTIMATION_PROXY_V0_7_DEPLOYED_BYTECODE: [u8; 3421] = {
match const_hex::const_decode_to_array(__CALL_GAS_ESTIMATION_PROXY_V0_7_DEPLOYED_BYTECODE_HEX) {
Ok(a) => a,
Err(_) => panic!("Failed to decode call gas estimation proxy hex"),
Expand Down
2 changes: 1 addition & 1 deletion crates/sim/src/estimation/v0_6.rs
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,7 @@ impl CallGasEstimatorSpecialization for CallGasEstimatorSpecializationV06 {
///
/// The easiest way to get the updated value is to run this module's tests. The
/// failure will tell you the new value.
const PROXY_TARGET_OFFSET: usize = 163;
const PROXY_TARGET_OFFSET: usize = 159;

// Replaces the address of the proxy target where it appears in the proxy
// bytecode so we don't need the same fixed address every time.
Expand Down
2 changes: 1 addition & 1 deletion crates/sim/src/estimation/v0_7.rs
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ impl CallGasEstimatorSpecialization for CallGasEstimatorSpecializationV07 {
///
/// The easiest way to get the updated value is to run this module's tests. The
/// failure will tell you the new value.
const PROXY_TARGET_OFFSET: usize = 163;
const PROXY_TARGET_OFFSET: usize = 159;

// Replaces the address of the proxy target where it appears in the proxy
// bytecode so we don't need the same fixed address every time.
Expand Down
4 changes: 2 additions & 2 deletions docs/developing.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ git submodule update --init --recursive

2. Install prerequisites

* [Rust/Cargo](https://www.rust-lang.org/tools/install): 1.72 or higher with nightly
* [Rust/Cargo](https://www.rust-lang.org/tools/install): 1.83 or higher with nightly
* [Cocogitto](https://github.com/cocogitto/cocogitto): Commit linting
* [Docker](https://docs.docker.com/engine/install/): Run spec tests
* [PDM](https://pdm.fming.dev/latest/#installation): Run spec tests
* [Protoc](https://grpc.io/docs/protoc-installation/): Compile protobuf
* [Buf](https://buf.build/docs/installation): Protobuf linting
* [Foundry](https://book.getfoundry.sh/getting-started/installation): Compile contracts
* [Foundry ^0.3.0](https://book.getfoundry.sh/getting-started/installation): Compile contracts

## Build & Test

Expand Down

0 comments on commit a46042f

Please sign in to comment.