[pallet-revive] fee estimation fixes (#7281)
- Fix the EVM fee cost estimation. The estimation shown in EVM wallet was using Native instead of EVM decimals - Remove the precise code length estimation in dry run call. Over-estimating is fine, since extra gas is refunded anyway. - Ensure that the estimated fee calculated from gas_price x gas use the encoded weight & deposit limit instead of the exact one calculated by the dry-run. Else we can end up with a fee that is lower than the actual fee paid by the user --------- Co-authored-by: command-bot <>
Showing
- cumulus/parachains/runtimes/assets/asset-hub-westend/src/lib.rs 5 additions, 1 deletion...s/parachains/runtimes/assets/asset-hub-westend/src/lib.rs
- prdoc/pr_7281.prdoc 13 additions, 0 deletionsprdoc/pr_7281.prdoc
- substrate/bin/node/runtime/src/lib.rs 4 additions, 0 deletionssubstrate/bin/node/runtime/src/lib.rs
- substrate/frame/revive/rpc/examples/js/src/build-contracts.ts 1 addition, 1 deletion...trate/frame/revive/rpc/examples/js/src/build-contracts.ts
- substrate/frame/revive/rpc/examples/js/src/geth-diff.test.ts 83 additions, 79 deletionssubstrate/frame/revive/rpc/examples/js/src/geth-diff.test.ts
- substrate/frame/revive/rpc/examples/js/src/util.ts 10 additions, 1 deletionsubstrate/frame/revive/rpc/examples/js/src/util.ts
- substrate/frame/revive/rpc/revive_chain.metadata 0 additions, 0 deletionssubstrate/frame/revive/rpc/revive_chain.metadata
- substrate/frame/revive/rpc/src/client.rs 6 additions, 11 deletionssubstrate/frame/revive/rpc/src/client.rs
- substrate/frame/revive/src/benchmarking/mod.rs 4 additions, 2 deletionssubstrate/frame/revive/src/benchmarking/mod.rs
- substrate/frame/revive/src/evm/gas_encoder.rs 11 additions, 0 deletionssubstrate/frame/revive/src/evm/gas_encoder.rs
- substrate/frame/revive/src/evm/runtime.rs 22 additions, 42 deletionssubstrate/frame/revive/src/evm/runtime.rs
- substrate/frame/revive/src/exec.rs 3 additions, 3 deletionssubstrate/frame/revive/src/exec.rs
- substrate/frame/revive/src/lib.rs 79 additions, 50 deletionssubstrate/frame/revive/src/lib.rs
- substrate/frame/revive/src/primitives.rs 8 additions, 0 deletionssubstrate/frame/revive/src/primitives.rs
Please register or sign in to comment