From 234e59bbea9367f6c1c6e716d7d4ff77fedb59ce Mon Sep 17 00:00:00 2001 From: Omar Abdulla Date: Sat, 1 Nov 2025 04:57:33 +0300 Subject: [PATCH] Remove references to kitchensink --- README.md | 8 +- crates/common/src/types/identifiers.rs | 6 - crates/config/src/lib.rs | 94 ------------ crates/core/src/lib.rs | 140 ------------------ .../src/node_implementations/substrate.rs | 9 +- run_tests.sh | 1 - 6 files changed, 8 insertions(+), 250 deletions(-) diff --git a/README.md b/README.md index a5aee14..bfa5684 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ This project compiles and executes declarative smart-contract tests against multiple platforms, then compares behavior (status, return data, events, and state diffs). Today it supports: - Geth (EVM reference implementation) -- Revive Kitchensink (Substrate-based PolkaVM + `eth-rpc` proxy) +- Revive Dev Node (Substrate-based PolkaVM + `eth-rpc` proxy) Use it to: @@ -39,9 +39,9 @@ This repository contains none of the tests and only contains the testing framewo This section describes the required dependencies that this framework requires to run. Compiling this framework is pretty straightforward and no additional dependencies beyond what's specified in the `Cargo.toml` file should be required. - Stable Rust -- Geth - When doing differential testing against the PVM we submit transactions to a Geth node and to Kitchensink to compare them. -- Kitchensink - When doing differential testing against the PVM we submit transactions to a Geth node and to Kitchensink to compare them. -- ETH-RPC - All communication with Kitchensink is done through the ETH RPC. +- Geth - When doing differential testing against the PVM we submit transactions to a Geth node and to Revive Dev Node to compare them. +- Revive Dev Node - When doing differential testing against the PVM we submit transactions to a Geth node and to Revive Dev Node to compare them. +- ETH-RPC - All communication with Revive Dev Node is done through the ETH RPC. - Solc - This is actually a transitive dependency, while this tool doesn't require solc as it downloads the versions that it requires, resolc requires that Solc is installed and available in the path. - Resolc - This is required to compile the contracts to PolkaVM bytecode. - Kurtosis - The Kurtosis CLI tool is required for the production Ethereum mainnet-like node configuration with Geth as the execution layer and lighthouse as the consensus layer. Kurtosis also requires docker to be installed since it runs everything inside of docker containers. diff --git a/crates/common/src/types/identifiers.rs b/crates/common/src/types/identifiers.rs index 2dd8563..8a6bdcd 100644 --- a/crates/common/src/types/identifiers.rs +++ b/crates/common/src/types/identifiers.rs @@ -31,10 +31,6 @@ pub enum PlatformIdentifier { GethEvmSolc, /// The Lighthouse Go-ethereum reference full node EVM implementation with the solc compiler. LighthouseGethEvmSolc, - /// The kitchensink node with the PolkaVM backend with the resolc compiler. - KitchensinkPolkavmResolc, - /// The kitchensink node with the REVM backend with the solc compiler. - KitchensinkRevmSolc, /// The revive dev node with the PolkaVM backend with the resolc compiler. ReviveDevNodePolkavmResolc, /// The revive dev node with the REVM backend with the solc compiler. @@ -95,8 +91,6 @@ pub enum NodeIdentifier { Geth, /// The go-ethereum node implementation. LighthouseGeth, - /// The Kitchensink node implementation. - Kitchensink, /// The revive dev node implementation. ReviveDevNode, /// A zombienet spawned nodes diff --git a/crates/config/src/lib.rs b/crates/config/src/lib.rs index 4798ad2..5964b70 100644 --- a/crates/config/src/lib.rs +++ b/crates/config/src/lib.rs @@ -131,17 +131,6 @@ impl AsRef for Context { } } -impl AsRef for Context { - fn as_ref(&self) -> &KitchensinkConfiguration { - match self { - Self::Test(context) => context.as_ref().as_ref(), - Self::Benchmark(context) => context.as_ref().as_ref(), - Self::ExportGenesis(context) => context.as_ref().as_ref(), - Self::ExportJsonSchema => unreachable!(), - } - } -} - impl AsRef for Context { fn as_ref(&self) -> &ReviveDevNodeConfiguration { match self { @@ -283,10 +272,6 @@ pub struct TestExecutionContext { #[clap(flatten, next_help_heading = "Lighthouse Configuration")] pub lighthouse_configuration: KurtosisConfiguration, - /// Configuration parameters for the Kitchensink. - #[clap(flatten, next_help_heading = "Kitchensink Configuration")] - pub kitchensink_configuration: KitchensinkConfiguration, - /// Configuration parameters for the Revive Dev Node. #[clap(flatten, next_help_heading = "Revive Dev Node Configuration")] pub revive_dev_node_configuration: ReviveDevNodeConfiguration, @@ -409,10 +394,6 @@ pub struct BenchmarkingContext { #[clap(flatten, next_help_heading = "Lighthouse Configuration")] pub lighthouse_configuration: KurtosisConfiguration, - /// Configuration parameters for the Kitchensink. - #[clap(flatten, next_help_heading = "Kitchensink Configuration")] - pub kitchensink_configuration: KitchensinkConfiguration, - /// Configuration parameters for the Polkadot Parachain. #[clap(flatten, next_help_heading = "Polkadot Parachain Configuration")] pub polkadot_parachain_configuration: PolkadotParachainConfiguration, @@ -491,10 +472,6 @@ pub struct ExportGenesisContext { #[clap(flatten, next_help_heading = "Lighthouse Configuration")] pub lighthouse_configuration: KurtosisConfiguration, - /// Configuration parameters for the Kitchensink. - #[clap(flatten, next_help_heading = "Kitchensink Configuration")] - pub kitchensink_configuration: KitchensinkConfiguration, - /// Configuration parameters for the Polkadot Parachain. #[clap(flatten, next_help_heading = "Polkadot Parachain Configuration")] pub polkadot_parachain_configuration: PolkadotParachainConfiguration, @@ -556,12 +533,6 @@ impl AsRef for TestExecutionContext { } } -impl AsRef for TestExecutionContext { - fn as_ref(&self) -> &KitchensinkConfiguration { - &self.kitchensink_configuration - } -} - impl AsRef for TestExecutionContext { fn as_ref(&self) -> &ReviveDevNodeConfiguration { &self.revive_dev_node_configuration @@ -658,12 +629,6 @@ impl AsRef for BenchmarkingContext { } } -impl AsRef for BenchmarkingContext { - fn as_ref(&self) -> &KitchensinkConfiguration { - &self.kitchensink_configuration - } -} - impl AsRef for BenchmarkingContext { fn as_ref(&self) -> &ReviveDevNodeConfiguration { &self.revive_dev_node_configuration @@ -718,12 +683,6 @@ impl AsRef for ExportGenesisContext { } } -impl AsRef for ExportGenesisContext { - fn as_ref(&self) -> &KitchensinkConfiguration { - &self.kitchensink_configuration - } -} - impl AsRef for ExportGenesisContext { fn as_ref(&self) -> &PolkadotParachainConfiguration { &self.polkadot_parachain_configuration @@ -842,30 +801,6 @@ pub struct KurtosisConfiguration { pub path: PathBuf, } -/// A set of configuration parameters for Kitchensink. -#[derive(Clone, Debug, Parser, Serialize, Deserialize)] -pub struct KitchensinkConfiguration { - /// Specifies the path of the kitchensink node to be used by the tool. - /// - /// If this is not specified, then the tool assumes that it should use the kitchensink binary - /// that's provided in the user's $PATH. - #[clap( - id = "kitchensink.path", - long = "kitchensink.path", - default_value = "substrate-node" - )] - pub path: PathBuf, - - /// The amount of time to wait upon startup before considering that the node timed out. - #[clap( - id = "kitchensink.start-timeout-ms", - long = "kitchensink.start-timeout-ms", - default_value = "30000", - value_parser = parse_duration - )] - pub start_timeout_ms: Duration, -} - /// A set of configuration parameters for the revive dev node. #[derive(Clone, Debug, Parser, Serialize, Deserialize)] pub struct ReviveDevNodeConfiguration { @@ -1161,35 +1096,6 @@ fn parse_duration(s: &str) -> anyhow::Result { .map_err(Into::into) } -/// The Solidity compatible node implementation. -/// -/// This describes the solutions to be tested against on a high level. -#[derive( - Clone, - Copy, - Debug, - PartialEq, - Eq, - PartialOrd, - Ord, - Hash, - Serialize, - ValueEnum, - EnumString, - Display, - AsRefStr, - IntoStaticStr, -)] -#[strum(serialize_all = "kebab-case")] -pub enum TestingPlatform { - /// The go-ethereum reference full node EVM implementation. - Geth, - /// The kitchensink runtime provides the PolkaVM (PVM) based node implementation. - Kitchensink, - /// A polkadot/Substrate based network - Zombienet, -} - /// The output format to use for the test execution output. #[derive( Clone, diff --git a/crates/core/src/lib.rs b/crates/core/src/lib.rs index fc6332b..12c8b1b 100644 --- a/crates/core/src/lib.rs +++ b/crates/core/src/lib.rs @@ -172,134 +172,6 @@ impl Platform for LighthouseGethEvmSolcPlatform { } } -#[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord, Default, Hash)] -pub struct KitchensinkPolkavmResolcPlatform; - -impl Platform for KitchensinkPolkavmResolcPlatform { - fn platform_identifier(&self) -> PlatformIdentifier { - PlatformIdentifier::KitchensinkPolkavmResolc - } - - fn node_identifier(&self) -> NodeIdentifier { - NodeIdentifier::Kitchensink - } - - fn vm_identifier(&self) -> VmIdentifier { - VmIdentifier::PolkaVM - } - - fn compiler_identifier(&self) -> CompilerIdentifier { - CompilerIdentifier::Resolc - } - - fn new_node( - &self, - context: Context, - ) -> anyhow::Result>>> { - let genesis_configuration = AsRef::::as_ref(&context); - let kitchensink_path = AsRef::::as_ref(&context) - .path - .clone(); - let genesis = genesis_configuration.genesis()?.clone(); - Ok(thread::spawn(move || { - let node = SubstrateNode::new( - kitchensink_path, - SubstrateNode::KITCHENSINK_EXPORT_CHAINSPEC_COMMAND, - None, - context, - &[], - ); - let node = spawn_node(node, genesis)?; - Ok(Box::new(node) as Box<_>) - })) - } - - fn new_compiler( - &self, - context: Context, - version: Option, - ) -> Pin>>>> { - Box::pin(async move { - let compiler = Resolc::new(context, version).await; - compiler.map(|compiler| Box::new(compiler) as Box) - }) - } - - fn export_genesis(&self, context: Context) -> anyhow::Result { - let kitchensink_path = AsRef::::as_ref(&context) - .path - .as_path(); - let wallet = AsRef::::as_ref(&context).wallet(); - let export_chainspec_command = SubstrateNode::KITCHENSINK_EXPORT_CHAINSPEC_COMMAND; - - SubstrateNode::node_genesis(kitchensink_path, export_chainspec_command, &wallet) - } -} - -#[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord, Default, Hash)] -pub struct KitchensinkRevmSolcPlatform; - -impl Platform for KitchensinkRevmSolcPlatform { - fn platform_identifier(&self) -> PlatformIdentifier { - PlatformIdentifier::KitchensinkRevmSolc - } - - fn node_identifier(&self) -> NodeIdentifier { - NodeIdentifier::Kitchensink - } - - fn vm_identifier(&self) -> VmIdentifier { - VmIdentifier::Evm - } - - fn compiler_identifier(&self) -> CompilerIdentifier { - CompilerIdentifier::Solc - } - - fn new_node( - &self, - context: Context, - ) -> anyhow::Result>>> { - let genesis_configuration = AsRef::::as_ref(&context); - let kitchensink_path = AsRef::::as_ref(&context) - .path - .clone(); - let genesis = genesis_configuration.genesis()?.clone(); - Ok(thread::spawn(move || { - let node = SubstrateNode::new( - kitchensink_path, - SubstrateNode::KITCHENSINK_EXPORT_CHAINSPEC_COMMAND, - None, - context, - &[], - ); - let node = spawn_node(node, genesis)?; - Ok(Box::new(node) as Box<_>) - })) - } - - fn new_compiler( - &self, - context: Context, - version: Option, - ) -> Pin>>>> { - Box::pin(async move { - let compiler = Solc::new(context, version).await; - compiler.map(|compiler| Box::new(compiler) as Box) - }) - } - - fn export_genesis(&self, context: Context) -> anyhow::Result { - let kitchensink_path = AsRef::::as_ref(&context) - .path - .as_path(); - let wallet = AsRef::::as_ref(&context).wallet(); - let export_chainspec_command = SubstrateNode::KITCHENSINK_EXPORT_CHAINSPEC_COMMAND; - - SubstrateNode::node_genesis(kitchensink_path, export_chainspec_command, &wallet) - } -} - #[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord, Default, Hash)] pub struct ReviveDevNodePolkavmResolcPlatform; @@ -557,12 +429,6 @@ impl From for Box { PlatformIdentifier::LighthouseGethEvmSolc => { Box::new(LighthouseGethEvmSolcPlatform) as Box<_> } - PlatformIdentifier::KitchensinkPolkavmResolc => { - Box::new(KitchensinkPolkavmResolcPlatform) as Box<_> - } - PlatformIdentifier::KitchensinkRevmSolc => { - Box::new(KitchensinkRevmSolcPlatform) as Box<_> - } PlatformIdentifier::ReviveDevNodePolkavmResolc => { Box::new(ReviveDevNodePolkavmResolcPlatform) as Box<_> } @@ -584,12 +450,6 @@ impl From for &dyn Platform { PlatformIdentifier::LighthouseGethEvmSolc => { &LighthouseGethEvmSolcPlatform as &dyn Platform } - PlatformIdentifier::KitchensinkPolkavmResolc => { - &KitchensinkPolkavmResolcPlatform as &dyn Platform - } - PlatformIdentifier::KitchensinkRevmSolc => { - &KitchensinkRevmSolcPlatform as &dyn Platform - } PlatformIdentifier::ReviveDevNodePolkavmResolc => { &ReviveDevNodePolkavmResolcPlatform as &dyn Platform } diff --git a/crates/node/src/node_implementations/substrate.rs b/crates/node/src/node_implementations/substrate.rs index 69f64de..498d2bf 100644 --- a/crates/node/src/node_implementations/substrate.rs +++ b/crates/node/src/node_implementations/substrate.rs @@ -92,7 +92,6 @@ impl SubstrateNode { const SUBSTRATE_LOG_ENV: &str = "error,evm=debug,sc_rpc_server=info,runtime::revive=debug"; const PROXY_LOG_ENV: &str = "info,eth-rpc=debug"; - pub const KITCHENSINK_EXPORT_CHAINSPEC_COMMAND: &str = "export-chain-spec"; pub const REVIVE_DEV_NODE_EXPORT_CHAINSPEC_COMMAND: &str = "build-spec"; pub fn new( @@ -800,8 +799,8 @@ mod tests { let context = test_config(); let mut node = SubstrateNode::new( - context.kitchensink_configuration.path.clone(), - SubstrateNode::KITCHENSINK_EXPORT_CHAINSPEC_COMMAND, + context.revive_dev_node_configuration.path.clone(), + SubstrateNode::REVIVE_DEV_NODE_EXPORT_CHAINSPEC_COMMAND, None, &context, &[], @@ -867,8 +866,8 @@ mod tests { let context = test_config(); let mut dummy_node = SubstrateNode::new( - context.kitchensink_configuration.path.clone(), - SubstrateNode::KITCHENSINK_EXPORT_CHAINSPEC_COMMAND, + context.revive_dev_node_configuration.path.clone(), + SubstrateNode::REVIVE_DEV_NODE_EXPORT_CHAINSPEC_COMMAND, None, &context, &[], diff --git a/run_tests.sh b/run_tests.sh index 1295d86..df7ae54 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -84,7 +84,6 @@ RUST_LOG="info,alloy_pubsub::service=error" ./target/release/retester test \ --concurrency.number-of-threads 5 \ --concurrency.number-of-concurrent-tasks 500 \ --wallet.additional-keys 100000 \ - --kitchensink.path "$SUBSTRATE_NODE_BIN" \ --revive-dev-node.path "$REVIVE_DEV_NODE_BIN" \ --eth-rpc.path "$ETH_RPC_BIN" \ > logs.log \