-
Notifications
You must be signed in to change notification settings - Fork 56
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
When opening an existing Liana wallet, advice users that wallet is syncing #1373
Comments
One approach could be for the For Liana Connect, we could leave this timestamp empty for now as a wallet using Liana Connect as a backend will remain synced even when the GUI is closed. As such, we would need to make sure the check of this timestamp is only done for a local backend. For a local backend, I think this check on first poll completing could be done instead of the check on wallet height becoming positive in #1370 in order to cover opening both new and existing wallets, but for a Liana Connect backend, we would still need to check the height. |
If we go with something like this we are relying on the fact that the poll is 100% successful. Is there any possible instance in which the first poll completes but the wallet doesn't get updated for some reason? This would get the user in an even worse state than what he has now - i.e. syncing "done" but still a wrong balance shown. |
We can be sure that if the poller completes, the wallet will have been synced to the extent that we're able to, ignoring some unlikely edge cases that would be logged as errors, and its height as stored in the DB will match the blockchain. So I think the first poll completing is a reliable indicator that the wallet has been synced. |
This is part of the "Wallet syncing / scanning state at wallet opening" activity included in v8.
The requirement would be to have the same syncing interaction that was developed for a new wallet (#1370) to when a user opens a wallet already present in his Liana until the first poll runs. This would mean for the user to have a syncing state for a maximum of
30 sec (poller frequency) + poll execution time
every time he opens the wallet. In that time, the user would see the last known amount blinking and a text indicating that the syncing has not yet been completed.If we are worried that this could be detrimental for users that open the wallet frequently, we could potentially evaluate to have this behavior only if the wallet has not been open for a while (>
arbitrary threshold
). I personally think it's more consistent to keep it for every opening.One way that was thought to achieve this requirement was to get the blockchain height and compare it to the wallet height, but since the mismatch between this two values occurs also in different moments than the wallet opening, this would mean repeating the syncing behavior every time we detect the block height to raise until the next poll, which is not ideal imho (see: #1362 (comment)). We decided to explore different ways of approaching it and see what could be best.
The text was updated successfully, but these errors were encountered: