Skip to content
This repository has been archived by the owner on Sep 26, 2024. It is now read-only.

Top level economic stats #189

Open
8 of 15 tasks
ilblackdragon opened this issue Feb 19, 2020 · 4 comments
Open
8 of 15 tasks

Top level economic stats #189

ilblackdragon opened this issue Feb 19, 2020 · 4 comments

Comments

@ilblackdragon
Copy link
Member

ilblackdragon commented Feb 19, 2020

We need many different economics stats, but here are the most important:

Supply breakdown:

  • Liquid tokens
  • Staked tokens
  • Locked tokens
  • ? unclaimed / etc tokens

Note that locked tokens can be staked. Unclaimed tokens from airdrops, etc.

Validator stats:

  • Number of validator seats
  • Validator seat threshold
  • Amount of staked / delegated tokens, ratio to total supply
  • Reward %, inflation %
  • Number of blocks until next epoch
@frol
Copy link
Collaborator

frol commented Feb 19, 2020

@ilblackdragon Could you, please, match the RPC data to the items you listed? For example, let's take "Total supply over time": there will be total supply exposed via Genesis Config near/nearcore#2109, but where should we learn about the "over time" part? I guess, it is a monotonic function, so we can compute it based on the block height, but the one who implements this issue needs to learn how to do that.

@frol frol assigned ilblackdragon and unassigned kcole16 Feb 19, 2020
@ilblackdragon
Copy link
Member Author

For general stats:

  • Total supply -> block.header.total_supply
  • Epoch reward -> (0.05 / (total_blocks_in_the_year / epoch_length)) * block.header.total_supply
  • Fees burnt -> block.header.rent_paid + block.header.gas_price * sum(for each chunk -> chunk.header.gas_used)
  • Gas spent / limit -> sum(for each chunk -> chunk.header.gas_used) / sum(for each chunk -> chunk.header.gas_limit)
  • Gas price -> block.header.gas_price
  • State size -> ??? @bowenwang1996 rent_paid / rent_cost?

@ilblackdragon ilblackdragon assigned frol and unassigned ilblackdragon Feb 20, 2020
@frol
Copy link
Collaborator

frol commented Feb 20, 2020

@kcole16 it seems that we need design for this thing. I imagine that we need dashboard changes here and at the same time we don’t want to bloat it, which is a hard task (maybe we should have a carousel of various stats or just have a toggle to show more stats while be default we only show the generic ones)

@frol frol assigned kcole16 and unassigned frol Feb 20, 2020
@frol frol added the Item Design Requires discovery and/or deliverables from Product Design label Apr 4, 2020
@frol
Copy link
Collaborator

frol commented Oct 22, 2020

@icerove icerove mentioned this issue Feb 16, 2021
10 tasks
@exalate-issue-sync exalate-issue-sync bot added Item_Design New_Feature and removed New Feature Item Design Requires discovery and/or deliverables from Product Design labels Nov 22, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants