tahowallet / extension

Taho, the community owned and operated Web3 wallet.
https://taho.xyz
GNU General Public License v3.0
3.12k stars 392 forks source link

Balances of some assets are shown as 10x smaller #3712

Open michalinacienciala opened 11 months ago

michalinacienciala commented 11 months ago

Taho extension sometimes (when asset's balance ends with 00?) shows wrong balances for assets.

I've imported bnbspider.crypto (0x208e94d5661a73360d9387d3ca169e5c130090cd) and did some tests of adding/removing tokens. I noticed that the balance of the LOOKSDROP hidden asset is wrong (we show 80 on the asset list, but when trying to import the asset, balance is shown as 800 (which is in line with Etherscan).

I first thought the balance may be displaying wrong for assets on the hidden assets list, but then I checked how it looks for other assets and now I think we may display wrong value when the balance ends with two zeros... Here is what balances look like on bnbspider.crypto:

Token                                      | Trusted | Taho Balance | Etherscan Balance
0xdac17f958d2ee523a2206206994597c13d831ec7 | Yes     | 1.52         | 1.526626
0x6c28aef8977c9b773996d0e8376d2ee379446f2f | Yes     | 0.02         | 0.02893628087622926
0x469eda64aed3a3ad6f868c44564291aa415cb1d9 | Yes     | 17.78        | 17.787563633168020154
0x99d8a9c45b2eca8864373a26d1459e3dff1e17f3 | Yes     | 0.59         | 0.597081746795495792
0xae7ab96520de3a18e5e111b5eaab095312d7fe84 | Yes     | 0.0001       | 0.000104402506970099
0xfa5047c9c78b8877af97bdcb85db743fd7313d4a | Yes     | 0.03         | 0.033768420189342274
0x0d3716e3e411af431a6e87e715d4b05bbcd67000 | No      | 400          | 4000
0xb0b1d4732efe32aea466ed6bc3c79181ed4810c4 | No      | 10254        | 10254
0x8965349fb649a33a30cbfda057d8ec2c48abe2a2 | No      | 2.2          | 2.2
0xac8102352085c492a0cafacb9afcb77d25a21ce4 | No      | 350          | 350
0x1883a07c429e84aca23b041c357e1d21a2b645f3 | No      | 80           | 800
0x0332d00ae8e9baa609edc48844f48fdd94ca9547 | No      | 600          | 6000
0xf511123fdf2f13811abf4eddb493860101471729 | No      | 920.81       | 920.8164
0x062032f5a8ffafbde4d513237071f450c270b764 | No      | 80           | 800
0x528d50dc9a333f01544177a924893fa1f5b9f748 | No      | 0.26         | 0.262405023822467935
0xda816459f1ab5631232fe5e97a05bbbb94970c95 | No      | 1.93         | 1.937416850870804822
0x6d765cbe5bc922694afe112c140b8878b9fb0390 | No      | 0.45         | 0.459175365610573315
codingfarhan commented 5 months ago

@michalinacienciala I couldn't replicate this issue on my end. Does this issue still exist?