From 884490e634f422008d4f5db88378aa1d5827d17e Mon Sep 17 00:00:00 2001 From: andrussal Date: Wed, 17 Dec 2025 09:10:09 +0100 Subject: [PATCH] fix(scripts): stabilize bundle + runners smoke tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Fix rapidsnark rebuild path in setup-nomos-circuits (Docker linux builds) - Fix compose template path after runners→deployers rename - Make local_runner 30s host run a pure smoke test --- examples/src/bin/local_runner.rs | 20 +++++++++++++------ scripts/setup-nomos-circuits.sh | 2 +- .../compose/src/infrastructure/template.rs | 2 +- 3 files changed, 16 insertions(+), 8 deletions(-) diff --git a/examples/src/bin/local_runner.rs b/examples/src/bin/local_runner.rs index 512cfb5..23fb2a3 100644 --- a/examples/src/bin/local_runner.rs +++ b/examples/src/bin/local_runner.rs @@ -13,6 +13,7 @@ const MIXED_TXS_PER_BLOCK: u64 = 5; const TOTAL_WALLETS: usize = 1000; const TRANSACTION_WALLETS: usize = 500; const DA_BLOB_RATE: u64 = 1; +const SMOKE_RUN_SECS_MAX: u64 = 30; #[tokio::main] async fn main() { @@ -55,15 +56,22 @@ async fn run_local_case(validators: usize, executors: usize, run_duration: Durat "building scenario plan" ); - let mut plan = ScenarioBuilder::topology_with(|t| { + let scenario = ScenarioBuilder::topology_with(|t| { t.network_star().validators(validators).executors(executors) }) .wallets(TOTAL_WALLETS) - .transactions_with(|txs| txs.rate(MIXED_TXS_PER_BLOCK).users(TRANSACTION_WALLETS)) - .da_with(|da| da.blob_rate(DA_BLOB_RATE)) - .with_run_duration(run_duration) - .expect_consensus_liveness() - .build(); + .with_run_duration(run_duration); + + let scenario = if run_duration.as_secs() <= SMOKE_RUN_SECS_MAX { + scenario + } else { + scenario + .transactions_with(|txs| txs.rate(MIXED_TXS_PER_BLOCK).users(TRANSACTION_WALLETS)) + .da_with(|da| da.blob_rate(DA_BLOB_RATE)) + .expect_consensus_liveness() + }; + + let mut plan = scenario.build(); let deployer = LocalDeployer::default().with_membership_check(true); info!("deploying local nodes"); diff --git a/scripts/setup-nomos-circuits.sh b/scripts/setup-nomos-circuits.sh index ed6cd12..198a5b3 100755 --- a/scripts/setup-nomos-circuits.sh +++ b/scripts/setup-nomos-circuits.sh @@ -235,7 +235,7 @@ setup_nomos_circuits::maybe_rebuild_rapidsnark() { if [[ "${REBUILD_REQUIRED}" == "1" ]]; then echo setup_nomos_circuits::print_info "Rebuilding rapidsnark prover for ${PLATFORM}..." - "${SCRIPT_DIR}/build-rapidsnark.sh" "${INSTALL_DIR}" + "${SCRIPT_DIR}/scripts/build-rapidsnark.sh" "${INSTALL_DIR}" else setup_nomos_circuits::print_info "Skipping rapidsnark rebuild (set NOMOS_CIRCUITS_REBUILD_RAPIDSNARK=1 to force)." fi diff --git a/testing-framework/deployers/compose/src/infrastructure/template.rs b/testing-framework/deployers/compose/src/infrastructure/template.rs index e913119..b98a74c 100644 --- a/testing-framework/deployers/compose/src/infrastructure/template.rs +++ b/testing-framework/deployers/compose/src/infrastructure/template.rs @@ -10,7 +10,7 @@ use tracing::{debug, info}; use crate::descriptor::ComposeDescriptor; const TEMPLATE_RELATIVE_PATH: &str = - "testing-framework/runners/compose/assets/docker-compose.yml.tera"; + "testing-framework/deployers/compose/assets/docker-compose.yml.tera"; /// Errors when templating docker-compose files. #[derive(Debug, thiserror::Error)]