diff --git a/.gitignore b/.gitignore index 90efe96aa..d3b0897d5 100644 --- a/.gitignore +++ b/.gitignore @@ -10,13 +10,6 @@ *.iml .vscode -# Foundry, configured in foundry.toml -contracts/cache/ -contracts/out/ - -# Generated contract bindings, created in build.rs -src/common/contracts/ - .env *.log diff --git a/.gitmodules b/.gitmodules index 08f3c1adc..5ecbdb58a 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,13 +1,13 @@ -[submodule "contracts/lib/account-abstraction"] - path = contracts/lib/account-abstraction +[submodule "crates/rundler/contracts/lib/account-abstraction"] + path = crates/rundler/contracts/lib/account-abstraction url = https://github.com/eth-infinitism/account-abstraction branch = v0.5 -[submodule "contracts/lib/forge-std"] - path = contracts/lib/forge-std +[submodule "crates/rundler/contracts/lib/forge-std"] + path = crates/rundler/contracts/lib/forge-std url = https://github.com/foundry-rs/forge-std branch = chore/v1.5.0 -[submodule "foundry/lib/openzeppelin-contracts"] - path = contracts/lib/openzeppelin-contracts +[submodule "crates/rundler/contracts/lib/openzeppelin-contracts"] + path = crates/rundler/contracts/lib/openzeppelin-contracts url = https://github.com/OpenZeppelin/openzeppelin-contracts branch = release-v4.8 [submodule "test/spec-tests/bundler-spec-tests"] diff --git a/Cargo.lock b/Cargo.lock index eacba16cf..cb80caebc 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3946,6 +3946,15 @@ dependencies = [ [[package]] name = "rundler" version = "0.1.0-beta" +dependencies = [ + "dotenv", + "rundler-rundler", + "tokio", +] + +[[package]] +name = "rundler-rundler" +version = "0.1.0-beta" dependencies = [ "anyhow", "arrayvec", @@ -3953,7 +3962,6 @@ dependencies = [ "cargo-husky", "chrono", "clap 4.2.4", - "dotenv", "enum_dispatch", "ethers", "ethers-signers", @@ -4005,6 +4013,22 @@ dependencies = [ "url", ] +[[package]] +name = "rundler-tools" +version = "0.1.0-beta" +dependencies = [ + "anyhow", + "clap 4.2.4", + "dotenv", + "ethers", + "ethers-signers", + "rundler-rundler", + "rusoto_core", + "rusoto_kms", + "serde_json", + "tokio", +] + [[package]] name = "rusoto_core" version = "0.48.0" diff --git a/Cargo.toml b/Cargo.toml index d5a366e63..df2c519fc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,71 +1,17 @@ -[package] -name = "rundler" +[workspace] +members = [ + "bin/rundler", + "bin/tools", + "crates/rundler" +] +default-members = ["bin/rundler", "bin/tools"] + +[workspace.package] version = "0.1.0-beta" edition = "2021" -default-run = "rundler" - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html - -[dependencies] -anyhow = "1.0.70" -arrayvec = "0.7.2" -async-stream = "0.3.5" -chrono = "0.4.24" -clap = { version = "4.2.4", features = ["derive", "env"] } -dotenv = "0.15.0" -enum_dispatch = "0.3.11" -ethers = { version = "2.0.8", features = ["ws"] } -ethers-signers = {version = "2.0.8", features = ["aws"] } -futures = "0.3.28" -futures-timer = "3.0.2" -futures-util = "0.3.28" -hyper = "0.14.27" -indexmap = "2.0.0" -itertools = "0.11.0" -jsonrpsee = { version = "0.20.0", features = ["client", "macros", "server"] } -linked-hash-map = "0.5.6" -metrics = "0.21.0" -metrics-exporter-prometheus = "0.12.0" -metrics-process = "1.0.10" -metrics-util = "0.15.0" -parking_lot = "0.12.1" -parse-display = "0.8.0" -pin-project = "1.0.12" -prost = "0.12.0" -prost-types = "0.12.0" -rand = "0.8.5" -reqwest = { version = "0.11.18", default-features = false, features = ["rustls-tls"] } -rslock = "0.2.2" -rustls = "0.21.7" -rusoto_core = { version = "0.48.0", default-features = false, features = ["rustls"] } -rusoto_kms = { version = "0.48.0", default-features = false, features = ["rustls"] } -rusoto_s3 = { version = "0.48.0", default-features = false, features = ["rustls"] } -serde = { version = "1.0.160", features = ["derive"] } -serde_json = "1.0.96" -serde_with = "3.0.0" -sscanf = "0.4.0" -strum = { version = "0.25.0", features = ["derive"] } -thiserror = "1.0.40" -tokio = { version = "1.27.0", features = ["macros", "rt-multi-thread", "signal", "sync"] } -tokio-rustls = "0.24.1" -tokio-stream = { version = "0.1.12", features = ["sync"] } -tokio-util = "0.7.8" -tonic = "0.10.0" -tonic-health = "0.10.0" -tonic-reflection = "0.10.0" -tonic-types = "0.10.0" -tower = "0.4.13" -tower-http = { version = "0.4.0", features = ["trace"] } -tracing = "0.1.37" -tracing-appender = "0.2.2" -tracing-subscriber = { version = "0.3.16", features = ["env-filter", "fmt", "json"] } -url = "2.3.1" - -[dev-dependencies] -cargo-husky = { version = "1", default-features = false, features = ["user-hooks" ] } -mockall = "0.11.4" -tokio-util = "0.7.7" +rust-version = "1.71" +license = "MIT OR Apache-2.0" +repository = "https://github.com/alchemyplatform/rundler" -[build-dependencies] -ethers = "2.0.3" -tonic-build = "0.10.0" +[workspace.dependencies] +tokio = { version = "1.27.0", default-features = false } diff --git a/bin/rundler/Cargo.toml b/bin/rundler/Cargo.toml new file mode 100644 index 000000000..615319306 --- /dev/null +++ b/bin/rundler/Cargo.toml @@ -0,0 +1,17 @@ +[package] +name = "rundler" +version.workspace = true +edition.workspace = true +rust-version.workspace = true +license.workspace = true +repository.workspace = true +description = """ +Rundler node implementation +""" + +[dependencies] +rundler-rundler = { path = "../../crates/rundler" } + +# CLI dependencies +tokio = "1.27.0" +dotenv = "0.15.0" diff --git a/src/main.rs b/bin/rundler/src/main.rs similarity index 87% rename from src/main.rs rename to bin/rundler/src/main.rs index 79ddfdb02..eca0164f2 100644 --- a/src/main.rs +++ b/bin/rundler/src/main.rs @@ -1,5 +1,5 @@ use dotenv::dotenv; -use rundler::cli; +use rundler_rundler::cli; #[tokio::main] async fn main() { diff --git a/bin/tools/Cargo.toml b/bin/tools/Cargo.toml new file mode 100644 index 000000000..7ec2ee5a7 --- /dev/null +++ b/bin/tools/Cargo.toml @@ -0,0 +1,23 @@ +[package] +name = "rundler-tools" +version.workspace = true +edition.workspace = true +rust-version.workspace = true +license.workspace = true +repository.workspace = true +description = """ +Rundler tools +""" + +[dependencies] +rundler-rundler = { path = "../../crates/rundler" } + +anyhow = "1.0.70" +clap = { version = "4.2.4", features = ["derive", "env"] } +dotenv = "0.15.0" +ethers = "2.0.8" +ethers-signers = {version = "2.0.8", features = ["aws"] } +rusoto_core = { version = "0.48.0", default-features = false, features = ["rustls"] } +rusoto_kms = { version = "0.48.0", default-features = false, features = ["rustls"] } +serde_json = "1.0.96" +tokio.workspace = true diff --git a/src/bin/deploy_dev_contracts.rs b/bin/tools/src/bin/deploy_dev_contracts.rs similarity index 88% rename from src/bin/deploy_dev_contracts.rs rename to bin/tools/src/bin/deploy_dev_contracts.rs index 5cb93aa37..38068ae85 100644 --- a/src/bin/deploy_dev_contracts.rs +++ b/bin/tools/src/bin/deploy_dev_contracts.rs @@ -1,5 +1,5 @@ use ethers::utils::hex; -use rundler::common::{ +use rundler_rundler::common::{ dev, dev::{DevAddresses, BUNDLER_ACCOUNT_ID, PAYMASTER_SIGNER_ACCOUNT_ID, WALLET_OWNER_ACCOUNT_ID}, }; @@ -7,7 +7,7 @@ use rundler::common::{ #[tokio::main] async fn main() -> anyhow::Result<()> { let bytecode = include_str!( - "../../contracts/bytecode/entrypoint/0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789.txt", + "../../../../crates/rundler/contracts/bytecode/entrypoint/0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789.txt", ); let addresses = dev::deploy_dev_contracts(bytecode).await?; addresses.write_to_env_file()?; diff --git a/src/bin/get_example_ops.rs b/bin/tools/src/bin/get_example_ops.rs similarity index 91% rename from src/bin/get_example_ops.rs rename to bin/tools/src/bin/get_example_ops.rs index a65637226..aa52d33ed 100644 --- a/src/bin/get_example_ops.rs +++ b/bin/tools/src/bin/get_example_ops.rs @@ -1,5 +1,5 @@ use dotenv::dotenv; -use rundler::{common::dev::DevClients, rpc::RpcUserOperation}; +use rundler_rundler::{common::dev::DevClients, rpc::RpcUserOperation}; #[tokio::main] async fn main() -> anyhow::Result<()> { diff --git a/src/bin/get_kms_address.rs b/bin/tools/src/bin/get_kms_address.rs similarity index 100% rename from src/bin/get_kms_address.rs rename to bin/tools/src/bin/get_kms_address.rs diff --git a/src/bin/send_ops.rs b/bin/tools/src/bin/send_ops.rs similarity index 80% rename from src/bin/send_ops.rs rename to bin/tools/src/bin/send_ops.rs index 811874d92..1d8e1b3cb 100644 --- a/src/bin/send_ops.rs +++ b/bin/tools/src/bin/send_ops.rs @@ -1,5 +1,5 @@ use dotenv::dotenv; -use rundler::common::{dev::DevClients, eth}; +use rundler_rundler::common::{dev::DevClients, eth}; #[tokio::main] async fn main() -> anyhow::Result<()> { @@ -15,7 +15,7 @@ async fn main() -> anyhow::Result<()> { // simply call the nonce method multiple times for i in 0..10 { println!("Sending op {i}"); - let op = clients.new_wallet_op(wallet.get_nonce(), 0.into()).await?; + let op = clients.new_wallet_op(wallet.nonce(), 0.into()).await?; let call = entry_point.handle_ops(vec![op], bundler_client.address()); eth::await_mined_tx(call.send(), "send user operation").await?; } diff --git a/buf.work.yaml b/buf.work.yaml index 1878b341b..f86e3a0e3 100644 --- a/buf.work.yaml +++ b/buf.work.yaml @@ -1,3 +1,3 @@ version: v1 directories: - - proto + - crates/rundler/proto diff --git a/contracts/foundry.toml b/contracts/foundry.toml deleted file mode 100644 index 73927b63e..000000000 --- a/contracts/foundry.toml +++ /dev/null @@ -1,8 +0,0 @@ -[profile.default] -src = 'src' -out = 'out' -libs = ['lib'] -test = 'test' -cache_path = 'cache' - -# See more config options https://github.com/foundry-rs/foundry/tree/master/config diff --git a/contracts/lib/account-abstraction b/contracts/lib/account-abstraction deleted file mode 160000 index 9b5f2e4bb..000000000 --- a/contracts/lib/account-abstraction +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 9b5f2e4bb30a81aa30761749d9e2e43fee64c768 diff --git a/contracts/lib/forge-std b/contracts/lib/forge-std deleted file mode 160000 index 73a504d2c..000000000 --- a/contracts/lib/forge-std +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 73a504d2cf6f37b7ce285b479f4c681f76e95f1b diff --git a/contracts/lib/openzeppelin-contracts b/contracts/lib/openzeppelin-contracts deleted file mode 160000 index d00acef40..000000000 --- a/contracts/lib/openzeppelin-contracts +++ /dev/null @@ -1 +0,0 @@ -Subproject commit d00acef4059807535af0bd0dd0ddf619747a044b diff --git a/contracts/remappings.txt b/contracts/remappings.txt deleted file mode 100644 index 7cf1bbaa3..000000000 --- a/contracts/remappings.txt +++ /dev/null @@ -1,4 +0,0 @@ -forge-std/=lib/forge-std/src -ds-test/=lib/forge-std/lib/ds-test/src/ -account-abstraction/=lib/account-abstraction/contracts/ -@openzeppelin/=lib/openzeppelin-contracts/ diff --git a/crates/rundler/.gitignore b/crates/rundler/.gitignore new file mode 100644 index 000000000..311f2f849 --- /dev/null +++ b/crates/rundler/.gitignore @@ -0,0 +1 @@ +/src/common/contracts diff --git a/crates/rundler/Cargo.toml b/crates/rundler/Cargo.toml new file mode 100644 index 000000000..59c8ed3cd --- /dev/null +++ b/crates/rundler/Cargo.toml @@ -0,0 +1,70 @@ +[package] +name = "rundler-rundler" +version.workspace = true +edition.workspace = true +rust-version.workspace = true +license.workspace = true +repository.workspace = true + +[dependencies] +anyhow = "1.0.70" +arrayvec = "0.7.2" +async-stream = "0.3.5" +chrono = "0.4.24" +clap = { version = "4.2.4", features = ["derive", "env"] } +enum_dispatch = "0.3.11" +ethers = { version = "2.0.8", features = ["ws"] } +ethers-signers = {version = "2.0.8", features = ["aws"] } +futures = "0.3.28" +futures-timer = "3.0.2" +futures-util = "0.3.28" +hyper = "0.14.27" +indexmap = "2.0.0" +itertools = "0.11.0" +jsonrpsee = { version = "0.20.0", features = ["client", "macros", "server"] } +linked-hash-map = "0.5.6" +metrics = "0.21.0" +metrics-exporter-prometheus = "0.12.0" +metrics-process = "1.0.10" +metrics-util = "0.15.0" +parking_lot = "0.12.1" +parse-display = "0.8.0" +pin-project = "1.0.12" +prost = "0.12.0" +prost-types = "0.12.0" +rand = "0.8.5" +reqwest = { version = "0.11.18", default-features = false, features = ["rustls-tls"] } +rslock = "0.2.2" +rustls = "0.21.7" +rusoto_core = { version = "0.48.0", default-features = false, features = ["rustls"] } +rusoto_kms = { version = "0.48.0", default-features = false, features = ["rustls"] } +rusoto_s3 = { version = "0.48.0", default-features = false, features = ["rustls"] } +serde = { version = "1.0.160", features = ["derive"] } +serde_json = "1.0.96" +serde_with = "3.0.0" +sscanf = "0.4.0" +strum = { version = "0.25.0", features = ["derive"] } +thiserror = "1.0.40" +tokio = { workspace = true, features = ["macros", "rt-multi-thread", "signal", "sync"] } +tokio-rustls = "0.24.1" +tokio-stream = { version = "0.1.12", features = ["sync"] } +tokio-util = "0.7.8" +tonic = "0.10.0" +tonic-health = "0.10.0" +tonic-reflection = "0.10.0" +tonic-types = "0.10.0" +tower = "0.4.13" +tower-http = { version = "0.4.0", features = ["trace"] } +tracing = "0.1.37" +tracing-appender = "0.2.2" +tracing-subscriber = { version = "0.3.16", features = ["env-filter", "fmt", "json"] } +url = "2.3.1" + +[dev-dependencies] +cargo-husky = { version = "1", default-features = false, features = ["user-hooks" ] } +mockall = "0.11.4" +tokio-util = "0.7.7" + +[build-dependencies] +ethers = "2.0.3" +tonic-build = "0.10.0" diff --git a/build.rs b/crates/rundler/build.rs similarity index 100% rename from build.rs rename to crates/rundler/build.rs diff --git a/crates/rundler/contracts/.gitignore b/crates/rundler/contracts/.gitignore new file mode 100644 index 000000000..68b562455 --- /dev/null +++ b/crates/rundler/contracts/.gitignore @@ -0,0 +1,2 @@ +/cache +/out diff --git a/contracts/README.md b/crates/rundler/contracts/README.md similarity index 100% rename from contracts/README.md rename to crates/rundler/contracts/README.md diff --git a/contracts/bytecode/entrypoint/0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789.txt b/crates/rundler/contracts/bytecode/entrypoint/0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789.txt similarity index 100% rename from contracts/bytecode/entrypoint/0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789.txt rename to crates/rundler/contracts/bytecode/entrypoint/0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789.txt diff --git a/crates/rundler/contracts/foundry.toml b/crates/rundler/contracts/foundry.toml new file mode 100644 index 000000000..d82db5af8 --- /dev/null +++ b/crates/rundler/contracts/foundry.toml @@ -0,0 +1,13 @@ +[profile.default] +src = 'src' +out = 'out' +libs = ['lib'] +test = 'test' +cache_path = 'cache' + +remappings = [ + 'forge-std/=lib/forge-std/src', + 'ds-test/=lib/forge-std/lib/ds-test/src/', + 'account-abstraction/=lib/account-abstraction/contracts/', + '@openzeppelin/=lib/openzeppelin-contracts/' +] diff --git a/crates/rundler/contracts/lib/account-abstraction b/crates/rundler/contracts/lib/account-abstraction new file mode 160000 index 000000000..f3b5f7955 --- /dev/null +++ b/crates/rundler/contracts/lib/account-abstraction @@ -0,0 +1 @@ +Subproject commit f3b5f795515ad8a7a7bf447575d6554854b820da diff --git a/crates/rundler/contracts/lib/forge-std b/crates/rundler/contracts/lib/forge-std new file mode 160000 index 000000000..b1cf26037 --- /dev/null +++ b/crates/rundler/contracts/lib/forge-std @@ -0,0 +1 @@ +Subproject commit b1cf26037432d18fea6917ba82a6fedbff71c037 diff --git a/crates/rundler/contracts/lib/openzeppelin-contracts b/crates/rundler/contracts/lib/openzeppelin-contracts new file mode 160000 index 000000000..0a25c1940 --- /dev/null +++ b/crates/rundler/contracts/lib/openzeppelin-contracts @@ -0,0 +1 @@ +Subproject commit 0a25c1940ca220686588c4af3ec526f725fe2582 diff --git a/contracts/src/CallGasEstimationProxy.sol b/crates/rundler/contracts/src/CallGasEstimationProxy.sol similarity index 100% rename from contracts/src/CallGasEstimationProxy.sol rename to crates/rundler/contracts/src/CallGasEstimationProxy.sol diff --git a/contracts/src/GetCodeHashes.sol b/crates/rundler/contracts/src/GetCodeHashes.sol similarity index 100% rename from contracts/src/GetCodeHashes.sol rename to crates/rundler/contracts/src/GetCodeHashes.sol diff --git a/contracts/src/GetGasUsed.sol b/crates/rundler/contracts/src/GetGasUsed.sol similarity index 100% rename from contracts/src/GetGasUsed.sol rename to crates/rundler/contracts/src/GetGasUsed.sol diff --git a/contracts/src/PrecompileAccount.sol b/crates/rundler/contracts/src/PrecompileAccount.sol similarity index 100% rename from contracts/src/PrecompileAccount.sol rename to crates/rundler/contracts/src/PrecompileAccount.sol diff --git a/contracts/src/arbitrum/NodeInterface.sol b/crates/rundler/contracts/src/arbitrum/NodeInterface.sol similarity index 100% rename from contracts/src/arbitrum/NodeInterface.sol rename to crates/rundler/contracts/src/arbitrum/NodeInterface.sol diff --git a/contracts/src/imports.sol b/crates/rundler/contracts/src/imports.sol similarity index 100% rename from contracts/src/imports.sol rename to crates/rundler/contracts/src/imports.sol diff --git a/contracts/src/optimism/GasPriceOracle.sol b/crates/rundler/contracts/src/optimism/GasPriceOracle.sol similarity index 100% rename from contracts/src/optimism/GasPriceOracle.sol rename to crates/rundler/contracts/src/optimism/GasPriceOracle.sol diff --git a/contracts/src/optimism/L1Block.sol b/crates/rundler/contracts/src/optimism/L1Block.sol similarity index 100% rename from contracts/src/optimism/L1Block.sol rename to crates/rundler/contracts/src/optimism/L1Block.sol diff --git a/contracts/src/optimism/Predeploys.sol b/crates/rundler/contracts/src/optimism/Predeploys.sol similarity index 100% rename from contracts/src/optimism/Predeploys.sol rename to crates/rundler/contracts/src/optimism/Predeploys.sol diff --git a/contracts/test/PrecompileAccountTest.sol b/crates/rundler/contracts/test/PrecompileAccountTest.sol similarity index 100% rename from contracts/test/PrecompileAccountTest.sol rename to crates/rundler/contracts/test/PrecompileAccountTest.sol diff --git a/proto/README.md b/crates/rundler/proto/README.md similarity index 100% rename from proto/README.md rename to crates/rundler/proto/README.md diff --git a/proto/buf.yaml b/crates/rundler/proto/buf.yaml similarity index 100% rename from proto/buf.yaml rename to crates/rundler/proto/buf.yaml diff --git a/proto/builder/builder.proto b/crates/rundler/proto/builder/builder.proto similarity index 100% rename from proto/builder/builder.proto rename to crates/rundler/proto/builder/builder.proto diff --git a/proto/op_pool/op_pool.proto b/crates/rundler/proto/op_pool/op_pool.proto similarity index 100% rename from proto/op_pool/op_pool.proto rename to crates/rundler/proto/op_pool/op_pool.proto diff --git a/src/builder/bundle_proposer.rs b/crates/rundler/src/builder/bundle_proposer.rs similarity index 100% rename from src/builder/bundle_proposer.rs rename to crates/rundler/src/builder/bundle_proposer.rs diff --git a/src/builder/bundle_sender.rs b/crates/rundler/src/builder/bundle_sender.rs similarity index 100% rename from src/builder/bundle_sender.rs rename to crates/rundler/src/builder/bundle_sender.rs diff --git a/src/builder/emit.rs b/crates/rundler/src/builder/emit.rs similarity index 100% rename from src/builder/emit.rs rename to crates/rundler/src/builder/emit.rs diff --git a/src/builder/mod.rs b/crates/rundler/src/builder/mod.rs similarity index 100% rename from src/builder/mod.rs rename to crates/rundler/src/builder/mod.rs diff --git a/src/builder/sender/conditional.rs b/crates/rundler/src/builder/sender/conditional.rs similarity index 100% rename from src/builder/sender/conditional.rs rename to crates/rundler/src/builder/sender/conditional.rs diff --git a/src/builder/sender/flashbots.rs b/crates/rundler/src/builder/sender/flashbots.rs similarity index 100% rename from src/builder/sender/flashbots.rs rename to crates/rundler/src/builder/sender/flashbots.rs diff --git a/src/builder/sender/mod.rs b/crates/rundler/src/builder/sender/mod.rs similarity index 100% rename from src/builder/sender/mod.rs rename to crates/rundler/src/builder/sender/mod.rs diff --git a/src/builder/sender/raw.rs b/crates/rundler/src/builder/sender/raw.rs similarity index 100% rename from src/builder/sender/raw.rs rename to crates/rundler/src/builder/sender/raw.rs diff --git a/src/builder/server/local.rs b/crates/rundler/src/builder/server/local.rs similarity index 97% rename from src/builder/server/local.rs rename to crates/rundler/src/builder/server/local.rs index 7ff25cc45..88cec8787 100644 --- a/src/builder/server/local.rs +++ b/crates/rundler/src/builder/server/local.rs @@ -163,6 +163,10 @@ impl LocalBuilderServerRunner { }) }, ServerRequestKind::DebugSendBundleNow => { + if !self.manual_bundling_mode.load(Ordering::Relaxed) { + break 'a Err(anyhow::anyhow!("bundling mode is not manual").into()) + } + let (tx, rx) = oneshot::channel(); match self.send_bundle_requester.send(SendBundleRequest{ responder: tx diff --git a/src/builder/server/mod.rs b/crates/rundler/src/builder/server/mod.rs similarity index 100% rename from src/builder/server/mod.rs rename to crates/rundler/src/builder/server/mod.rs diff --git a/src/builder/server/remote/client.rs b/crates/rundler/src/builder/server/remote/client.rs similarity index 100% rename from src/builder/server/remote/client.rs rename to crates/rundler/src/builder/server/remote/client.rs diff --git a/src/builder/server/remote/error.rs b/crates/rundler/src/builder/server/remote/error.rs similarity index 100% rename from src/builder/server/remote/error.rs rename to crates/rundler/src/builder/server/remote/error.rs diff --git a/src/builder/server/remote/mod.rs b/crates/rundler/src/builder/server/remote/mod.rs similarity index 100% rename from src/builder/server/remote/mod.rs rename to crates/rundler/src/builder/server/remote/mod.rs diff --git a/src/builder/server/remote/protos.rs b/crates/rundler/src/builder/server/remote/protos.rs similarity index 100% rename from src/builder/server/remote/protos.rs rename to crates/rundler/src/builder/server/remote/protos.rs diff --git a/src/builder/server/remote/server.rs b/crates/rundler/src/builder/server/remote/server.rs similarity index 100% rename from src/builder/server/remote/server.rs rename to crates/rundler/src/builder/server/remote/server.rs diff --git a/src/builder/signer/aws.rs b/crates/rundler/src/builder/signer/aws.rs similarity index 100% rename from src/builder/signer/aws.rs rename to crates/rundler/src/builder/signer/aws.rs diff --git a/src/builder/signer/mod.rs b/crates/rundler/src/builder/signer/mod.rs similarity index 100% rename from src/builder/signer/mod.rs rename to crates/rundler/src/builder/signer/mod.rs diff --git a/src/builder/task.rs b/crates/rundler/src/builder/task.rs similarity index 100% rename from src/builder/task.rs rename to crates/rundler/src/builder/task.rs diff --git a/src/builder/transaction_tracker.rs b/crates/rundler/src/builder/transaction_tracker.rs similarity index 100% rename from src/builder/transaction_tracker.rs rename to crates/rundler/src/builder/transaction_tracker.rs diff --git a/src/cli/builder.rs b/crates/rundler/src/cli/builder.rs similarity index 100% rename from src/cli/builder.rs rename to crates/rundler/src/cli/builder.rs diff --git a/src/cli/json.rs b/crates/rundler/src/cli/json.rs similarity index 100% rename from src/cli/json.rs rename to crates/rundler/src/cli/json.rs diff --git a/src/cli/mod.rs b/crates/rundler/src/cli/mod.rs similarity index 100% rename from src/cli/mod.rs rename to crates/rundler/src/cli/mod.rs diff --git a/src/cli/node/events.rs b/crates/rundler/src/cli/node/events.rs similarity index 100% rename from src/cli/node/events.rs rename to crates/rundler/src/cli/node/events.rs diff --git a/src/cli/node/mod.rs b/crates/rundler/src/cli/node/mod.rs similarity index 100% rename from src/cli/node/mod.rs rename to crates/rundler/src/cli/node/mod.rs diff --git a/src/cli/pool.rs b/crates/rundler/src/cli/pool.rs similarity index 100% rename from src/cli/pool.rs rename to crates/rundler/src/cli/pool.rs diff --git a/src/cli/prometheus_exporter.rs b/crates/rundler/src/cli/prometheus_exporter.rs similarity index 100% rename from src/cli/prometheus_exporter.rs rename to crates/rundler/src/cli/prometheus_exporter.rs diff --git a/src/cli/rpc.rs b/crates/rundler/src/cli/rpc.rs similarity index 100% rename from src/cli/rpc.rs rename to crates/rundler/src/cli/rpc.rs diff --git a/src/cli/tracing.rs b/crates/rundler/src/cli/tracing.rs similarity index 100% rename from src/cli/tracing.rs rename to crates/rundler/src/cli/tracing.rs diff --git a/src/common/block_watcher.rs b/crates/rundler/src/common/block_watcher.rs similarity index 100% rename from src/common/block_watcher.rs rename to crates/rundler/src/common/block_watcher.rs diff --git a/src/common/context.rs b/crates/rundler/src/common/context.rs similarity index 100% rename from src/common/context.rs rename to crates/rundler/src/common/context.rs diff --git a/src/common/dev.rs b/crates/rundler/src/common/dev.rs similarity index 99% rename from src/common/dev.rs rename to crates/rundler/src/common/dev.rs index a88fbbd76..4fe541fd9 100644 --- a/src/common/dev.rs +++ b/crates/rundler/src/common/dev.rs @@ -366,7 +366,7 @@ impl DevClients { .context("call executed by wallet should have to address")?; let nonce = self .wallet - .get_nonce() + .nonce() .await .context("should read nonce from wallet")?; let call_data = Bytes::clone( diff --git a/src/common/emit.rs b/crates/rundler/src/common/emit.rs similarity index 100% rename from src/common/emit.rs rename to crates/rundler/src/common/emit.rs diff --git a/src/common/eth.rs b/crates/rundler/src/common/eth.rs similarity index 100% rename from src/common/eth.rs rename to crates/rundler/src/common/eth.rs diff --git a/src/common/gas.rs b/crates/rundler/src/common/gas.rs similarity index 100% rename from src/common/gas.rs rename to crates/rundler/src/common/gas.rs diff --git a/src/common/grpc/metrics.rs b/crates/rundler/src/common/grpc/metrics.rs similarity index 100% rename from src/common/grpc/metrics.rs rename to crates/rundler/src/common/grpc/metrics.rs diff --git a/src/common/grpc/mod.rs b/crates/rundler/src/common/grpc/mod.rs similarity index 100% rename from src/common/grpc/mod.rs rename to crates/rundler/src/common/grpc/mod.rs diff --git a/src/common/handle.rs b/crates/rundler/src/common/handle.rs similarity index 100% rename from src/common/handle.rs rename to crates/rundler/src/common/handle.rs diff --git a/src/common/math.rs b/crates/rundler/src/common/math.rs similarity index 100% rename from src/common/math.rs rename to crates/rundler/src/common/math.rs diff --git a/src/common/mempool.rs b/crates/rundler/src/common/mempool.rs similarity index 100% rename from src/common/mempool.rs rename to crates/rundler/src/common/mempool.rs diff --git a/src/common/mod.rs b/crates/rundler/src/common/mod.rs similarity index 100% rename from src/common/mod.rs rename to crates/rundler/src/common/mod.rs diff --git a/src/common/precheck.rs b/crates/rundler/src/common/precheck.rs similarity index 100% rename from src/common/precheck.rs rename to crates/rundler/src/common/precheck.rs diff --git a/src/common/protos.rs b/crates/rundler/src/common/protos.rs similarity index 100% rename from src/common/protos.rs rename to crates/rundler/src/common/protos.rs diff --git a/src/common/retry.rs b/crates/rundler/src/common/retry.rs similarity index 100% rename from src/common/retry.rs rename to crates/rundler/src/common/retry.rs diff --git a/src/common/server.rs b/crates/rundler/src/common/server.rs similarity index 100% rename from src/common/server.rs rename to crates/rundler/src/common/server.rs diff --git a/src/common/simulation.rs b/crates/rundler/src/common/simulation.rs similarity index 100% rename from src/common/simulation.rs rename to crates/rundler/src/common/simulation.rs diff --git a/src/common/strs.rs b/crates/rundler/src/common/strs.rs similarity index 100% rename from src/common/strs.rs rename to crates/rundler/src/common/strs.rs diff --git a/src/common/tracer.rs b/crates/rundler/src/common/tracer.rs similarity index 100% rename from src/common/tracer.rs rename to crates/rundler/src/common/tracer.rs diff --git a/src/common/types/chain.rs b/crates/rundler/src/common/types/chain.rs similarity index 100% rename from src/common/types/chain.rs rename to crates/rundler/src/common/types/chain.rs diff --git a/src/common/types/entry_point_like.rs b/crates/rundler/src/common/types/entry_point_like.rs similarity index 100% rename from src/common/types/entry_point_like.rs rename to crates/rundler/src/common/types/entry_point_like.rs diff --git a/src/common/types/mod.rs b/crates/rundler/src/common/types/mod.rs similarity index 100% rename from src/common/types/mod.rs rename to crates/rundler/src/common/types/mod.rs diff --git a/src/common/types/provider_like.rs b/crates/rundler/src/common/types/provider_like.rs similarity index 100% rename from src/common/types/provider_like.rs rename to crates/rundler/src/common/types/provider_like.rs diff --git a/src/common/types/timestamp.rs b/crates/rundler/src/common/types/timestamp.rs similarity index 100% rename from src/common/types/timestamp.rs rename to crates/rundler/src/common/types/timestamp.rs diff --git a/src/common/types/validation_results.rs b/crates/rundler/src/common/types/validation_results.rs similarity index 100% rename from src/common/types/validation_results.rs rename to crates/rundler/src/common/types/validation_results.rs diff --git a/src/common/types/violations.rs b/crates/rundler/src/common/types/violations.rs similarity index 100% rename from src/common/types/violations.rs rename to crates/rundler/src/common/types/violations.rs diff --git a/src/lib.rs b/crates/rundler/src/lib.rs similarity index 100% rename from src/lib.rs rename to crates/rundler/src/lib.rs diff --git a/src/op_pool/chain.rs b/crates/rundler/src/op_pool/chain.rs similarity index 100% rename from src/op_pool/chain.rs rename to crates/rundler/src/op_pool/chain.rs diff --git a/src/op_pool/emit.rs b/crates/rundler/src/op_pool/emit.rs similarity index 100% rename from src/op_pool/emit.rs rename to crates/rundler/src/op_pool/emit.rs diff --git a/src/op_pool/mempool/error.rs b/crates/rundler/src/op_pool/mempool/error.rs similarity index 100% rename from src/op_pool/mempool/error.rs rename to crates/rundler/src/op_pool/mempool/error.rs diff --git a/src/op_pool/mempool/mod.rs b/crates/rundler/src/op_pool/mempool/mod.rs similarity index 100% rename from src/op_pool/mempool/mod.rs rename to crates/rundler/src/op_pool/mempool/mod.rs diff --git a/src/op_pool/mempool/pool.rs b/crates/rundler/src/op_pool/mempool/pool.rs similarity index 100% rename from src/op_pool/mempool/pool.rs rename to crates/rundler/src/op_pool/mempool/pool.rs diff --git a/src/op_pool/mempool/reputation.rs b/crates/rundler/src/op_pool/mempool/reputation.rs similarity index 100% rename from src/op_pool/mempool/reputation.rs rename to crates/rundler/src/op_pool/mempool/reputation.rs diff --git a/src/op_pool/mempool/size.rs b/crates/rundler/src/op_pool/mempool/size.rs similarity index 100% rename from src/op_pool/mempool/size.rs rename to crates/rundler/src/op_pool/mempool/size.rs diff --git a/src/op_pool/mempool/uo_pool.rs b/crates/rundler/src/op_pool/mempool/uo_pool.rs similarity index 100% rename from src/op_pool/mempool/uo_pool.rs rename to crates/rundler/src/op_pool/mempool/uo_pool.rs diff --git a/src/op_pool/mod.rs b/crates/rundler/src/op_pool/mod.rs similarity index 100% rename from src/op_pool/mod.rs rename to crates/rundler/src/op_pool/mod.rs diff --git a/src/op_pool/server/error.rs b/crates/rundler/src/op_pool/server/error.rs similarity index 100% rename from src/op_pool/server/error.rs rename to crates/rundler/src/op_pool/server/error.rs diff --git a/src/op_pool/server/local.rs b/crates/rundler/src/op_pool/server/local.rs similarity index 100% rename from src/op_pool/server/local.rs rename to crates/rundler/src/op_pool/server/local.rs diff --git a/src/op_pool/server/mod.rs b/crates/rundler/src/op_pool/server/mod.rs similarity index 100% rename from src/op_pool/server/mod.rs rename to crates/rundler/src/op_pool/server/mod.rs diff --git a/src/op_pool/server/remote/client.rs b/crates/rundler/src/op_pool/server/remote/client.rs similarity index 100% rename from src/op_pool/server/remote/client.rs rename to crates/rundler/src/op_pool/server/remote/client.rs diff --git a/src/op_pool/server/remote/error.rs b/crates/rundler/src/op_pool/server/remote/error.rs similarity index 100% rename from src/op_pool/server/remote/error.rs rename to crates/rundler/src/op_pool/server/remote/error.rs diff --git a/src/op_pool/server/remote/mod.rs b/crates/rundler/src/op_pool/server/remote/mod.rs similarity index 100% rename from src/op_pool/server/remote/mod.rs rename to crates/rundler/src/op_pool/server/remote/mod.rs diff --git a/src/op_pool/server/remote/protos.rs b/crates/rundler/src/op_pool/server/remote/protos.rs similarity index 100% rename from src/op_pool/server/remote/protos.rs rename to crates/rundler/src/op_pool/server/remote/protos.rs diff --git a/src/op_pool/server/remote/server.rs b/crates/rundler/src/op_pool/server/remote/server.rs similarity index 100% rename from src/op_pool/server/remote/server.rs rename to crates/rundler/src/op_pool/server/remote/server.rs diff --git a/src/op_pool/task.rs b/crates/rundler/src/op_pool/task.rs similarity index 100% rename from src/op_pool/task.rs rename to crates/rundler/src/op_pool/task.rs diff --git a/src/rpc/debug.rs b/crates/rundler/src/rpc/debug.rs similarity index 100% rename from src/rpc/debug.rs rename to crates/rundler/src/rpc/debug.rs diff --git a/src/rpc/eth/api.rs b/crates/rundler/src/rpc/eth/api.rs similarity index 100% rename from src/rpc/eth/api.rs rename to crates/rundler/src/rpc/eth/api.rs diff --git a/src/rpc/eth/error.rs b/crates/rundler/src/rpc/eth/error.rs similarity index 100% rename from src/rpc/eth/error.rs rename to crates/rundler/src/rpc/eth/error.rs diff --git a/src/rpc/eth/estimation.rs b/crates/rundler/src/rpc/eth/estimation.rs similarity index 100% rename from src/rpc/eth/estimation.rs rename to crates/rundler/src/rpc/eth/estimation.rs diff --git a/src/rpc/eth/mod.rs b/crates/rundler/src/rpc/eth/mod.rs similarity index 100% rename from src/rpc/eth/mod.rs rename to crates/rundler/src/rpc/eth/mod.rs diff --git a/src/rpc/eth/server.rs b/crates/rundler/src/rpc/eth/server.rs similarity index 100% rename from src/rpc/eth/server.rs rename to crates/rundler/src/rpc/eth/server.rs diff --git a/src/rpc/health.rs b/crates/rundler/src/rpc/health.rs similarity index 100% rename from src/rpc/health.rs rename to crates/rundler/src/rpc/health.rs diff --git a/src/rpc/metrics.rs b/crates/rundler/src/rpc/metrics.rs similarity index 100% rename from src/rpc/metrics.rs rename to crates/rundler/src/rpc/metrics.rs diff --git a/src/rpc/mod.rs b/crates/rundler/src/rpc/mod.rs similarity index 100% rename from src/rpc/mod.rs rename to crates/rundler/src/rpc/mod.rs diff --git a/src/rpc/rundler.rs b/crates/rundler/src/rpc/rundler.rs similarity index 100% rename from src/rpc/rundler.rs rename to crates/rundler/src/rpc/rundler.rs diff --git a/src/rpc/task.rs b/crates/rundler/src/rpc/task.rs similarity index 100% rename from src/rpc/task.rs rename to crates/rundler/src/rpc/task.rs diff --git a/tracer/.gitignore b/crates/rundler/tracer/.gitignore similarity index 100% rename from tracer/.gitignore rename to crates/rundler/tracer/.gitignore diff --git a/tracer/.swcrc b/crates/rundler/tracer/.swcrc similarity index 100% rename from tracer/.swcrc rename to crates/rundler/tracer/.swcrc diff --git a/tracer/README.md b/crates/rundler/tracer/README.md similarity index 100% rename from tracer/README.md rename to crates/rundler/tracer/README.md diff --git a/tracer/package.json b/crates/rundler/tracer/package.json similarity index 100% rename from tracer/package.json rename to crates/rundler/tracer/package.json diff --git a/tracer/src/types.ts b/crates/rundler/tracer/src/types.ts similarity index 100% rename from tracer/src/types.ts rename to crates/rundler/tracer/src/types.ts diff --git a/tracer/src/validationTracer.ts b/crates/rundler/tracer/src/validationTracer.ts similarity index 100% rename from tracer/src/validationTracer.ts rename to crates/rundler/tracer/src/validationTracer.ts diff --git a/tracer/tsconfig.json b/crates/rundler/tracer/tsconfig.json similarity index 100% rename from tracer/tsconfig.json rename to crates/rundler/tracer/tsconfig.json diff --git a/tracer/yarn.lock b/crates/rundler/tracer/yarn.lock similarity index 100% rename from tracer/yarn.lock rename to crates/rundler/tracer/yarn.lock