Skip to content

chore(wallet): bring master + release-8.7.0 onto swift-sdk-integration - #805

Merged
QuantumExplorer merged 278 commits into
swift-sdk-integrationfrom
merge/master-into-swift-sdk
Jul 15, 2026
Merged

chore(wallet): bring master + release-8.7.0 onto swift-sdk-integration#805
QuantumExplorer merged 278 commits into
swift-sdk-integrationfrom
merge/master-into-swift-sdk

Conversation

@romchornyi

Copy link
Copy Markdown
Contributor

Issue being fixed or feature implemented

swift-sdk-integration had fallen ~4 months behind. This PR brings it up to date with master and the current releas branch, so the SwiftDashSDK migration work sits on top of the latest features instead of a stale base — with wallet data migration preserved so upgrading users aren't affected.

What was done?

Layered integration onto swift-sdk-integration:

  • Merged origin/master (130 commits) then feat/release-8.7.0 (141 commits), then caught up the 4 latest swift-sdk-integration commits (fix(wallet): adapt shielded spends to the SDK's per-operation resolver (latest v4.1-dev) #799, feat(dashpay): join DashPay from the Shielded balance with readiness UX #801, feat(wallet): in-app diagnostic log export for beta feedback #802, fix(wallet): imported wallets scan from genesis, not from the newest checkpoint #804).
  • Conflict policy: keep the incoming feature work, re-apply the branch's DashSync → SwiftDashSDK migration on top (DSTransaction → Transaction, DWEnvironment reads → SwiftDashSDKWalletState / SwiftDashSDKWalletSource, DSLogger → DWLogger). Where a side rewrote a whole mechanism, one side is taken whole rather than interleaved.
  • Notable resolutions: balance sourced from SwiftDashSDKWalletState (DWEnvironment is frozen post-M6); Home tx row uses release's DashUIKit.TransactionView with the branch's shielded-transfer semantics; menu navigation unified on the branch's NavigationLink/@State; NumericKeyboardView/reachability re-pointed at DashUIKit/NetworkReachability Coinbase-transfer + preview stub migrated to txidWire/Transaction; DSTransaction+DashWallet extension restored for release Swap code.
  • Project/build: iOS deployment target aligned to 18.0; local swift-sdk SPM package + SwiftDashSDK product re-added (release kept only remote DashUIKit); project.pbxproj reconciled so dashpay ⊇ dashwallet; TOCropViewController 2.6.1 + combined dashwallet-dashpay scheme added.
  • Platform pin: requires ../platform at v4.1-dev tip dc1d645df4 (#4131 adds LoggingPreferences.logsRootDirectory); DashSDKFFI sim xcframework rebuilt against it.
  • Feature gating: Maya and Dash DEX / SwapKit entry points are withheld (showsMaya/showsSwapKit = false). Both build swaps through frozen DashSync (hand-built DSTransaction + OP_RETURN memo), which SwiftDashSDK's CoreTransactionBuilder cannot emit yet — screens stay compiled, entry points hidden. Restoring them needs OP_RETURN support in the SDK.

How Has This Been Tested?

  • dashwallet-dashpay scheme builds clean on the iOS Simulator (ARCHS=arm64; the FFI xcframework ships an arm64-only sim slice).
  • App launches and runs on the simulator (testnet).
  • Still pending: full end-to-end wallet-data migration QA (old wallet → upgrade → seed/balance/history/PIN intact) and feature regression pass. The KeyMigrator call site (AppDelegate) and migration files were verified untouched by the merge, but the on-device upgrade flow has not yet been exercised.

Breaking Changes

  • iOS deployment target raised to 18.0 (matches the branch + Podfile post_install).
  • Maya and Dash DEX entry points are withheld for this integration — users who used them will notice they're gone until ported to the SDK.
  • The dashwallet target is not kept green on this branch (by design); use the dashpay / dashwallet-dashpay scheme.

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have made corresponding changes to the documentation

For repository code-owners and collaborators only

  • I have assigned this pull request to a milestone

HashEngineering and others added 30 commits April 14, 2026 10:11
…dger

feat: update csv export and zenledger
…gation

- Migrate all menu items to use the new MenuItem component
- Update styles for MenuItemsList
- Replace all menu item icons with updated assets
- Change "Buy & Sell Dash" and "Explore" from bottom sheet to full page
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
feat: Update menu items on the More page
jeanpierreroma and others added 27 commits July 14, 2026 20:19
Brings 130 commits of master (803 files) onto the SwiftDashSDK migration
branch. 23 conflicts resolved; `dashpay` builds clean (ARCHS=arm64).

Conflict policy: keep master's feature work, re-apply the branch's
DashSync -> SwiftDashSDK migration on top (DSTransaction -> Transaction,
DWEnvironment reads -> SwiftDashSDKWalletState / SwiftDashSDKWalletSource,
DSLogger -> DWLogger). Where a side rewrote a whole mechanism, one side is
taken whole rather than interleaved.

Notable resolutions:
- BalanceModel reads SwiftDashSDKWalletState; master's DWEnvironment.balance
  is frozen at zero post-M6 and would have shown an empty balance.
- HomeView: gift-card sheet rewired to the branch's @State giftCardTxId
  (the auto-merge left the sheet bound to viewModel.giftCardTxId while the
  write went to @State, so the sheet could never open).
- DashSpendPayScreen: master's component split kept; the branch's inline
  layout would have rendered the screen twice.
- Menu navigation unified on the branch's NavigationLink/@State; master's
  push-based show*() funcs removed.
- Gift-card note keeps master's semantics (buildPiggyOrderNote carries
  PiggyCards order quantities), not the branch's bare id.
- CoinJoin mixing and paper-wallet sweep stay deleted (branch decisions).

Maya (new in master, 92 files) is DashSync-only: it hand-builds a
DSTransaction with an OP_RETURN memo, which SwiftDashSDKTransactionSender
cannot express. It compiles here but would spend against frozen DashSync
UTXOs. Kept compiling (and DSTransaction+DashWallet.{h,m} restored for it);
its UI entry point is disabled in the follow-up commit.
Maya's swap path hand-builds a DSTransaction (OP_RETURN memo, fixed output
order) and broadcasts it through DashSync. DashSync's SPV is frozen post-M6,
so balances and UTXOs read stale/zero — a swap would be built against dead
state and fail after the user committed to it. Showing a button that cannot
work is worse than not showing it.

