Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
5d46686
fix: remove polling tokens if history is cleared
micaelae Apr 16, 2026
ccecf2d
feat: subscribe to transactionStatusUpdated
micaelae Apr 16, 2026
08ad5e3
fix: don't save initial stx hash in history
micaelae Apr 16, 2026
0e6c19f
chore: read max history age from LD
micaelae Apr 17, 2026
b30baf4
chore: return historyKey from addTxToHistory
micaelae Apr 20, 2026
40bc4e3
fix: skip duplicate tests
micaelae Apr 20, 2026
99fe580
statusUpdated
micaelae Apr 20, 2026
d0b1c24
status tests
micaelae Apr 20, 2026
1b68668
test: baseline unit tests
micaelae Apr 20, 2026
2d5a957
refactor: handleFetchFailure
micaelae Apr 20, 2026
84bc75d
fix: skip metrics for perps tx
micaelae Apr 20, 2026
28dd789
chore: throw an error if history item is too old
micaelae Apr 20, 2026
e2a7723
test: remove redundant unit tests
micaelae Apr 20, 2026
df71533
chore: handle non-evm history items
micaelae Apr 20, 2026
8e9c439
chore: update changelog
micaelae Apr 20, 2026
34336d2
chore: rm console logs
micaelae Apr 21, 2026
190f8c4
fix: track failure event once when approval fails
micaelae Apr 21, 2026
f66686e
chore: rename enum
micaelae Apr 21, 2026
67c47f7
fix: lint errors
micaelae Apr 21, 2026
0c337af
fix: lint errors
micaelae Apr 21, 2026
cef9ba0
fix: restore max_attempts behavior
micaelae Apr 21, 2026
86fb638
fix: fetch status at least once
micaelae Apr 21, 2026
7365e45
fix: cursor comment
micaelae Apr 21, 2026
0af4d26
Merge branch 'main' into swaps4380-invalid-src-hash
micaelae Apr 21, 2026
92fa59a
chore: cursor comments
micaelae Apr 21, 2026
a542a68
chore: address comments
micaelae Apr 22, 2026
63b36c5
Merge branch 'main' into swaps4380-invalid-src-hash
micaelae Apr 22, 2026
538d291
fix: lint
micaelae Apr 22, 2026
dbfbe65
fix: lint
micaelae Apr 22, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions packages/bridge-controller/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Add `AccountHardwareType` type and `getAccountHardwareType` function to the package exports ([#8503](https://github.com/MetaMask/core/pull/8503))
- `AccountHardwareType` is a union of `'Ledger' | 'Trezor' | 'QR Hardware' | 'Lattice' | null`
- `getAccountHardwareType` maps a keyring type string to the corresponding `AccountHardwareType` value
- Read 'maxPendingHistoryItemAgeMs' feature flag from LaunchDarkly, which indicates when a history item can be treated as a failure ([#8479](https://github.com/MetaMask/core/pull/8479))
- Add the `invalid_transaction_hash` polling reason to indicate that a history item was removed from state do to having an invalid hash ([#8479](https://github.com/MetaMask/core/pull/8479))

### Changed

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export enum UnifiedSwapBridgeEventName {

export enum PollingStatus {
MaxPollingReached = 'max_polling_reached',
InvalidTransactionHash = 'invalid_transaction_hash',
ManuallyRestarted = 'manually_restarted',
}

Expand Down
1 change: 1 addition & 0 deletions packages/bridge-controller/src/utils/validators.ts
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,7 @@ export const PlatformConfigSchema = type({
* Array of chain objects ordered by preference/ranking
*/
chainRanking: ChainRankingSchema,
maxPendingHistoryItemAgeMs: optional(number()),
});

export const validateFeatureFlagsResponse = (
Expand Down
10 changes: 10 additions & 0 deletions packages/bridge-status-controller/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Added

- Remove stale bridge transactions from `txHistory` to prevent excessive polling. Once a history item exceeds the configured maximum age, the status is fetched once, then the src tx hash's receipt is retrieved. If there is no receipt, the history item's hash is presumed to be invalid and the entry is deleted from state. ([#8479](https://github.com/MetaMask/core/pull/8479))
- Add missing action types for public `BridgeStatusController` methods ([#8367](https://github.com/MetaMask/core/pull/8367))
- The following types are now available:
- `BridgeStatusControllerSubmitTxAction`
Expand All @@ -17,6 +18,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Changed

- **BREAKING:** Replace `transactionFailed` and `transactionConfirmed` event subscriptions with `TransactionController:transactionStatusUpdated` ([#8479](https://github.com/MetaMask/core/pull/8479))
- **BREAKING:** Add `RemoteFeatureFlags:getState` to allowed actions to retrieve max history item age config ([#8479](https://github.com/MetaMask/core/pull/8479))
- Add `account_hardware_type` field to all cross-chain swap analytics events ([#8503](https://github.com/MetaMask/core/pull/8503))
- `account_hardware_type` carries the specific hardware wallet brand (e.g. `'Ledger'`, `'QR Hardware'`) or `null` for software wallets
- `is_hardware_wallet` is now derived from `account_hardware_type !== null`, keeping both fields in sync
Expand All @@ -28,6 +31,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Bump `@metamask/base-controller` from `^9.0.1` to `^9.1.0` ([#8457](https://github.com/MetaMask/core/pull/8457))
- Bump `@metamask/bridge-controller` from `^70.0.1` to `^70.1.1` ([#8466](https://github.com/MetaMask/core/pull/8466), [#8474](https://github.com/MetaMask/core/pull/8474))

### Fixed

- Prevent invalid src hashes from being persisted in `txHistory` ([#8479](https://github.com/MetaMask/core/pull/8479))
- Make transaction status subscribers generic so that `txHistory` items get updated if there are any transaction updates matching by actionId, txMetaId, hash or type
- Skip saving smart transaction hashes on transaction submission. This used to make it possible for invalid src hashes to be stored in state and polled indefinitely. Instead, the txHistory item will now be updated with the confirmed tx hash when the `transactionStatusUpdated` event is published
- If there is no srcTxHash in state, attempt to set it based on the local TransactionController state

## [70.0.5]

### Changed
Expand Down
Loading
Loading