File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed
aggregation_mode/proof_aggregator/src/backend Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -609,13 +609,14 @@ impl ProofAggregator {
609609 . get_max_priority_fee_per_gas ( )
610610 . await
611611 . map_err ( |e| AggregatedProofSubmissionError :: GasPriceError ( e. to_string ( ) ) ) ?
612- as f64 ;
612+ as u128 ;
613613
614- // Calculate priority fee: suggested * (1 + (attempt + 1) * 0.1) , capped at max
615- let priority_fee_multiplier = 1.0 + ( attempt + 1 ) as f64 * 0. 1;
614+ // Calculate priority fee: suggested * (1 + (attempt + 1), capped at max
615+ let priority_fee_multiplier = attempt + 1 ;
616616 let max_priority_fee_per_gas = ( suggested_priority_fee * priority_fee_multiplier)
617- . min ( max_priority_fee_upper_limit as f64 ) ;
617+ . min ( max_priority_fee_upper_limit) ;
618618
619+ // Calculate max fee with cumulative bump per attempt to ensure replacement tx is accepted
619620 let max_fee_multiplier = 1.0 + max_fee_bump_percentage as f64 / 100.0 ;
620621 let max_fee_per_gas = max_fee_multiplier * current_base_fee + max_priority_fee_per_gas;
621622
@@ -628,7 +629,7 @@ impl ProofAggregator {
628629
629630 Ok ( tx_req
630631 . with_max_fee_per_gas ( max_fee_per_gas as u128 )
631- . with_max_priority_fee_per_gas ( max_priority_fee_per_gas as u128 ) )
632+ . with_max_priority_fee_per_gas ( max_priority_fee_per_gas) )
632633 }
633634
634635 async fn wait_until_can_submit_aggregated_proof (
You can’t perform that action at this time.
0 commit comments