The Maya screens stay compiled; only the portal card is gated. Mirrors the
existing showCoinbase gate.

TODO(maya-sdk-port): restore once SwiftDashSDKTransactionSender can emit an
OP_RETURN output with a preserved output order (needs SDK/Rust support).
# Conflicts:
#	DashWallet.xcodeproj/project.pbxproj
#	DashWallet/Sources/UI/Maya/Convert/Components/MayaAmountView.swift
# Conflicts:
#	.gitignore
#	DashWallet.xcodeproj/project.pbxproj
…iles

The Sources phases of both app targets still referenced F4C40609...0001/0002,
but the PBXBuildFile objects were lost while resolving the release-branch
merges. CocoaPods silently discards such dangling refs, which would have
dropped the migration from the build and broken DatabaseConnection.migrations().

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
HomeViewController gained UIHostingController/Color usage from the CrowdNode
balance reminder but never imported SwiftUI — DashUIKit does not re-export it,
so the file did not compile.

DashSyncCurrentCommit had been rolled back to 3b28f981 by the DashDEX branch,
losing master's 13fc5bea. Point it at DashSync master (d3c1497a), which is the
first commit carrying DSWallet.lockedBalance that BalanceModel already requires.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The provider refunds a deposit that is even one base unit short of the quoted
amount, while an overpayment of one unit is accepted. Truncating meant a quoted
5.701673 USDC was deposited as 5.701672 and refunded.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Only dashwallet linked DashUIKit, and neither target declared it in
packageProductDependencies — so the dashpay scheme failed to resolve the module
for the many sources shared by both targets (e.g. LocalCurrencyView).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
transactionRowIcons only read metadata.icon (the merchant logo bitmap), so rows
whose provider supplies a named icon instead — SwapOrderMetadataProvider sets
transaction-convert, CoinbaseMetadataProvider sets transaction-coinbase.received
— fell through to the generic send arrow.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sync bookkeeping is per-network (kExploreDatabaseLastVersion_Mainnet/_Testnet)
but both networks share a single explore.db on disk. After switching chains the
saved version for the new network already read as up to date and the file check
passed, so the app kept serving the other network's merchants — testnet users
saw the mainnet database (no Brinker, fewer merchants than Android).

