bitcoin icon indicating copy to clipboard operation
bitcoin copied to clipboard

The index of address balances does not work well

Open ander7agar opened this issue 7 years ago • 2 comments

I have been testing version 0.12.1, and I have seen that the address balance index does not work correctly. It seems to be missing some transactions to be indexed. For example, the balance of the address 12c6DSiU4Rq3P4ZxziKxzrL5LmMBrzjrJX according to blockchain.info should be 50.0587895 BTC, but the core returns only 0.0587895 BTC, 50 BTC is missing.

my@explorer:~# bitcoin-cli getaddressbalance '{"addresses": ["12c6DSiU4Rq3P4ZxziKxzrL5LmMBrzjrJX"]}'
{
  "balance": 5878950,
  "received": 5878950
}

The first time this happened I turned off the core and re-executed it with reindex = 1, but when I finished I saw the balance of the same address again and returned the same. I have bought other addresses such as 1HLoD9E4SDFFPDiYfNYnkBLQ85Y51J3Zb1 and 50 BTCs too.

my@explorer:~# bitcoin-cli getaddressbalance '{"addresses": ["1HLoD9E4SDFFPDiYfNYnkBLQ85Y51J3Zb1"]}'
{
  "balance": 998292,
  "received": 998292
}

Interestingly, the amount that is missing is the same amount as the first transaction they received (Coinbase)

ander7agar avatar Nov 20 '17 17:11 ander7agar

I confirm. Tons of wrong balances. Running two full nodes and both of them has same problems with incorrect balances.

UPD: As I can see, there is a problem with counting newly generated coins.

uFire avatar Feb 03 '18 12:02 uFire