Skip to content

fix(dapp): name the connected wallet on every deployment, not only multi-network ones - #162

Merged
0xDeon merged 1 commit into
mainfrom
fix/wallet-header-every-deploy
Nov 6, 2026
Merged

0xDeon merged 1 commit into
mainfrom
fix/wallet-header-every-deploy

Conversation

@0xDeon

@0xDeon 0xDeon commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

Bug

On prod, connected users see "Connect your wallet to cash out" when they try to pay out naira, and their payout history is empty.

Prod logs show /api/naira/orders and /api/naira/rate returning 401 to these users tonight, between 22:29 and 22:32.

Cause

With sign-in paused, the server tells users apart by the wallet header the page sends.

That header is added by a fetch wrapper. The wrapper was installed only when the deployment serves more than one Stellar network. Prod is built with NEXT_PUBLIC_STELLAR_NETWORKS=mainnet alone, so the wrapper never installed and plain fetch calls sent no wallet.

Weave cash-outs use walletFetch, which adds the header itself, so they kept working. The Stellar naira flow, payout history and the standing-orders inbox use plain fetch, so they failed. The only users who got through had a session cookie left over from the old email sign-in.

Fix

The wrapper is now installed on every deployment, in both places that set it up: ChainProvider and the connect page.

It covers every page's calls on every chain.

Checks

  • A new test fails before the fix and passes after: on a mainnet-only deployment, /api/naira/orders and /api/naira/rate carry the wallet header.
  • tsc, eslint and prettier are clean.
  • Full suite: 352 of 353 test files pass. The one failure was the oneclick-origin timing flake, which passes alone (89/89).

…lti-network ones

The fetch wrapper that adds the wallet header was installed only where several
Stellar networks are served. Prod is built with mainnet alone, so plain fetch
calls carried no wallet: naira payouts answered "Connect your wallet to cash
out" to connected wallets, and payout history came back empty.
@netlify

netlify Bot commented Nov 6, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for useintent ready!

Name Link
🔨 Latest commit 31fad07
🔍 Latest deploy log https://app.netlify.com/projects/useintent/deploys/6aee55f216697137208f440b
😎 Deploy Preview https://deploy-preview-162--useintent.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify

netlify Bot commented Nov 6, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for useintentadapp ready!

Name Link
🔨 Latest commit 31fad07
🔍 Latest deploy log https://app.netlify.com/projects/useintentadapp/deploys/6aee55f2029711a9614a0a80
😎 Deploy Preview https://deploy-preview-162--useintentadapp.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@0xDeon
0xDeon merged commit eba67fc into main Nov 6, 2026
9 of 10 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.

1 participant