Record which network the installed database belongs to and force a download when
it differs. Existing installs have no marker, so they refresh once on next launch.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
activeTopViewController() returns the top-most controller, which may be the PIN
prompt itself — DSRequestPinViewController is a DWAlertController and reports no
presentedViewController, so the existing guard let the reminder present over it.
That broke the PIN's dismissal and let its completion fire twice, tripping
NSParameterAssert(completion) in DashSync.

The pending-reminder retry already re-attempts every 0.5s, so the sheet simply
waits for the PIN to be dismissed.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The DashDEX stack had already moved this row to DashUIKit; it was reverted during
the release merge because the component had no way to show the "Locked" status
that fix/locked-rewards-flow shipped. DashUIKit now carries trailingStatusText,
so the row moves over for real — TransactionPreview was only a typealias for the
generic MenuItem, which is why the row's typography drifted from the design.

Also restores Package.resolved, dropped by the chore/secrets-hardening merge.
DashUIKit is pinned to a branch, so without it every build floats to whatever
import/final points at.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
# Conflicts:
#	DashWallet.xcodeproj/project.pbxproj
#	DashWallet/Sources/UI/Coinbase/Transfer Amount/TransferAmountViewController.swift
#	DashWallet/Sources/UI/Maya/Convert/Components/MayaAmountView.swift
#	DashWallet/Sources/UI/Swap/Convert/SwapConvertView.swift
#	DashWallet/Sources/UI/SwiftUI Components/Geometry Readers/FrameReader.swift
#	DashWallet/Sources/UI/SwiftUI Components/Geometry Readers/ScaleToFitWidth.swift
Swept into the coinbase merge by a git add -A. The pod graph is unchanged (spec
checksums and PODFILE CHECKSUM are identical); only the tool-version stamp moved,
and bumping it would oblige every dev and CI to run 1.16.2. Not a release decision.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The buy matcher required tx.timestamp >= order.timestamp. An unconfirmed tx
reports when the wallet first saw it, but a mined one reports its block's
timestamp, which only has to beat the median of the last 11 blocks and so can
sit minutes earlier. The match therefore vanished the moment the tx confirmed
and the row fell back from "Converted · USDC/DASH" to a plain "Received".

Give the block clock two hours of slack; the receive address and the ±5% amount
check are what actually disambiguate the transaction.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The archive unzipped straight over the live explore.db and the -wal/-shm sidecars
of the old database were left in place, so SQLite replayed that WAL against the
new file: 'database disk image is malformed'. The reconnect only ran afterwards.

Post databaseWillBeUpdatedNotification first so the connection releases the file,
then delete the sidecars, then unzip. Queries return [] during the window.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
fix/coinbase-receive-summary carried its own DashUIKit wiring; the merge kept our
build-file object but auto-merged their reference into dashpay's Frameworks phase,
leaving it pointing at nothing. CocoaPods discards such refs silently — the same
failure mode that dropped the migration build files earlier.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
….7.0

