Co-authored-by: behzad nouri <behzadnouri@gmail.com>
This commit is contained in:
@@ -299,7 +299,7 @@ fn simulate_process_entries(
|
||||
hash: next_hash(&bank.last_blockhash(), 1, &tx_vector),
|
||||
transactions: tx_vector,
|
||||
};
|
||||
process_entries(&bank, &[entry], randomize_txs, None, None).unwrap();
|
||||
process_entries(&bank, &mut [entry], randomize_txs, None, None).unwrap();
|
||||
}
|
||||
|
||||
#[allow(clippy::same_item_push)]
|
||||
|
@@ -751,7 +751,6 @@ impl BankingStage {
|
||||
if num_to_commit != 0 {
|
||||
let tx_results = bank.commit_transactions(
|
||||
txs,
|
||||
None,
|
||||
&mut loaded_accounts,
|
||||
&results,
|
||||
tx_count,
|
||||
@@ -766,7 +765,6 @@ impl BankingStage {
|
||||
transaction_status_sender.send_transaction_status_batch(
|
||||
bank.clone(),
|
||||
batch.transactions(),
|
||||
batch.iteration_order_vec(),
|
||||
tx_results.execution_results,
|
||||
TransactionBalancesSet::new(pre_balances, post_balances),
|
||||
TransactionTokenBalancesSet::new(pre_token_balances, post_token_balances),
|
||||
@@ -802,7 +800,7 @@ impl BankingStage {
|
||||
let mut lock_time = Measure::start("lock_time");
|
||||
// Once accounts are locked, other threads cannot encode transactions that will modify the
|
||||
// same account state
|
||||
let batch = bank.prepare_batch(txs, None);
|
||||
let batch = bank.prepare_batch(txs);
|
||||
lock_time.stop();
|
||||
|
||||
let (result, mut retryable_txs) = Self::process_and_record_transactions_locked(
|
||||
@@ -995,7 +993,6 @@ impl BankingStage {
|
||||
};
|
||||
let result = bank.check_transactions(
|
||||
transactions,
|
||||
None,
|
||||
&filter,
|
||||
(MAX_PROCESSING_AGE)
|
||||
.saturating_sub(max_tx_fwd_delay)
|
||||
|
@@ -2740,7 +2740,7 @@ pub(crate) mod tests {
|
||||
let fail_tx =
|
||||
system_transaction::transfer(&mint_keypair, &keypair2.pubkey(), 2, Hash::default());
|
||||
let entry_3 = next_entry(&entry_2.hash, 1, vec![fail_tx]);
|
||||
let entries = vec![entry_1, entry_2, entry_3];
|
||||
let mut entries = vec![entry_1, entry_2, entry_3];
|
||||
|
||||
let shreds = entries_to_test_shreds(entries.clone(), slot, previous_slot, true, 0);
|
||||
blockstore.insert_shreds(shreds, None, false).unwrap();
|
||||
@@ -2759,7 +2759,7 @@ pub(crate) mod tests {
|
||||
// that they are matched properly by get_rooted_block
|
||||
let _result = blockstore_processor::process_entries(
|
||||
&bank,
|
||||
&entries,
|
||||
&mut entries,
|
||||
true,
|
||||
Some(TransactionStatusSender {
|
||||
sender: transaction_status_sender,
|
||||
|
@@ -4,9 +4,8 @@ use solana_ledger::{
|
||||
blockstore::Blockstore,
|
||||
blockstore_processor::{TransactionStatusBatch, TransactionStatusMessage},
|
||||
};
|
||||
use solana_runtime::{
|
||||
bank::{Bank, InnerInstructionsList, NonceRollbackInfo, TransactionLogMessages},
|
||||
transaction_utils::OrderedIterator,
|
||||
use solana_runtime::bank::{
|
||||
Bank, InnerInstructionsList, NonceRollbackInfo, TransactionLogMessages,
|
||||
};
|
||||
use solana_transaction_status::{InnerInstructions, TransactionStatusMeta};
|
||||
use std::{
|
||||
@@ -58,7 +57,6 @@ impl TransactionStatusService {
|
||||
TransactionStatusMessage::Batch(TransactionStatusBatch {
|
||||
bank,
|
||||
transactions,
|
||||
iteration_order,
|
||||
statuses,
|
||||
balances,
|
||||
token_balances,
|
||||
@@ -80,7 +78,7 @@ impl TransactionStatusService {
|
||||
Box::new(std::iter::repeat_with(Vec::new))
|
||||
};
|
||||
for (
|
||||
(_, transaction),
|
||||
transaction,
|
||||
(status, nonce_rollback),
|
||||
pre_balances,
|
||||
post_balances,
|
||||
@@ -89,7 +87,7 @@ impl TransactionStatusService {
|
||||
inner_instructions,
|
||||
log_messages,
|
||||
) in izip!(
|
||||
OrderedIterator::new(&transactions, iteration_order.as_deref()),
|
||||
&transactions,
|
||||
statuses,
|
||||
balances.pre_balances,
|
||||
balances.post_balances,
|
||||
|
Reference in New Issue
Block a user