Skip to content

Commit

Permalink
Call wait_for_completed_scheduler in banking simulator
Browse files Browse the repository at this point in the history
  • Loading branch information
ryoqun committed Jan 6, 2025
1 parent a1bc4b9 commit 5b1b19b
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ agave-banking-stage-ingress-types = { workspace = true }
ahash = { workspace = true }
anyhow = { workspace = true }
arrayvec = { workspace = true }
assert_matches = { workspace = true }
base64 = { workspace = true }
bincode = { workspace = true }
bs58 = { workspace = true }
Expand Down
4 changes: 4 additions & 0 deletions core/src/banking_simulation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ use {
validator::BlockProductionMethod,
},
agave_banking_stage_ingress_types::BankingPacketBatch,
assert_matches::assert_matches,
bincode::deserialize_from,
crossbeam_channel::{unbounded, Sender},
itertools::Itertools,
Expand Down Expand Up @@ -452,6 +453,9 @@ impl SimulatorLoop {
info!("Bank::new_from_parent()!");

logger.log_jitter(&bank);
if let Some((result, _execute_timings)) = bank.wait_for_completed_scheduler() {
assert_matches!(result, Ok(()));
}
bank.freeze();
let new_slot = if bank.slot() == self.parent_slot {
info!("initial leader block!");
Expand Down
1 change: 1 addition & 0 deletions programs/sbf/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions svm/examples/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 5b1b19b

Please sign in to comment.