Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

bug: supply calculator does not regard transactions sent to genesis wallet

See original GitHub issue

Expected Behavior

Proper calculation of the supply taking into account burned tokens.

Current Behavior

The supply calculator calculates the supply based on the totalAmount of the genesis block and all forging rewards. This method does not take into account transactions sent to the genesis wallet, i.e. effectively burned tokens.

Possible Solution

Take into account transactions sent to the genesis wallet (or wallets? basically all senders of transfer transactions), of the genesis block.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:12 (11 by maintainers)

github_iconTop GitHub Comments

rainydiocommented, Feb 24, 2020

Created #3530

rainydiocommented, Feb 21, 2020

You can use not-so-random address 000000000000000000000000000000DEAD (needs to be adjusted to network). My second statement was incorrect, sorry about that.

There is an issue with whole approach of sending tokens to any kind burn address (genesis, random, not-so-random). You have to re-implement every possible balance-transferring transaction in supply calculation. And it’s unknown what kind of balance-transfer transaction bridgechain may deploy.

In your PR #3443 you forgot to include htlc-claim which in a way can also be used to burn tokens. I understand that it is ridiculous to use htlc to burn tokens. But I’m trying to show that it’s difficult to correctly re-implement balance-transfer logic even when you do know all transaction types.

I think cleaner approach is to add new kind of transaction type deliberately designed to burn tokens and include it in core. It has legit use-cases as stand-alone transaction type. If @faustbrian is fine with that, I can create ticket for to implement it (3.0 or later). It should be simple.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Burn balance transaction · Issue #3530 · ArkEcosystem/core · GitHub
Calculating supply is prone to errors without dedicated burn transaction. ... bug: supply calculator does not regard transactions sent to genesis wallet # ......
Read more >
Hidden surprises in the Bitcoin blockchain and how they are ...
Every Bitcoin transaction is stored in the distributed database known as the Bitcoin blockchain. However, people have found ways to hack the ...
Read more >
Some of my transactions are missing the cost basis or ...
This most commonly occurs when we do not have the price history of a particular coin or if we do not have your...
Read more >
Blockchain Genesis (White Paper)
Abstract—In this White Paper, we describe Blockchain Genesis ... All transactions sent to a blockchain are validated by validators.
Read more >
Ethereum Staking Calculator & Best ETH Staking Pools
Learn about Ethereum staking including how to stake ETH, pros, cons, how much money you can make, and what happens after the Merge....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found