# Conflicts:
#	DashWallet.xcodeproj/project.pbxproj
#	DashWallet/Sources/Application/Tools.swift
#	DashWallet/Sources/UI/Maya/Convert/MayaConvertView.swift
#	DashWallet/Sources/UI/Maya/OrderPreview/OrderPreviewViewModel.swift
#	DashWallet/Sources/UI/Swap/Convert/MayaAmountFormatter.swift
#	DashWallet/Sources/UI/Swap/Convert/SwapConvertViewModel.swift
#	DashWallet/Sources/UI/SwiftUI Components/Geometry Readers/FrameReader.swift
#	DashWallet/Sources/UI/SwiftUI Components/NumericKeyboardView.swift
#	DashWallet/ar.lproj/Localizable.strings
#	DashWallet/bg.lproj/Localizable.strings
#	DashWallet/ca.lproj/Localizable.strings
#	DashWallet/cs.lproj/Localizable.strings
#	DashWallet/da.lproj/Localizable.strings
#	DashWallet/de.lproj/Localizable.strings
#	DashWallet/el.lproj/Localizable.strings
#	DashWallet/eo.lproj/Localizable.strings
#	DashWallet/es.lproj/Localizable.strings
#	DashWallet/et.lproj/Localizable.strings
#	DashWallet/fa.lproj/Localizable.strings
#	DashWallet/fi.lproj/Localizable.strings
#	DashWallet/fil.lproj/Localizable.strings
#	DashWallet/fr.lproj/Localizable.strings
#	DashWallet/hr.lproj/Localizable.strings
#	DashWallet/hu.lproj/Localizable.strings
#	DashWallet/id.lproj/Localizable.strings
#	DashWallet/it.lproj/Localizable.strings
#	DashWallet/ja.lproj/Localizable.strings
#	DashWallet/ko.lproj/Localizable.strings
#	DashWallet/mk.lproj/Localizable.strings
#	DashWallet/ms.lproj/Localizable.strings
#	DashWallet/nb.lproj/Localizable.strings
#	DashWallet/nl.lproj/Localizable.strings
#	DashWallet/pl.lproj/Localizable.strings
#	DashWallet/pt.lproj/Localizable.strings
#	DashWallet/ro.lproj/Localizable.strings
#	DashWallet/ru.lproj/Localizable.strings
#	DashWallet/sk.lproj/Localizable.strings
#	DashWallet/sl.lproj/Localizable.strings
#	DashWallet/sl_SI.lproj/Localizable.strings
#	DashWallet/sq.lproj/Localizable.strings
#	DashWallet/sr.lproj/Localizable.strings
#	DashWallet/sv.lproj/Localizable.strings
#	DashWallet/th.lproj/Localizable.strings
#	DashWallet/tr.lproj/Localizable.strings
#	DashWallet/uk.lproj/Localizable.strings
#	DashWallet/vi.lproj/Localizable.strings
#	DashWallet/zh.lproj/Localizable.strings
#	DashWallet/zh_TW.lproj/Localizable.strings
The DashDEX branch wired refund-addresses.csv into DashWalletScreenshotsUITests'
Resources, but the file was never committed, so every test target failed to build:
'refund-addresses.csv couldn't be opened because there is no such file'. The UI
test that reads it already fails with a clear message when it is absent.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
DWUpholdMainnetConstants.m hardcoded the Uphold mainnet clientID/clientSecret on
the DashDEX branch, which is pushed to this public repo. The credentials have been
rotated, so the values in history are dead, and chore/secrets-hardening moved the
constants to the gitignored Uphold-Info.plist.

Recording both fingerprints — the commit as it landed on feat/dash-dex-impr and as
rewritten into this branch — so the pre-commit hook and CI stop flagging them.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The amount-paste branch added the file to dashwallet only, so dashpay failed with
'cannot find MayaAmountFormatter in scope' — every other file in that folder has a
build file per target.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
SDK-only identities have no DSBlockchainIdentity, so the header avatar was
rendered with only its random background — a blank circle. Add
`configureAsCurrentUser` on DWDPAvatarView (username -> letter, avatarURL ->
image from DWCurrentUserIdentityInfo.shared) and route to it from
HomeViewController when blockchainIdentity is nil. DashSync-backed identities
keep the existing path.

