fix(bridge): make tx history resilient to per-tx failures#310
Open
dewanshparashar wants to merge 7 commits into
Open
fix(bridge): make tx history resilient to per-tx failures#310dewanshparashar wants to merge 7 commits into
dewanshparashar wants to merge 7 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Pull request overview
Improves transaction history robustness by preventing a single transaction transformation failure from blocking the entire history load, and surfaces per-transaction failures via the existing warning tooltip UI.
Changes:
- Track per-transaction transform failures in
useTransactionHistoryusingPromise.allSettled()and a newfailedTxsfield. - Persist and expose
failedTxsvia SWR cache keyed by address. - Extend the Transaction History warning tooltip to display both failed chain pairs and failed transactions.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| packages/arb-token-bridge-ui/src/hooks/useTransactionHistory.ts | Switches page transformation to Promise.allSettled(), records failed tx metadata, and exposes failedTxs in the hook result. |
| packages/arb-token-bridge-ui/src/components/TransactionHistory/TransactionHistoryTable.tsx | Updates the warning tooltip to show failed txs alongside failed chain pairs, and wires in the new failedTxs prop. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+736
to
+740
| return merged; | ||
| }, false); | ||
| } | ||
|
|
||
| return Promise.all(dedupedTransactions.slice(startIndex, endIndex).map(transformTransaction)); | ||
| return succeeded; |
…/OffchainLabs/arbitrum-portal into fix/bridge-tx-history-resilience
This file contains hidden or 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
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.
If processing a transaction fails, the whole tx history should not fail to load. Instead, it's error should be communicated subtly to the user - while keeping the rest of the tx history unblocked.
Core change - use
Promise.allSettled()instead ofPromise.all(), and keeping track of the failed txns to show in the existing failure tooltip.Before
After
Closes FS-2156