Repository navigation
feat(syncing): per-phase progress, connected peers, and peer rotation in the sync alert - #809
Merged
QuantumExplorer merged 1 commit intoJul 16, 2026
Conversation
… in the sync alert The syncing detail alert previously showed a single "header #x of x" line even when headers were long finished and the overall percentage was grinding through the filter phases. It now renders the whole pipeline: - SyncStateSnapshot carries a per-phase array (headers, filter headers, filters, masternode list) populated from SPVSyncProgress; the alert shows one row per phase with its own progress bar, a green check once caught up, and grouping-formatted heights. - The alert content is rewritten in SwiftUI (SyncingAlertView + view model observing the sync monitor and the SPV coordinator); the old UIKit SyncingAlertContentView is deleted and the controller shrinks to the modal-popup hosting shell. - Connected peers are listed live from SwiftDashSDKSPVCoordinator.connectedPeers with node-type badges (Evonode / Masternode / Node). - "Sync too slow? Change peers" appears after 45 s without progress movement and triggers SwiftDashSDKWalletRuntime.rotatePeers() — a new serialized full stop → start through the runtime's lifecycle pipeline; dash-spv re-dials peers from the DNS seeds and resumes from persisted chain data. The action hides while an identity registration/claim is in flight (asset-lock IS/CL proofs ride the P2P subscription). Peer selection is seed-random — a same-peer redial is possible until the SDK grows an exclude-list. Verified: dashpay arm64-sim build green; QA-simulator smoke of the mid-sync dialog (headers/masternodes checked, filter phases advancing). Co-Authored-By: Claude Fable 5 <[email protected]>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The syncing detail alert used to show one
header #x of xline even when headers were finished and the overall percentage was actually grinding through the filter phases. This PR makes the dialog explain the whole pipeline and gives users a self-serve action when sync drags:SyncStateSnapshotnow carries a phase array (headers → filter headers → filters → masternode list) populated fromSPVSyncProgress; the alert renders one row per phase with its own progress bar, a green ✓ once caught up, and grouped heights (1,754,000 / 2,505,629).SyncingAlertView(+ view model observingSyncingActivityMonitorand the SPV coordinator); the UIKitSyncingAlertContentViewis deleted andSyncingAlertViewControllershrinks to the modal-popup hosting shell — per the SwiftUI-first rule.SwiftDashSDKSPVCoordinator.connectedPeerswith node-type badges (Evonode / Masternode / Node) and a count.SwiftDashSDKWalletRuntime.rotatePeers()— apeerRotationrefresh trigger through the runtime's serialized lifecycle pipeline (full stop → start; dash-spv re-dials from DNS seeds and resumes from persisted chain data).Known limitation, documented in code: peer selection on restart is seed-random, so redialing a previous peer is possible. A guaranteed fresh set needs an exclude-list on
PlatformSpvStartConfigupstream.Five new en localization keys (
Connected peers,Sync too slow?,Change peers,Evonode,Node) plus three phase labels;MasternodeandFiltersreuse existing translated keys.Verification
dashpayarm64-sim build green (Xcode 26.6 / Swift 6.3.3).🤖 Generated with Claude Code