Skip to content

Commit fe5188d

Browse files
authored
Merge branch 'main' into namespace-runner-trial
2 parents 36ffd4d + 9432aa0 commit fe5188d

337 files changed

Lines changed: 22572 additions & 8596 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.eslintrc.js

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -385,6 +385,33 @@ module.exports = {
385385
],
386386
},
387387
},
388+
{
389+
files: ['**/*.test.{js,ts,tsx,jsx}', '**/*.spec.{js,ts,tsx,jsx}'],
390+
plugins: ['jest'],
391+
rules: {
392+
// Prevent new file-based snapshots. Inline snapshots (toMatchInlineSnapshot)
393+
// are still allowed as they keep assertions co-located with the test.
394+
'jest/no-restricted-matchers': [
395+
'error',
396+
{
397+
toMatchSnapshot:
398+
'Use toMatchInlineSnapshot() or an explicit assertion instead. File-based snapshots are being phased out.',
399+
},
400+
],
401+
},
402+
},
403+
{
404+
// Matches CODEOWNERS `**/snaps/**` and `**/Snaps/**` (@MetaMask/core-platform).
405+
// ESLint cannot read CODEOWNERS.
406+
files: [
407+
'**/snaps/**/*.{test,spec}.{js,ts,tsx,jsx}',
408+
'**/Snaps/**/*.{test,spec}.{js,ts,tsx,jsx}',
409+
],
410+
plugins: ['jest'],
411+
rules: {
412+
'jest/no-restricted-matchers': 'off',
413+
},
414+
},
388415
// ── Perps controller Core-alignment override ──
389416
// Enforces the same ESLint rules that Core's @metamask/eslint-config
390417
// applies to packages/perps-controller so that code written in mobile
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
diff --git a/dist/bridge-status-controller.cjs b/dist/bridge-status-controller.cjs
2+
index c8dcd1f18fd4395b13ac7945e533ae1a92553950..ced9b35dc96c65ffe7ac59d198f4ab2737ae24ac 100644
3+
--- a/dist/bridge-status-controller.cjs
4+
+++ b/dist/bridge-status-controller.cjs
5+
@@ -863,16 +863,27 @@ class BridgeStatusController extends (0, polling_controller_1.StaticIntervalPoll
6+
};
7+
// Record in bridge history with actual transaction metadata
8+
try {
9+
- // Create a bridge transaction metadata that includes the original txId
10+
+ /**
11+
+ * Patch to fix ondo swap activity tab status issue logged at
12+
+ * https://consensyssoftware.atlassian.net/browse/BETR-413
13+
+ *
14+
+ */
15+
+ // Create a bridge transaction metadata keyed by orderUid for intent polling
16+
const bridgeTxMetaForHistory = {
17+
...syntheticMeta,
18+
id: orderUid,
19+
- originalTransactionId: syntheticMeta.id, // Keep original txId for TransactionController updates
20+
};
21+
// Use orderId as the history key for intent transactions
22+
+ // IMPORTANT: pass originalTransactionId as a top-level argument so
23+
+ // `getInitialHistoryItem` reads it. Setting it on `bridgeTxMeta` is a no-op
24+
+ // because `getInitialHistoryItem` destructures `originalTransactionId` from
25+
+ // the top-level args, not from `bridgeTxMeta`. Without this, the field
26+
+ // falls back to `bridgeTxMeta.id` (the orderUid), severing the link between
27+
+ // the bridge history record and the synthetic TransactionController entry.
28+
const historyKey = __classPrivateFieldGet(this, _BridgeStatusController_addTxToHistory, "f").call(this, {
29+
accountAddress,
30+
bridgeTxMeta: bridgeTxMetaForHistory,
31+
+ originalTransactionId: syntheticMeta.id, // Keep original txId for TransactionController updates
32+
quoteResponse,
33+
slippagePercentage: 0,
34+
isStxEnabled: false,
35+
diff --git a/dist/bridge-status-controller.mjs b/dist/bridge-status-controller.mjs
36+
index 3c285a68a35e69b6898f5c811a000324044213c8..9e0b4ef973b167c39e142b60ca28cf32ea89f41a 100644
37+
--- a/dist/bridge-status-controller.mjs
38+
+++ b/dist/bridge-status-controller.mjs
39+
@@ -860,16 +860,27 @@ export class BridgeStatusController extends StaticIntervalPollingController() {
40+
};
41+
// Record in bridge history with actual transaction metadata
42+
try {
43+
- // Create a bridge transaction metadata that includes the original txId
44+
+ /**
45+
+ * Patch to fix ondo swap activity tab status issue logged at
46+
+ * https://consensyssoftware.atlassian.net/browse/BETR-413
47+
+ *
48+
+ */
49+
+ // Create a bridge transaction metadata keyed by orderUid for intent polling
50+
const bridgeTxMetaForHistory = {
51+
...syntheticMeta,
52+
id: orderUid,
53+
- originalTransactionId: syntheticMeta.id, // Keep original txId for TransactionController updates
54+
};
55+
// Use orderId as the history key for intent transactions
56+
+ // IMPORTANT: pass originalTransactionId as a top-level argument so
57+
+ // `getInitialHistoryItem` reads it. Setting it on `bridgeTxMeta` is a no-op
58+
+ // because `getInitialHistoryItem` destructures `originalTransactionId` from
59+
+ // the top-level args, not from `bridgeTxMeta`. Without this, the field
60+
+ // falls back to `bridgeTxMeta.id` (the orderUid), severing the link between
61+
+ // the bridge history record and the synthetic TransactionController entry.
62+
const historyKey = __classPrivateFieldGet(this, _BridgeStatusController_addTxToHistory, "f").call(this, {
63+
accountAddress,
64+
bridgeTxMeta: bridgeTxMetaForHistory,
65+
+ originalTransactionId: syntheticMeta.id, // Keep original txId for TransactionController updates
66+
quoteResponse,
67+
slippagePercentage: 0,
68+
isStxEnabled: false,

0 commit comments

Comments
 (0)