dmihal / l2-fees

l2-fees.vercel.app
31 stars 16 forks source link

Suggestion: use a rolling average instead of real-time prices #6

Closed smartcontracts closed 2 years ago

smartcontracts commented 2 years ago

L2Fees currently uses real-time prices. However, rollup prices fluctuate quite heavily with time (since L1 fees fluctuate heavily) and it's likely that the price that the user will pay by the time they execute a transaction is quite different than the price displayed by L2Fees.

There's also the issue of accurate comparison: L2 prices update at different rates and I'll often see one network with a much higher cost than another for a few minutes and then refresh the page to see that the rates have equalized. A user who views the page during this time window might have a very unrealistic view of the average costs of different networks. Since L2Fees is mainly being used to compare overall costs (not for estimating real-time costs), I think it makes more sense to use a rolling average over some short time window (maybe 24 hours?).

smartcontracts commented 2 years ago

Another point of reference for this argument: L2Fees often gets cited in Tweets (screenshots) which attempt to highlight the current overall costs of using L2. Since L2Fees only shows the spot cost of using the listed systems, screenshots can be very misleading and might push people away from one system or towards another.

smartcontracts commented 2 years ago

Also, I'd be happy to help implement this if you think this is a reasonable request.

dmihal commented 2 years ago

Closing this issue, as I believe @smartcontracts has included this in the Optimism adapter on CryptoStats

https://cryptostats.community/discover/l2-fees/optimism-transaction-fees