Closed
Description
Problem
Right now, Katana hardcoded the gas prices value. These gas prices are then used for computing the fees that transactions has to pay.
Though it works fine when using Katana just for testing/dev environment but for actual production setting we want to properly sample the L1 gas prices. Refer to the doc below for how starknet sample the l1 gas price:
Implementation for the gas oracle component should be able to (1) perform actual sampling on the underlying L1, (2) hardcoded value when katana is not run with an L1 (ie testing env).
On every new block, we'd then need to update the gas price values that have been sampled, in the block env:
dojo/crates/katana/core/src/backend/mod.rs
Lines 101 to 117 in e6bab2d