Skip to content

chore: back-merge main → dev (2026-07-02 hotfix wave)#2339

Merged
Hugo0 merged 23 commits into
devfrom
chore/backmerge-main-2026-07-02
Jul 2, 2026
Merged

chore: back-merge main → dev (2026-07-02 hotfix wave)#2339
Hugo0 merged 23 commits into
devfrom
chore/backmerge-main-2026-07-02

Conversation

@Hugo0

@Hugo0 Hugo0 commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Summary

Brings today's ~16 main hotfix commits back into dev so the dev→main release is conflict-free: card findActiveCard + un-trappable setup modal (#2334 + follow-ups), Manteca BRL PIX QR deposit screens + settling-stage fix, landing supported-rails FAQ, badge art tweak.

Merge was textually clean. Typecheck + 1665 tests green on the merged tree.

Risks

None beyond the constituent PRs — pure sync, no new code.

QA

Local gate on the merge commit: typecheck ✅, jest 1665 ✅ (108 suites).

Hugo0 and others added 23 commits July 1, 2026 19:38
…ll-crash

🚑 hotfix(add-money): stop prod page crash when FX rate fails (PEANUT-UI-PS7)
Frontend for the offramp.xyz -> Peanut migration badge (backend in
peanut-api-ts). Adds the BADGES entry + art and the /invite campaign
resolution: invite-code `offramp`, utm_campaign `offramp`, and
bare ?campaign=OFFRAMP_USER (vanity claim, no waitlist skip). Mirrors
TOUCHED_GRASS.
Swap the badge asset to the b12-teary design — the Offramp coin with
teary kawaii eyes (bittersweet farewell as offramp.xyz shuts down),
bolt intact + little feet. Same path/filename, no code change.
feat(badges): wire Offramp User badge (art + campaign maps)
…ppable setup modal

2026-07-02 dup-card incident: the setup modal read cards[0] (newest) while
the backend stored the session-key grant on a different card — every tap
'succeeded', the modal never dismissed, and the error-gated Skip never
rendered. All card flows now use the existing findActiveCard helper, and a
grant that succeeds without flipping hasWithdrawApproval reveals the escape
hatch and pages Sentry (console.warn + captureMessage).
…bit) — a re-issued card must not inherit an old card's grant success
Companion to peanut-api-ts #1093. For BRL, Add Money now shows Manteca's dynamic
PIX QR instead of the static bank-details screen: render the copia-e-cola via
QRCodeWrapper, a copy button, a live m:ss expiry countdown, and poll the deposit
intent status to auto-advance to a success state. ARS path untouched.

- showQR step (nuqs) routed by the response discriminator (type === 'QR')
- useMantecaDepositPolling: read-only mirror of GET /manteca/deposit/:id/status
- QRCodeWrapper gains an optional className width-override (160 -> 280px here)
- hook + component tests
…'s details

Drops MantecaPixDepositData; the dynamic QR now reads from the existing
MantecaDepositResponseData.details.qr (the ramp-on synthetic), routed to showQR
by currency. Matches the BE pivot (api #1093) off deposit-request. details.qr is
a stub until Manteca confirms the field name.
…g screen

Two PIX-deposit polish items:
- Add money → Brazil now defaults the input denomination to BRL (Argentina → ARS)
  instead of USD — you deposit in your local currency.
- Show the branded CyclingLoading screen (spinning peanut + rotating messages,
  same as PIX-payment processing) while the BRL QR is being generated, and in
  place of the plain "Preparing your PIX QR…" fallback.
…lement screen

- Add money → Brazil defaults the denomination to BRL (PIX is in BRL); every
  other country keeps USD (Argentina reverts to USD).
- useMantecaDepositPolling now surfaces a 'processing' status for the
  payment-settling window (Manteca PROCESSING / AWAITING_SETTLEMENT); the QR
  screen shows the branded CyclingLoading during it, so the flow is
  QR → processing → "Deposit received!".
…ire the maintenance warn

Manteca shipped the dynamic BRL QR to prod today. Probe (mono
ops/scripts/manteca/probe-brl-rampon-qr.ts) pinned the real shape: the
EMVCo copia-e-cola rides in details.depositAddresses.PIX.{code,url,
expiresAt,bankId}; the old static depositAddress/depositAlias are gone
for BRL (now optional in the type — the ARS share-details screen keeps a
'' fallback but BRL never routes there).

With the QR flow live the warn-only maintenance surface comes off:
pixBrazilOnrampMaintenance flips false (machinery stays for future
outages), the unused banner copy is trimmed to the badge, and the
maintenance test now snapshots/restores the shipped flag instead of
hardcoding true — flipping the committed default no longer poisons the
config singleton for later tests.
- overviewFresh: a grant whose overview refetch failed is STALE, not stuck —
  don't false-page Sentry on flaky connections (grant() now reports it)
- per-card Skip dismissal: skipping stuck card A must not suppress card B's
  legitimate prompt in the same session
- stuck state now explains itself (error copy + Try again CTA) instead of
  happy-path text with an unexplained Skip
- Sentry warn dedupe uses a Set — alternating active cards (A→B→A) no longer
  re-page for an already-warned card
…-review findings 4+5)

A hard failure on card A no longer leaks 'Try again' copy and the skip
escape into a re-issued card B's first prompt — same stale-signal class
as the grantSucceededFor fix, applied to the hook's un-scoped error.
feat(manteca): BRL PIX deposit QR screen (details.depositAddresses.PIX)
…ection

fix(card): key card flows off findActiveCard, never cards[0] + un-trappable setup modal
…t PROCESSING

Manteca flips a ramp-on to ACTIVE (→ intent PROCESSING) seconds after
creation, while the user hasn't paid. The polling hook read PROCESSING as
'payment detected' and swapped the QR for a permanent CyclingLoading —
the reported 'QR shows, then loads again, and it's lost'. The BE status
endpoint now returns the synthetic stage (api#1112); the settling screen
only shows once stage >= 2 (fiat actually received). Absent/null stage
(older BE, legacy row) degrades to keeping the QR visible.
fix(manteca): PIX QR no longer vanishes — settling gates on stage, not PROCESSING
Users comparing cards can't find which chains/stables we support without
signing up (X thread 2026-07-02 — reviewers literally said they look for
this in the FAQ and bounce when it's missing). Renders the answer from the
same rhino.consts the add-money Choose Network drawer uses, so the public
claim can never drift from what the app actually accepts; plain-text
answer feeds the FAQPage JSON-LD for SEO.
Fiat rails now live once in FIAT_RAILS (chips + JSON-LD prose both derive
from it), Solana/Tron chips derive from OTHER_SUPPORTED_CHAINS, token chips
reuse getSupportedTokens' logoUrl, chainDisplayName moves to a utils file
per export rules, withSupportedRails wraps in one place, and the FAQ array
is memoized (LandingPageClient re-renders per scroll frame).
feat: advertise supported networks, tokens and bank rails in landing FAQ
@vercel

vercel Bot commented Jul 2, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
peanut-wallet Ready Ready Preview, Comment Jul 2, 2026 11:55pm

Request Review

@coderabbitai

coderabbitai Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 17 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: d9a70650-c7be-44f6-88d7-b4b4e1877d25

📥 Commits

Reviewing files that changed from the base of the PR and between cac1e93 and 8e5f036.

⛔ Files ignored due to path filters (1)
  • public/badges/offramp_user.png is excluded by !**/*.png
📒 Files selected for processing (25)
  • src/app/(mobile-ui)/dev/card-session-approve/page.tsx
  • src/components/AddMoney/components/MantecaAddMoney.tsx
  • src/components/AddMoney/components/MantecaDepositShareDetails.tsx
  • src/components/AddMoney/components/MantecaPixQrDeposit.tsx
  • src/components/AddMoney/components/__tests__/MantecaPixQrDeposit.test.tsx
  • src/components/AddMoney/hooks/__tests__/useMantecaDepositPolling.test.tsx
  • src/components/AddMoney/hooks/useMantecaDepositPolling.ts
  • src/components/AddWithdraw/__tests__/AddWithdrawCountriesList.test.tsx
  • src/components/Badges/badge.utils.ts
  • src/components/Global/FAQs/index.tsx
  • src/components/Global/QRCodeWrapper/index.tsx
  • src/components/Home/EnableAutoBalanceBanner.tsx
  • src/components/Home/__tests__/EnableAutoBalanceBanner.test.tsx
  • src/components/Invites/campaign-maps.ts
  • src/components/LandingPage/LandingPageClient.tsx
  • src/components/LandingPage/SupportedRailsFaqAnswer.tsx
  • src/config/underMaintenance.config.ts
  • src/constants/faq.consts.ts
  • src/hooks/wallet/useGrantSessionKey.ts
  • src/hooks/wallet/useSignSpendBundle.ts
  • src/hooks/wallet/useSpendBundle.ts
  • src/lib/landingContent.ts
  • src/services/manteca.ts
  • src/types/manteca.types.ts
  • src/utils/chain-display.utils.ts

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Code-analysis diff

Painscore total: 5858.95 → 5857.65 (-1.3)
Findings: +10 net (+68 new, -58 resolved)

🆕 New findings (68)

  • critical complexity — src/components/AddMoney/components/MantecaAddMoney.tsx — CC 58, MI 56.81, SLOC 212
  • high complexity — src/services/manteca.ts — CC 48, MI 56.59, SLOC 216
  • high complexity — src/components/LandingPage/LandingPageClient.tsx — CC 39, MI 55.86, SLOC 145
  • high hotspot — src/components/AddMoney/components/MantecaAddMoney.tsx — 35 commits, +315/-204 lines since 6 months ago
  • high hotspot — src/components/Badges/badge.utils.ts — 34 commits, +332/-108 lines since 6 months ago
  • high complexity — src/components/Home/EnableAutoBalanceBanner.tsx — CC 30, MI 61.21, SLOC 61
  • high complexity — src/hooks/wallet/useSignSpendBundle.ts — CC 13, MI 38.73, SLOC 180
  • high complexity — src/components/Badges/badge.utils.ts — CC 10, MI 46.55, SLOC 153
  • medium high-mdd — src/components/AddMoney/components/MantecaAddMoney.tsx:37 — MantecaAddMoney: MDD 126.2 (uses across many lines from declarations)
  • medium high-mdd — src/hooks/wallet/useSpendBundle.ts:155 — useSpendBundle: MDD 69.6 (uses across many lines from declarations)
  • medium high-mdd — src/hooks/wallet/useSpendBundle.ts:170 — : MDD 60.6 (uses across many lines from declarations)
  • medium high-mdd — src/hooks/wallet/useSignSpendBundle.ts:102 — useSignSpendBundle: MDD 55.4 (uses across many lines from declarations)
  • medium high-mdd — src/hooks/wallet/useSignSpendBundle.ts:110 — : MDD 51.5 (uses across many lines from declarations)
  • medium high-mdd — src/components/LandingPage/LandingPageClient.tsx:44 — LandingPageClient: MDD 41.4 (uses across many lines from declarations)
  • medium high-mdd — src/hooks/wallet/useGrantSessionKey.ts:84 — useGrantSessionKey: MDD 33.3 (uses across many lines from declarations)
  • medium high-dlt — src/hooks/wallet/useGrantSessionKey.ts:84 — useGrantSessionKey: DLT 31 (calls 31 distinct functions — high context load)
  • medium high-dlt — src/hooks/wallet/useSpendBundle.ts:155 — useSpendBundle: DLT 30 (calls 30 distinct functions — high context load)
  • medium structural-dup — app/(mobile-ui)/withdraw/manteca/page.tsx:631 — 29 duplicate lines / 132 tokens with components/AddMoney/components/MantecaAddMoney.tsx:265
  • medium structural-dup — services/manteca.ts:151 — 29 duplicate lines / 56 tokens with services/manteca.ts:415
  • medium high-mdd — src/components/AddMoney/components/MantecaDepositShareDetails.tsx:22 — MantecaDepositShareDetails: MDD 29.1 (uses across many lines from declarations)

…and 48 more.

✅ Resolved (58)

  • src/components/AddMoney/components/MantecaAddMoney.tsx — CC 50, MI 56.79, SLOC 191
  • src/services/manteca.ts — CC 44, MI 56.94, SLOC 201
  • src/components/LandingPage/LandingPageClient.tsx — CC 36, MI 54.54, SLOC 137
  • src/components/Badges/badge.utils.ts — 33 commits, +328/-108 lines since 6 months ago
  • src/components/AddMoney/components/MantecaAddMoney.tsx — 31 commits, +255/-167 lines since 6 months ago
  • src/hooks/wallet/useSignSpendBundle.ts — CC 13, MI 38.79, SLOC 179
  • src/components/Badges/badge.utils.ts — CC 10, MI 46.78, SLOC 150
  • src/components/AddMoney/components/MantecaAddMoney.tsx:37 — MantecaAddMoney: MDD 112.1 (uses across many lines from declarations)
  • src/hooks/wallet/useSpendBundle.ts:154 — useSpendBundle: MDD 69.6 (uses across many lines from declarations)
  • src/hooks/wallet/useSpendBundle.ts:169 — : MDD 60.6 (uses across many lines from declarations)
  • src/hooks/wallet/useSignSpendBundle.ts:101 — useSignSpendBundle: MDD 55.4 (uses across many lines from declarations)
  • src/hooks/wallet/useSignSpendBundle.ts:109 — : MDD 51.5 (uses across many lines from declarations)
  • src/components/LandingPage/LandingPageClient.tsx:42 — LandingPageClient: MDD 39.7 (uses across many lines from declarations)
  • src/hooks/wallet/useGrantSessionKey.ts:79 — useGrantSessionKey: MDD 33.1 (uses across many lines from declarations)
  • src/hooks/wallet/useGrantSessionKey.ts:79 — useGrantSessionKey: DLT 30 (calls 30 distinct functions — high context load)
  • app/(mobile-ui)/withdraw/manteca/page.tsx:631 — 29 duplicate lines / 132 tokens with components/AddMoney/components/MantecaAddMoney.tsx:246
  • services/manteca.ts:151 — 29 duplicate lines / 56 tokens with services/manteca.ts:399
  • src/components/AddMoney/components/MantecaDepositShareDetails.tsx:22 — MantecaDepositShareDetails: MDD 28.9 (uses across many lines from declarations)
  • src/config/underMaintenance.config.ts — 26 commits, +102/-38 lines since 6 months ago
  • hooks/wallet/useSignSpendBundle.ts:274 — 22 duplicate lines / 98 tokens with hooks/wallet/useSpendBundle.ts:356

…and 38 more.

📈 Painscore deltas (top movers)

File Before After Δ
src/components/AddMoney/components/MantecaPixQrDeposit.tsx 0.0 6.5 +6.5
src/components/AddMoney/hooks/useMantecaDepositPolling.ts 0.0 5.6 +5.6
src/constants/faq.consts.ts 0.0 5.2 +5.2
src/components/LandingPage/SupportedRailsFaqAnswer.tsx 0.0 4.2 +4.2
src/utils/chain-display.utils.ts 0.0 3.8 +3.8
src/components/Home/EnableAutoBalanceBanner.tsx 5.6 7.9 +2.3
src/services/manteca.ts 9.6 10.1 +0.5

@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

🧪 UI test report — ✅ all green

Suites

  • unit: 1668 ran, 0 failed, 0 skipped, 25.6s

📊 Coverage (unit)

metric %
statements 55.0%
branches 37.9%
functions 42.9%
lines 54.9%
⏱ 10 slowest test cases
time test
4.4s src/components/Card/share-asset/__tests__/shareAssetLayout.test.ts › never places two stickers in heavy overlap (broad seed sweep)
0.5s src/components/Card/share-asset/__tests__/shareAssetLayout.test.ts › every sticker stays within canvas at any count
0.3s src/app/actions/__tests__/api-headers-extended.test.ts › should not include apiKey in updateUserById body
0.3s src/app/actions/__tests__/api-headers.test.ts › should include Content-Type in updateUserById
0.1s src/components/Global/GeneralRecipientInput/__tests__/GeneralRecipientInput.test.tsx › should handle too long for US account
0.1s src/components/Global/GeneralRecipientInput/__tests__/GeneralRecipientInput.test.tsx › should handle valid 9-digit US account
0.1s src/components/Global/GeneralRecipientInput/__tests__/GeneralRecipientInput.test.tsx › should handle valid ENS name
0.1s src/components/Global/GeneralRecipientInput/__tests__/GeneralRecipientInput.test.tsx › should handle valid US account with spaces 2
0.1s src/app/(mobile-ui)/qr-pay/__tests__/qr-pay-states.test.tsx › Perk claimed shows shake class + go home button
0.1s src/components/Global/GeneralRecipientInput/__tests__/GeneralRecipientInput.test.tsx › should handle valid ETH address with surrounding spaces
📍 Inline annotations are in the **Unit test report** check above. Coverage artifact: `coverage-unit`. Generated by `.github/workflows/tests.yml`.

@Hugo0 Hugo0 merged commit b655479 into dev Jul 2, 2026
16 of 19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants