-
Notifications
You must be signed in to change notification settings - Fork 19
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
feat(frontend): different warning for non-working index canister #3758
Merged
AntonioVentilii
merged 9 commits into
main
from
feat(frontend)/different-feedback-for-non-working-index-canister
Nov 27, 2024
Merged
feat(frontend): different warning for non-working index canister #3758
AntonioVentilii
merged 9 commits into
main
from
feat(frontend)/different-feedback-for-non-working-index-canister
Nov 27, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…rking-index-canister
AntonioVentilii
added a commit
that referenced
this pull request
Nov 26, 2024
# Motivation It may happen that an ICRC token has an Index Canister but it is not working. For example, it is out of cycles. In those cases, we don't want to show an error anymore, but leverage the same wallet service used for tokens without Index Canister. That means, that in those cases, we will just fetch the balance, and show an explanatory warning for not having the transacitons. # Changes - Change function `onLoadTransactionsError` to accept a fallback function. - If the error is raised during the ICRC transaction fetching, the fallback restarts the worker, but providing only the lLedger Canister, and not the Index Canister. This will allow the service to treat it in the same way of a token without index canister (i.e. fetching balance only). # Note The changes in the UI will be done with: - PR #3758 # Tests I simulated a wrong index canister in the local replica for ckSepoliaUSDC. In the video we can see how I switch between the correct Index canister and the wrong one, back and forth. https://github.com/user-attachments/assets/f007e592-bd26-4dcb-88b4-b6cbb7b19d33
…rking-index-canister
src/frontend/src/icp/components/transactions/IcNoIndexPlaceholder.svelte
Outdated
Show resolved
Hide resolved
src/frontend/src/icp/components/transactions/IcNoIndexPlaceholder.svelte
Outdated
Show resolved
Hide resolved
src/frontend/src/icp/components/transactions/IcTransactions.svelte
Outdated
Show resolved
Hide resolved
peterpeterparker
approved these changes
Nov 27, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thx
AntonioVentilii
deleted the
feat(frontend)/different-feedback-for-non-working-index-canister
branch
November 27, 2024 13:02
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
For ICRC tokens that have the index canister but it is not working, we want to show a different message.
Changes
IcNoIndexPlaceHolder
to accept a prop that defines if the index is eithermissing
ornot-working
.IcTransactions
component.Tests
I simulated
ckSepoliaUSDC
with a wrong index canister,