WIP: preserved ahead of the feat/release-8.7.0 merge; not yet verified on device.
Brings the real release target (141 commits / 322 files ahead of the master
merge) onto the SwiftDashSDK branch. 184 conflicts resolved (129 .strings +
~46 code + pbxproj); dashpay builds clean (ARCHS=arm64).

Base + policy:
- pbxproj base = release (keeps its structural fixes: remote DashUIKit, the
  Components synchronized folder, dangling-ref cleanups). Then reconciled
  programmatically: removed 131 refs to branch-deleted files across all build
  phases, re-added the 81/99 branch SwiftDashSDK source files, restored the
  DWLogger.h ref, and re-added the local swift-sdk SPM package + SwiftDashSDK
  product (release had dropped it; only remote DashUIKit remained).
- Deployment target raised release's 15.0 -> 18.0 to match the branch and the
  Podfile post_install (pods build at 18.0).
- DashSync pin -> release's d3c1497a.

Feature reconciliation (keep master/release features, re-apply the branch's
DashSync->SwiftDashSDK migration on top):
- Shortcuts: branch's getTestDash/switchWallet AND release's new .dashDEX coexist.
- Home tx row uses release's DashUIKit.TransactionView API with the branch's
  shielded-transfer `details` semantics (dropped the duplicate icon args).
- ExploreDatabaseSyncManager keeps release's chain-switch merchant-DB fix but
  sources the network from WalletEnvironment (DWEnvironment is frozen post-M6).
- DWUpholdConstants keeps release's Info.plist secret (rotated) with the
  branch's WalletEnvironment network check.
- Coinbase transfer + preview stub migrated to the branch's txidWire/Transaction
  contracts; reachability routed to NetworkReachability; NumericKeyboardView
  imported from DashUIKit (release extracted it there).
- Restored DSTransaction+DashWallet.swift's DSTransaction extension (needed by
  release Swap code) without the DSTransactionDirection block (TransactionDataItem
  already provides it).

Dash DEX / SwapKit is new in release and, like Maya, builds swaps through frozen
DashSync (5 Swap files hand-build DSTransaction). Both entry points are gated off
(showsMaya/showsSwapKit = false) so a broken swap can't be reached; screens stay
compiled. Product decision on porting either to the SDK is deferred.
It was swept into the master-merge commit by git add -A; it is not tracked
upstream (swift-sdk-integration / feat/release-8.7.0) and holds CLIENT_SECRET /
SANDBOX_CLIENT_SECRET. Untracked and gitignored; the file stays on disk for local
builds. NOTE: the blob is still present in history at c3f92c2d6 — scrub before
this branch is pushed or merged onward.
…shpay scheme

- Podfile/Podfile.lock: add TOCropViewController 2.6.1
- project.pbxproj + new dashwallet-dashpay shared scheme
Brings the 4 new swift-sdk-integration commits (#799, #801, #802, #804:
shielded-spend resolver adaptation, Join DashPay from Shielded, in-app
diagnostic log export, imported-wallet genesis scan) onto the branch.

- 2 conflicts (project.pbxproj, en.lproj/Localizable.strings); the rest
  auto-merged. en.strings kept ours (release-8.7.0 strings); the 4 features'
  new keys are re-extracted by bartycrouch on build.
- Added the 3 new source files to targets: DiagnosticLogExporter (both),
  JoinDashPayReadinessScreen + ShieldedIdentityFundingReadiness (dashpay).
- Requires platform pinned at v4.1-dev tip dc1d645df4 (#4131 adds
  LoggingPreferences.logsRootDirectory); local ../platform bumped and the
  DashSDKFFI sim xcframework rebuilt.

Builds clean via the dashwallet-dashpay scheme (ARCHS=arm64).
@coderabbitai

coderabbitai Bot commented Jul 15, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: b0039494-a31a-4bc7-8fed-4999f96c892b

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch merge/master-into-swift-sdk

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@QuantumExplorer
QuantumExplorer merged commit 1ca07eb into swift-sdk-integration Jul 15, 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.

5 participants