deemru / w8io

Waves Platform blockchain explorer (w8.io)
https://w8.io
MIT License
15 stars 16 forks source link

Wrong balance #14

Closed WavescapTorben closed 3 years ago

WavescapTorben commented 3 years ago

After downloading new 1.3 branch (few days ago) and running w8_update.php I am getting a wrong balance for WETH on address 3PPdeWwrzaxqgr6BuReoF3sWfxW8SYv743D It says -0.00199978 WETH but it should be 0.00000022 WETH like w8io.ru shows here: https://w8io.ru/3PPdeWwrzaxqgr6BuReoF3sWfxW8SYv743D

I am seeing all the new dapp-to-dapp transactions on my installation, too, but there is one transaction (or dapp result) that is wrong on my side, I attached it as image: Screenshot from 2021-07-11 21-34-07 Instead of invoke +0.00000000 Waves it should be +0.00200000 WETH like w8io.ru shows.

Does somebody else have this problem or have an idea what is wrong on my side?

deemru commented 3 years ago

Did you update to 1.3 and rebuild your database with w8_update from scratch?

If not, it must be done.

WavescapTorben commented 3 years ago

Yes I did everything from scratch and even tried a second time with same result. I will try on other machine with other node now..

WavescapTorben commented 3 years ago

Now I tried a third time everything from scratch with same wrong result. But I noticed a difference between my node API and the API of w8io.ru, maybe that could be the problem?

My node API: https://node.wscan.io/transactions/info/ECseEjTzQdiWfxyxP5PQa1g5MqTjZYrkhX2PmJtQStwK w8io.ru API: https://w8io.ru/tx/ECseEjTzQdiWfxyxP5PQa1g5MqTjZYrkhX2PmJtQStwK

$tx['stateChanges']['invokes'][0]['payment'] is an attribute name at my node, but at w8io.ru its in plural form: $tx['stateChanges']['invokes'][0]['payments']

deemru commented 3 years ago

payments is the correct one: https://github.com/deemru/w8io/blob/aa48335b41d1e455ab114e2cad2f77ae24e74e76/include/BlockchainParser.php#L980

You have to update your node it seems and it is always better to use the latest version.

WavescapTorben commented 3 years ago

That is strange, I am sure I used latest node mainnet release (1.3.6) and the official API shows same as mine: https://nodes.wavesnodes.com/transactions/info/ECseEjTzQdiWfxyxP5PQa1g5MqTjZYrkhX2PmJtQStwK

deemru commented 3 years ago

That is strange, I am sure I used latest node mainnet release (1.3.6) and the official API shows same as mine: https://nodes.wavesnodes.com/transactions/info/ECseEjTzQdiWfxyxP5PQa1g5MqTjZYrkhX2PmJtQStwK

Thanks for this notice, actually i use 1.3.5 version on my node, so 1.3.6 looks unsupported, i will fix that.

WavescapTorben commented 3 years ago

All clear thanks!

deemru commented 3 years ago

Seems fixed.

Check updated readme: https://github.com/deemru/w8io/blob/1.3/README.md

Then you need to rollback php w8_updater.php rollback 2651414 and then update as usual.

WavescapTorben commented 3 years ago

Yes its fixed.