I was trying to add Frontier into my parachain as a dependency... then I got this error
Compiling parachain-template-runtime v0.1.0 (/mnt/sda3/polkadot/substrate-parachain-template-evm/runtime)
error[E0412]: cannot find type `BaseFee` in this scope
--> /mnt/sda3/polkadot/substrate-parachain-template-evm/runtime/src/lib.rs:415:23
|
415 | type FeeCalculator = BaseFee;
| ^^^^^^^ not found in this scope
But I don't know how to import this BaseFee
because I could not find where it was imported from in the Frontier repository's template/runtime/src/lib.rs:
https://github.com/paritytech/frontier/blob/polkadot-v0.9.25/template/runtime/src/lib.rs#L330
impl pallet_evm::Config for Runtime {
type FeeCalculator = BaseFee;//from Frontier template, where is this declared?
//type FeeCalculator = FixedGasPrice;//from moombeam;
//type FeeCalculator = ();//From JoshOrndorff
...
}
or should I use the FixedGasPrice
from Moombeam?
pub struct FixedGasPrice;
impl FeeCalculator for FixedGasPrice {
fn min_gas_price() -> (U256, Weight) {
(
(1 * currency::GIGAWEI * currency::SUPPLY_FACTOR).into(),
1u64,
)
}
What is the difference? It seems I can use FixedGasPrice
to set the minimum gasPrice...
so that the user must pay 1 * currency::GIGAWEI * currency::SUPPLY_FACTOR
for every 1u64
amount of Weight. right?