Skip to content

Commit 1e464ce

Browse files
Merge branch 'main' (Phase 7 headless errors) into ramps-ub2-immediate-order-details
Conflicts resolved in: - app/components/UI/Ramp/Views/Checkout/Checkout.tsx - app/components/UI/Ramp/Views/Checkout/Checkout.test.tsx - app/components/UI/Ramp/hooks/useTransakRouting.ts - app/components/UI/Ramp/hooks/useTransakRouting.test.ts Reconciled with main's Phase 7 (`feat(ramp): surface headless buy errors as data`): - `Checkout.tsx`: imports `failSession` and adds `failHeadlessCheckout` to forward callback exceptions and WebView HTTP errors to the headless consumer's `onError` callback instead of showing the in-app `ErrorView`. This branch's non-headless path (navigate immediately to `OrderDetails` with callback params) is preserved; the headless branch still fetches the order and fires `onOrderCreated` before pop. - `useTransakRouting.ts`: imports `failSession`, calls it in the headless catch path of `handleNavigationStateChange`, and reintroduces `navigateToOrderProcessingCallback` so the manual bank transfer approval flow can hand a successful headless order to `onOrderCreated` without showing the toast or routing to bank-details. `LimitExceededError` now carries `headlessBuyErrorCode: 'LIMIT_EXCEEDED'` and `details` so the Host can surface limit failures as data; the approved-flow catch rethrows it unchanged. - Tests cover: callback failure → `failSession` (no ErrorView), WebView HTTP error → `failSession`, `LimitExceededError` preservation, manual bank transfer headless success path. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2 parents 893a0b9 + dba2c63 commit 1e464ce

73 files changed

Lines changed: 2218 additions & 668 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.

.github/workflows/build.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,7 @@ jobs:
125125
uses: actions/setup-node@v4
126126
with:
127127
node-version-file: '.nvmrc'
128+
cache: 'yarn'
128129
- run: yarn install --immutable
129130
- run: node scripts/validate-build-config.js
130131

.github/workflows/run-performance-e2e.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ jobs:
142142
needs: [determine-branch-name]
143143
outputs:
144144
android_matrix: ${{ steps.read-matrix.outputs.android_matrix }}
145+
android_mm_connect_matrix: ${{ steps.read-matrix.outputs.android_mm_connect_matrix }}
145146
ios_matrix: ${{ steps.read-matrix.outputs.ios_matrix }}
146147
steps:
147148
- name: Checkout code
@@ -165,18 +166,23 @@ jobs:
165166
fi
166167
167168
ANDROID_MATRIX=$(jq ".android_devices | $FILTER" "$FILE")
169+
ANDROID_MM_CONNECT_MATRIX=$(jq '[.android_devices[] | select(.name | contains("Samsung"))]' "$FILE")
168170
IOS_MATRIX=$(jq ".ios_devices | $FILTER" "$FILE")
169171
170172
{
171173
echo "android_matrix<<EOF"
172174
echo "$ANDROID_MATRIX"
173175
echo "EOF"
176+
echo "android_mm_connect_matrix<<EOF"
177+
echo "$ANDROID_MM_CONNECT_MATRIX"
178+
echo "EOF"
174179
echo "ios_matrix<<EOF"
175180
echo "$IOS_MATRIX"
176181
echo "EOF"
177182
} >> "$GITHUB_OUTPUT"
178183
179184
echo "Selected: $(echo "$ANDROID_MATRIX" | jq length) Android, $(echo "$IOS_MATRIX" | jq length) iOS"
185+
echo "Selected for Android MM-Connect: $(echo "$ANDROID_MM_CONNECT_MATRIX" | jq length)"
180186
181187
set-build-names:
182188
name: Set Unified BrowserStack Build Names
@@ -333,7 +339,7 @@ jobs:
333339
name: Fetch RN Playground APK and Upload to BrowserStack
334340
runs-on: ubuntu-latest
335341
needs: [wait-for-onboarding-completion]
336-
if: always() && !cancelled()
342+
if: always() && !cancelled() && (inputs.build_variant || 'rc') == 'rc'
337343
outputs:
338344
browserstack-playground-url: ${{ steps.upload-playground.outputs.browserstack-url }}
339345
steps:
@@ -376,13 +382,13 @@ jobs:
376382
set-build-names,
377383
determine-branch-name,
378384
]
379-
if: always() && !cancelled() && (needs.trigger-android-dual-versions.result == 'skipped' || needs.trigger-android-dual-versions.result == 'success') && (inputs.browserstack_app_url_android_imported_wallet != '' || needs.trigger-android-dual-versions.outputs.with-srp-browserstack-url != '')
385+
if: always() && !cancelled() && (inputs.build_variant || 'rc') == 'rc' && (needs.trigger-android-dual-versions.result == 'skipped' || needs.trigger-android-dual-versions.result == 'success') && (inputs.browserstack_app_url_android_imported_wallet != '' || needs.trigger-android-dual-versions.outputs.with-srp-browserstack-url != '')
380386
with:
381387
platform: android
382388
build_type: mm-connect
383389
sentry_target: ${{ inputs.sentry_target || 'test' }}
384390
build_variant: ${{ inputs.build_variant || 'rc' }}
385-
device_matrix: ${{ needs.read-device-matrix.outputs.android_matrix }}
391+
device_matrix: ${{ needs.read-device-matrix.outputs.android_mm_connect_matrix }}
386392
browserstack_app_url: ${{ needs.trigger-android-dual-versions.outputs.with-srp-browserstack-url || inputs.browserstack_app_url_android_imported_wallet }}
387393
app_version: ${{ needs.trigger-android-dual-versions.outputs.with-srp-version || 'Manual-Input' }}
388394
branch_name: ${{ needs.determine-branch-name.outputs.branch_name }}

.github/workflows/update-e2e-fixtures.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ jobs:
255255
run: |
256256
IS_TEST='true' NODE_OPTIONS='--experimental-vm-modules' \
257257
yarn detox test -c ios.sim.main.ci --headless \
258-
tests/regression/fixtures/fixture-validation.spec.ts
258+
tests/smoke/fixtures/fixture-validation.spec.ts
259259
env:
260260
PREBUILT_IOS_APP_PATH: artifacts/main-qa-MetaMask.app
261261

0 commit comments

Comments
 (0)