Skip to content

fix(ui): retire Join DashPay for synced-in identities; Core Sync Status label#837

Merged
QuantumExplorer merged 1 commit into
swift-sdk-integrationfrom
fix/menu-dashpay-mirror-selfheal
Jul 16, 2026
Merged

fix(ui): retire Join DashPay for synced-in identities; Core Sync Status label#837
QuantumExplorer merged 1 commit into
swift-sdk-integrationfrom
fix/menu-dashpay-mirror-selfheal

Conversation

@QuantumExplorer

Copy link
Copy Markdown
Member

Problem

The More menu showed Join DashPay — Request your username on a device whose wallet already owns Quantumtester2 (QA-iPhone16). #831 gated the banner on the DWGlobalOptions.dashpayUsername mirror, but the mirror is written only by an on-device registration completion or the explicit Find-identities adoption. An identity that arrived any other way — synced in from Platform after a reinstall, or registered under an earlier build — leaves the mirror empty forever, so every mirror reader disagrees with the SDK truth rendered everywhere else.

Fix

  • Self-heal the mirror at the source. DWCurrentUserIdentityInfo.computeSnapshot now backfills dashpayUsername + dashpayRegistrationCompleted whenever the SDK yields a real DPNS name and the mirror is empty, then posts the bridge state-change notification (async — the compute runs inside a lazy property read) so DWDashPayModel re-posts the canonical status update and every consumer re-keys. Only SDK-sourced names qualify (the mirror fallback can't feed itself), and the pending-contested filter has already run, so a deferred contested registration can't leak in. This fixes the whole class of stale-mirror bugs, not just this banner.
  • Gate reads SDK truth too. CurrentUserProfileModel.updateShowJoinDashpay checks DWCurrentUserIdentityInfo.shared.username alongside the mirror — which both corrects the gate immediately and triggers the backfill the moment the More menu renders.

Also

Sync Info's first row (and that screen's header) renamed SwiftDashSDK SPV Status → Core Sync Status, matching the Platform / DashPay / Shielded naming of its siblings.

Test plan

  • dashpay arm64-sim build green; installed on QA-iPhone16
  • Open More on the affected install → Join DashPay banner is gone (backfill log IDENT-INFO :: backfilled username mirror fires on first snapshot read)
  • Sync Info → first row reads Core Sync Status; detail header matches
  • Fresh wallet with no identity → banner still appears after sync completes

🤖 Generated with Claude Code

…shPay retires

The DWGlobalOptions.dashpayUsername mirror is written only by an
on-device registration completion or the explicit Find-identities
adoption. An identity that arrived any other way — synced in from
Platform after a reinstall, or registered under an earlier build —
left the mirror empty forever, so the More menu's Join DashPay banner
(gated on the mirror since #831) kept offering "Request your
username" to a wallet that already owns one.

Two-part fix:
- DWCurrentUserIdentityInfo.computeSnapshot backfills the mirror
  (username + registrationCompleted) whenever the SDK yields a real
  DPNS name and the mirror is empty, then posts the bridge
  state-change notification (async — the compute runs inside a lazy
  property read) so every mirror consumer re-keys. Only SDK-sourced
  names qualify; the pending-contested filter has already run, so a
  deferred contested registration cannot leak in.
- CurrentUserProfileModel.updateShowJoinDashpay reads the SDK truth
  directly as well as the mirror, which both fixes the gate and
  triggers the backfill the moment the menu renders.

Also renames the Sync Info menu's first row and screen header from
"SwiftDashSDK SPV Status" to "Core Sync Status".

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@QuantumExplorer
QuantumExplorer merged commit f0eceb9 into swift-sdk-integration Jul 16, 2026
2 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