From 62195d485be6946d43658cfe558de23bb0ad1338 Mon Sep 17 00:00:00 2001 From: Lucas B Date: Mon, 26 Jun 2023 17:18:57 -0500 Subject: [PATCH] pr feedback --- core/src/banking_stage/consumer.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/src/banking_stage/consumer.rs b/core/src/banking_stage/consumer.rs index c333c75cacd402..d3a4b82011b14e 100644 --- a/core/src/banking_stage/consumer.rs +++ b/core/src/banking_stage/consumer.rs @@ -472,9 +472,9 @@ impl Consumer { .. } = execute_and_commit_transactions_output; - // The transaction scheduler may allocate costs for transactions that don't get executed - // due to AccountInUse, InsufficientFunds, and other errors. Those costs should be removed - // to ensure accurate tracking of compute units. + // Costs of all transactions are added before processing. + // To ensure accurate tracking of compute units, transactions that ultimately + // were not included in the block should have their cost removed. QosService::remove_costs( transaction_qos_cost_results.iter(), commit_transactions_result.as_ref().ok(),