Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: add balances at exchange history page #75

Open
rory4ever opened this issue Apr 13, 2020 · 2 comments
Open

Request: add balances at exchange history page #75

rory4ever opened this issue Apr 13, 2020 · 2 comments

Comments

@rory4ever
Copy link

The Exchange History page is working great and fast as well, kudos to that :)
However, for option " funds" it only shows me all incoming and outgoing funds
and deposits/withdrawals. Although this is great I really miss the possibility to show all historical balances as well (for both the wallet as on the smartcontract)
I was wondering if this can be added in the future, it is also a much needed option for tax purposes. Thanks in advance.

@DeltaBalances
Copy link
Owner

This is a good idea for a future addition, but requires a little too much work for now.
You can't simply query Ethereum for a balance at a past date, you need to calculate it using other available info.

For you wallet balance for example, you get the current wallet balance and then walk back through all transactions (transfers) that happend since that date. This should sum up to the right total, but some tokens use minting/burning/wrapping features that might not show up as a transfer.
To also get deposited balances you would need to do a second pass, but check all deposit/withdraw/trade events on the exchange.

With the current setup this would be incredibly slow, to make it of any use it would probably require and additional database on a server somewhere. Again, a good idea to speed this site up, but requires quite a bit of extra work.

Luckily etherscan has already done some of this work for you, just not for deposited balances. They are just a little hard to find on their homepage.

Etherscan historical wallet balances:

Note that etherscan's trackers will often report a bad balance for WETH after you unwrap it, and will only correct your balance once you get some new WETH.
(a good example of the little issues with checking old token balances)

@rory4ever
Copy link
Author

Thanks for your reply. The main purpose for me is the deposited balances (on the etherdelta2 smartcontract) so the Etherscan solution is of little use to me.

I understand that this is a bridge too far for now, hopefully somewhere in he future, you have my full support ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants