-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(docker): remove need for foundry in cicd
- Loading branch information
1 parent
6d94c06
commit ab6ecb6
Showing
18 changed files
with
10,241 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
577 changes: 577 additions & 0 deletions
577
crates/types/src/contracts/call_gas_estimation_proxy.rs
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,219 @@ | ||
pub use get_code_hashes::*; | ||
/// This module was auto-generated with ethers-rs Abigen. | ||
/// More information at: <https://github.com/gakonst/ethers-rs> | ||
#[allow( | ||
clippy::enum_variant_names, | ||
clippy::too_many_arguments, | ||
clippy::upper_case_acronyms, | ||
clippy::type_complexity, | ||
dead_code, | ||
non_camel_case_types, | ||
)] | ||
pub mod get_code_hashes { | ||
#[allow(deprecated)] | ||
fn __abi() -> ::ethers::core::abi::Abi { | ||
::ethers::core::abi::ethabi::Contract { | ||
constructor: ::core::option::Option::Some(::ethers::core::abi::ethabi::Constructor { | ||
inputs: ::std::vec![ | ||
::ethers::core::abi::ethabi::Param { name : | ||
::std::borrow::ToOwned::to_owned("addresses"), kind : | ||
::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new(::ethers::core::abi::ethabi::ParamType::Address)), | ||
internal_type : | ||
::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address[]")), | ||
} | ||
], | ||
}), | ||
functions: ::core::convert::From::from([ | ||
( | ||
::std::borrow::ToOwned::to_owned("getCodeHashes"), | ||
::std::vec![ | ||
::ethers::core::abi::ethabi::Function { name : | ||
::std::borrow::ToOwned::to_owned("getCodeHashes"), inputs : | ||
::std::vec![::ethers::core::abi::ethabi::Param { name : | ||
::std::borrow::ToOwned::to_owned("addresses"), kind : | ||
::ethers::core::abi::ethabi::ParamType::Array(::std::boxed::Box::new(::ethers::core::abi::ethabi::ParamType::Address)), | ||
internal_type : | ||
::core::option::Option::Some(::std::borrow::ToOwned::to_owned("address[]")), | ||
}], outputs : ::std::vec![::ethers::core::abi::ethabi::Param { | ||
name : ::std::string::String::new(), kind : | ||
::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize), | ||
internal_type : | ||
::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32")), | ||
}], constant : ::core::option::Option::None, state_mutability : | ||
::ethers::core::abi::ethabi::StateMutability::View, } | ||
], | ||
), | ||
]), | ||
events: ::std::collections::BTreeMap::new(), | ||
errors: ::core::convert::From::from([ | ||
( | ||
::std::borrow::ToOwned::to_owned("CodeHashesResult"), | ||
::std::vec![ | ||
::ethers::core::abi::ethabi::AbiError { name : | ||
::std::borrow::ToOwned::to_owned("CodeHashesResult"), inputs : | ||
::std::vec![::ethers::core::abi::ethabi::Param { name : | ||
::std::borrow::ToOwned::to_owned("hash"), kind : | ||
::ethers::core::abi::ethabi::ParamType::FixedBytes(32usize), | ||
internal_type : | ||
::core::option::Option::Some(::std::borrow::ToOwned::to_owned("bytes32")), | ||
}], } | ||
], | ||
), | ||
]), | ||
receive: false, | ||
fallback: false, | ||
} | ||
} | ||
///The parsed JSON ABI of the contract. | ||
pub static GETCODEHASHES_ABI: ::ethers::contract::Lazy<::ethers::core::abi::Abi> = ::ethers::contract::Lazy::new( | ||
__abi, | ||
); | ||
#[rustfmt::skip] | ||
const __BYTECODE: &[u8] = b"`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[P`@Qa\x02\xB08\x03\x80a\x02\xB0\x839\x81\x01`@\x81\x90Ra\0/\x91a\x01jV[a\08\x81a\0]V[`@Qc\t\x1C\xD0\x05`\xE0\x1B\x81R`\x04\x01a\0T\x91\x81R` \x01\x90V[`@Q\x80\x91\x03\x90\xFD[`\0\x80\x82Q`\x01`\x01`@\x1B\x03\x81\x11\x15a\0yWa\0ya\x018V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\0\xA2W\x81` \x01` \x82\x02\x806\x837\x01\x90P[P\x90P`\0[\x83Q\x81\x10\x15a\x01\x04W\x83\x81\x81Q\x81\x10a\0\xC3Wa\0\xC3a\x02.V[` \x02` \x01\x01Q`\x01`\x01`\xA0\x1B\x03\x16?\x82\x82\x81Q\x81\x10a\0\xE7Wa\0\xE7a\x02.V[` \x90\x81\x02\x91\x90\x91\x01\x01R\x80a\0\xFC\x81a\x02DV[\x91PPa\0\xA8V[P`\0\x81`@Q` \x01a\x01\x18\x91\x90a\x02kV[`@\x80Q`\x1F\x19\x81\x84\x03\x01\x81R\x91\x90R\x80Q` \x90\x91\x01 \x94\x93PPPPV[cNH{q`\xE0\x1B`\0R`A`\x04R`$`\0\xFD[\x80Q`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14a\x01eW`\0\x80\xFD[\x91\x90PV[`\0` \x80\x83\x85\x03\x12\x15a\x01}W`\0\x80\xFD[\x82Q`\x01`\x01`@\x1B\x03\x80\x82\x11\x15a\x01\x94W`\0\x80\xFD[\x81\x85\x01\x91P\x85`\x1F\x83\x01\x12a\x01\xA8W`\0\x80\xFD[\x81Q\x81\x81\x11\x15a\x01\xBAWa\x01\xBAa\x018V[\x80`\x05\x1B`@Q`\x1F\x19`?\x83\x01\x16\x81\x01\x81\x81\x10\x85\x82\x11\x17\x15a\x01\xDFWa\x01\xDFa\x018V[`@R\x91\x82R\x84\x82\x01\x92P\x83\x81\x01\x85\x01\x91\x88\x83\x11\x15a\x01\xFDW`\0\x80\xFD[\x93\x85\x01\x93[\x82\x85\x10\x15a\x02\"Wa\x02\x13\x85a\x01NV[\x84R\x93\x85\x01\x93\x92\x85\x01\x92a\x02\x02V[\x98\x97PPPPPPPPV[cNH{q`\xE0\x1B`\0R`2`\x04R`$`\0\xFD[`\0`\x01\x82\x01a\x02dWcNH{q`\xE0\x1B`\0R`\x11`\x04R`$`\0\xFD[P`\x01\x01\x90V[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90\x84\x82\x01\x90`@\x85\x01\x90\x84[\x81\x81\x10\x15a\x02\xA3W\x83Q\x83R\x92\x84\x01\x92\x91\x84\x01\x91`\x01\x01a\x02\x87V[P\x90\x96\x95PPPPPPV\xFE"; | ||
/// The bytecode of the contract. | ||
pub static GETCODEHASHES_BYTECODE: ::ethers::core::types::Bytes = ::ethers::core::types::Bytes::from_static( | ||
__BYTECODE, | ||
); | ||
#[rustfmt::skip] | ||
const __DEPLOYED_BYTECODE: &[u8] = b"`\x80`@R4\x80\x15a\0\x10W`\0\x80\xFD[P`\x046\x10a\0+W`\x005`\xE0\x1C\x80c{4\xB6!\x14a\x000W[`\0\x80\xFD[a\0Ca\0>6`\x04a\x01cV[a\0UV[`@Q\x90\x81R` \x01`@Q\x80\x91\x03\x90\xF3[`\0\x80\x82Qg\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x81\x11\x15a\0rWa\0ra\x011V[`@Q\x90\x80\x82R\x80` \x02` \x01\x82\x01`@R\x80\x15a\0\x9BW\x81` \x01` \x82\x02\x806\x837\x01\x90P[P\x90P`\0[\x83Q\x81\x10\x15a\0\xFDW\x83\x81\x81Q\x81\x10a\0\xBCWa\0\xBCa\x02(V[` \x02` \x01\x01Q`\x01`\x01`\xA0\x1B\x03\x16?\x82\x82\x81Q\x81\x10a\0\xE0Wa\0\xE0a\x02(V[` \x90\x81\x02\x91\x90\x91\x01\x01R\x80a\0\xF5\x81a\x02>V[\x91PPa\0\xA1V[P`\0\x81`@Q` \x01a\x01\x11\x91\x90a\x02eV[`@\x80Q`\x1F\x19\x81\x84\x03\x01\x81R\x91\x90R\x80Q` \x90\x91\x01 \x94\x93PPPPV[cNH{q`\xE0\x1B`\0R`A`\x04R`$`\0\xFD[\x805`\x01`\x01`\xA0\x1B\x03\x81\x16\x81\x14a\x01^W`\0\x80\xFD[\x91\x90PV[`\0` \x80\x83\x85\x03\x12\x15a\x01vW`\0\x80\xFD[\x825g\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF\x80\x82\x11\x15a\x01\x8EW`\0\x80\xFD[\x81\x85\x01\x91P\x85`\x1F\x83\x01\x12a\x01\xA2W`\0\x80\xFD[\x815\x81\x81\x11\x15a\x01\xB4Wa\x01\xB4a\x011V[\x80`\x05\x1B`@Q`\x1F\x19`?\x83\x01\x16\x81\x01\x81\x81\x10\x85\x82\x11\x17\x15a\x01\xD9Wa\x01\xD9a\x011V[`@R\x91\x82R\x84\x82\x01\x92P\x83\x81\x01\x85\x01\x91\x88\x83\x11\x15a\x01\xF7W`\0\x80\xFD[\x93\x85\x01\x93[\x82\x85\x10\x15a\x02\x1CWa\x02\r\x85a\x01GV[\x84R\x93\x85\x01\x93\x92\x85\x01\x92a\x01\xFCV[\x98\x97PPPPPPPPV[cNH{q`\xE0\x1B`\0R`2`\x04R`$`\0\xFD[`\0`\x01\x82\x01a\x02^WcNH{q`\xE0\x1B`\0R`\x11`\x04R`$`\0\xFD[P`\x01\x01\x90V[` \x80\x82R\x82Q\x82\x82\x01\x81\x90R`\0\x91\x90\x84\x82\x01\x90`@\x85\x01\x90\x84[\x81\x81\x10\x15a\x02\x9DW\x83Q\x83R\x92\x84\x01\x92\x91\x84\x01\x91`\x01\x01a\x02\x81V[P\x90\x96\x95PPPPPPV\xFE\xA2dipfsX\"\x12 *\xD8\xA0$2\xFER\x19\0L\xEA e*(\x04t\x9E\\\xD3\x0EQ8\xB7\xF0\x85]\xF2\xD6Z\x05YdsolcC\0\x08\x15\x003"; | ||
/// The deployed bytecode of the contract. | ||
pub static GETCODEHASHES_DEPLOYED_BYTECODE: ::ethers::core::types::Bytes = ::ethers::core::types::Bytes::from_static( | ||
__DEPLOYED_BYTECODE, | ||
); | ||
pub struct GetCodeHashes<M>(::ethers::contract::Contract<M>); | ||
impl<M> ::core::clone::Clone for GetCodeHashes<M> { | ||
fn clone(&self) -> Self { | ||
Self(::core::clone::Clone::clone(&self.0)) | ||
} | ||
} | ||
impl<M> ::core::ops::Deref for GetCodeHashes<M> { | ||
type Target = ::ethers::contract::Contract<M>; | ||
fn deref(&self) -> &Self::Target { | ||
&self.0 | ||
} | ||
} | ||
impl<M> ::core::ops::DerefMut for GetCodeHashes<M> { | ||
fn deref_mut(&mut self) -> &mut Self::Target { | ||
&mut self.0 | ||
} | ||
} | ||
impl<M> ::core::fmt::Debug for GetCodeHashes<M> { | ||
fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { | ||
f.debug_tuple(::core::stringify!(GetCodeHashes)) | ||
.field(&self.address()) | ||
.finish() | ||
} | ||
} | ||
impl<M: ::ethers::providers::Middleware> GetCodeHashes<M> { | ||
/// Creates a new contract instance with the specified `ethers` client at | ||
/// `address`. The contract derefs to a `ethers::Contract` object. | ||
pub fn new<T: Into<::ethers::core::types::Address>>( | ||
address: T, | ||
client: ::std::sync::Arc<M>, | ||
) -> Self { | ||
Self( | ||
::ethers::contract::Contract::new( | ||
address.into(), | ||
GETCODEHASHES_ABI.clone(), | ||
client, | ||
), | ||
) | ||
} | ||
/// Constructs the general purpose `Deployer` instance based on the provided constructor arguments and sends it. | ||
/// Returns a new instance of a deployer that returns an instance of this contract after sending the transaction | ||
/// | ||
/// Notes: | ||
/// - If there are no constructor arguments, you should pass `()` as the argument. | ||
/// - The default poll duration is 7 seconds. | ||
/// - The default number of confirmations is 1 block. | ||
/// | ||
/// | ||
/// # Example | ||
/// | ||
/// Generate contract bindings with `abigen!` and deploy a new contract instance. | ||
/// | ||
/// *Note*: this requires a `bytecode` and `abi` object in the `greeter.json` artifact. | ||
/// | ||
/// ```ignore | ||
/// # async fn deploy<M: ethers::providers::Middleware>(client: ::std::sync::Arc<M>) { | ||
/// abigen!(Greeter, "../greeter.json"); | ||
/// | ||
/// let greeter_contract = Greeter::deploy(client, "Hello world!".to_string()).unwrap().send().await.unwrap(); | ||
/// let msg = greeter_contract.greet().call().await.unwrap(); | ||
/// # } | ||
/// ``` | ||
pub fn deploy<T: ::ethers::core::abi::Tokenize>( | ||
client: ::std::sync::Arc<M>, | ||
constructor_args: T, | ||
) -> ::core::result::Result< | ||
::ethers::contract::builders::ContractDeployer<M, Self>, | ||
::ethers::contract::ContractError<M>, | ||
> { | ||
let factory = ::ethers::contract::ContractFactory::new( | ||
GETCODEHASHES_ABI.clone(), | ||
GETCODEHASHES_BYTECODE.clone().into(), | ||
client, | ||
); | ||
let deployer = factory.deploy(constructor_args)?; | ||
let deployer = ::ethers::contract::ContractDeployer::new(deployer); | ||
Ok(deployer) | ||
} | ||
///Calls the contract's `getCodeHashes` (0x7b34b621) function | ||
pub fn get_code_hashes( | ||
&self, | ||
addresses: ::std::vec::Vec<::ethers::core::types::Address>, | ||
) -> ::ethers::contract::builders::ContractCall<M, [u8; 32]> { | ||
self.0 | ||
.method_hash([123, 52, 182, 33], addresses) | ||
.expect("method not found (this should never happen)") | ||
} | ||
} | ||
impl<M: ::ethers::providers::Middleware> From<::ethers::contract::Contract<M>> | ||
for GetCodeHashes<M> { | ||
fn from(contract: ::ethers::contract::Contract<M>) -> Self { | ||
Self::new(contract.address(), contract.client()) | ||
} | ||
} | ||
///Custom Error type `CodeHashesResult` with signature `CodeHashesResult(bytes32)` and selector `0x091cd005` | ||
#[derive( | ||
Clone, | ||
::ethers::contract::EthError, | ||
::ethers::contract::EthDisplay, | ||
Default, | ||
Debug, | ||
PartialEq, | ||
Eq, | ||
Hash | ||
)] | ||
#[etherror(name = "CodeHashesResult", abi = "CodeHashesResult(bytes32)")] | ||
pub struct CodeHashesResult { | ||
pub hash: [u8; 32], | ||
} | ||
///Container type for all input parameters for the `getCodeHashes` function with signature `getCodeHashes(address[])` and selector `0x7b34b621` | ||
#[derive( | ||
Clone, | ||
::ethers::contract::EthCall, | ||
::ethers::contract::EthDisplay, | ||
Default, | ||
Debug, | ||
PartialEq, | ||
Eq, | ||
Hash | ||
)] | ||
#[ethcall(name = "getCodeHashes", abi = "getCodeHashes(address[])")] | ||
pub struct GetCodeHashesCall { | ||
pub addresses: ::std::vec::Vec<::ethers::core::types::Address>, | ||
} | ||
///Container type for all return fields from the `getCodeHashes` function with signature `getCodeHashes(address[])` and selector `0x7b34b621` | ||
#[derive( | ||
Clone, | ||
::ethers::contract::EthAbiType, | ||
::ethers::contract::EthAbiCodec, | ||
Default, | ||
Debug, | ||
PartialEq, | ||
Eq, | ||
Hash | ||
)] | ||
pub struct GetCodeHashesReturn(pub [u8; 32]); | ||
} |
Oops, something went wrong.