solana
solana copied to clipboard
Remove congestion multiplier from calculate fee
Problem
congestion_multiplier
variable in sdk::fee_structure::calculate_fee(...)
does not have to do with congestion, it actually zeros out transaction fee for tests that don't handle transaction fees - those tests sets fee rate to zero in genesis config.
It is better to sync up fee_structure with fee_rate_governor during bank initialization to support those tests.
Summary of Changes
- set fee_structure.lamports_per_signature by fee_rate_governor during bank initialization
- remove
congestion_multiplier
in calculation_fee()
Fixes #
as Draft until rebaseed after #34821 is merged
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
a5c470d
) 81.7% compared to head (d8fff7f
) 81.7%. Report is 7 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #34865 +/- ##
=========================================
- Coverage 81.7% 81.7% -0.1%
=========================================
Files 826 826
Lines 223413 223411 -2
=========================================
- Hits 182614 182573 -41
- Misses 40799 40838 +39