-
Notifications
You must be signed in to change notification settings - Fork 269
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature Request] Calculate Minimum Transaction Fee for each Block #276
Comments
Is it something that you could calculate on your side from existing info? Or there is some piece of information missing that should be exposed by the explorer? |
There is very little documentation or understanding surrounding how the "base fee" is calculated, it seems there are a lot of moving parts. I've been trying to figure it out for myself to write a blog post to help others. If the block explorer automatically did this, I think it would also help people understand more about the fee paid in a transaction, relational to the base they had to pay. I think there is certain information needed that needs to be calculated for each block, but I am not certain. Also I have a 0.2 xmr bounty outstanding for anyone who makes it possible to get the base transaction fee of an arbitrary block on-chain, its not a lot of xmr but its something. |
Monero daemon has RPC https://github.com/monero-project/monero/blob/master/src/wallet/wallet2.cpp#L7338 If that would help, I could expose that? |
Yea that would work! But would this work for past blocks or just for the newest one? |
I think its for the current ones only. |
Would you know how to make it work for any arbitrary block? My problem is that I need to know the average "base transaction fee" over a 100,000 block period starting at block #2566273. |
At the moment I'm not sure. Would have too look into it in more depth. Maybe you could ask on reddit if there is some easy way? |
Have you check the json api for the explorer: https://github.com/moneroexamples/onion-monero-blockchain-explorer#apinetworkinfo |
Yea it looks like it makes an RPC call to get it, I don't think it would allow me to return the fee_per_kb of an arbitrary block :/ onion-monero-blockchain-explorer/src/MempoolStatus.cpp Lines 239 to 241 in aa96ce2
|
Its only based on current blocks. Is there any API in monero itself to get a fee estimate for any block? |
I dont believe so, but I wish there was one |
Would you be able to expose the |
This is a selfish request as I am creating a chart at the moment which needs this information and there is no historical source which I can pull the data from. I will recalculate the values myself but it would be really cool if the XMR block explorer advertised the base transaction fee for the block, even if it was an estimate.
https://www.getmonero.org/2017/12/11/A-note-on-fees.html
https://github.com/monero-project/monero/blob/master/tests/unit_tests/fee.cpp
The text was updated successfully, but these errors were encountered: