feat(grid-wallet-prod): payouts reach every corridor; only funding is rail-limited - #744
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. 2 Skipped Deployments
|
Greptile SummaryThis PR separates inbound funding corridors from outbound payout corridors.
Confidence Score: 3/5The PR should not merge until Add Money uses explicit funding-corridor eligibility rather than the broader account schema type. The new filter admits non-euro-area EUR_ACCOUNT countries into a flow whose changed copy and stated contract restrict incoming bank funding to the US and euro area. Files Needing Attention: components/grid-wallet-prod/src/apps/shared/wallet/useMoneySheet.ts and components/grid-wallet-prod/src/data/bankCountries.ts
|
| Filename | Overview |
|---|---|
| components/grid-wallet-prod/src/apps/shared/wallet/useMoneySheet.ts | Introduces mode-specific pools and ranks, but the funding filter conflates EUR account schemas with euro-area eligibility. |
| components/grid-wallet-prod/src/data/bankCountries.ts | Restores the broader corridor catalog and separate ranking metadata; its non-euro EUR_ACCOUNT entries expose the funding-filter mismatch. |
| components/grid-wallet-prod/src/apps/aurora/wallet/AddMoneySheet.tsx | Updates direction-specific bank and empty-state copy, though the euro-area funding claim does not match the resulting picker. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
M{Money-sheet mode} -->|Add Money| F[Filter by FUNDING_ACCOUNT_TYPES]
M -->|Withdraw / Send / Receive| A[Use all BANK_COUNTRIES]
F --> FP[Funding-ranked country picker]
A --> PP[Payout-ranked country picker]
FP --> D[Funding details / bank form]
PP --> B[Bank form or receive details]
Prompt To Fix All With AI
### Issue 1
components/grid-wallet-prod/src/apps/shared/wallet/useMoneySheet.ts:190-193
**Funding filter conflates account eligibility**
When Add Money is opened, filtering by `accountType` admits non-euro-area `EUR_ACCOUNT` countries such as Denmark, Norway, Sweden, and Switzerland, allowing users to proceed with countries outside the funding corridor advertised by this flow.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.Reviews (1): Last reviewed commit: "feat(grid-wallet-prod): payouts reach ev..." | Re-trigger Greptile
| const funding = mode === 'add'; | ||
| const countryPool = funding | ||
| ? BANK_COUNTRIES.filter((c) => FUNDING_ACCOUNT_TYPES.includes(c.accountType)) | ||
| : BANK_COUNTRIES; |
There was a problem hiding this comment.
Funding filter conflates account eligibility
When Add Money is opened, filtering by accountType admits non-euro-area EUR_ACCOUNT countries such as Denmark, Norway, Sweden, and Switzerland, allowing users to proceed with countries outside the funding corridor advertised by this flow.
Prompt To Fix With AI
This is a comment left during a code review.
Path: components/grid-wallet-prod/src/apps/shared/wallet/useMoneySheet.ts
Line: 190-193
Comment:
**Funding filter conflates account eligibility**
When Add Money is opened, filtering by `accountType` admits non-euro-area `EUR_ACCOUNT` countries such as Denmark, Norway, Sweden, and Switzerland, allowing users to proceed with countries outside the funding corridor advertised by this flow.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.2d9f615 to
6b5ade0
Compare
026bd43 to
742d8cc
Compare
6b5ade0 to
7172ecc
Compare
742d8cc to
8eb60b9
Compare
7172ecc to
63fb4ad
Compare
8eb60b9 to
b895952
Compare
Merge activity
|
… rail-limited The US + euro-area restriction was applied to the whole bank picker, which also narrowed withdraw and send. That conflated two different questions: money can only ARRIVE over the rails this wallet settles (ACH/wire/RTP for USD, SEPA for EUR), but it can be PAID OUT to any corridor Grid supports. - BANK_COUNTRIES is the full 55-country list again (restored from before the trim, with its recipient names and bank pools; validated against the spec schemas). - Add money filters to FUNDING_ACCOUNT_TYPES; withdraw, send and receive get the whole list. - Each direction has its own "popular" order: `popularRank` follows payment volume for payouts, `fundingRank` orders the corridors we can be funded over. - Corridor copy follows the direction too — the shared bank source row, and the empty-state text, no longer claim US/euro-area limits in the payout flows. Verified in the browser: Add offers the funding pool (US, Germany, France, Spain, Italy, Netherlands popular; no Mexico/India), Withdraw offers Mexico, India, Nigeria, the UK, Brazil, Kenya and the rest. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Pjqydq34z8DBK1kBrioXK2
b895952 to
48e26ef
Compare

The US + euro-area restriction was applied to the whole bank picker, which also
narrowed withdraw and send. That conflated two different questions: money can only
ARRIVE over the rails this wallet settles (ACH/wire/RTP for USD, SEPA for EUR), but
it can be PAID OUT to any corridor Grid supports.
with its recipient names and bank pools; validated against the spec schemas).
whole list.
popularRankfollows payment volumefor payouts,
fundingRankorders the corridors we can be funded over.empty-state text, no longer claim US/euro-area limits in the payout flows.
Verified in the browser: Add offers the funding pool (US, Germany, France, Spain,
Italy, Netherlands popular; no Mexico/India), Withdraw offers Mexico, India,
Nigeria, the UK, Brazil, Kenya and the rest.
Co-Authored-By: Claude Opus 5 (1M context) noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01Pjqydq34z8DBK1kBrioXK2