Repository navigation
fix(dashpay): write identity registration logs to the shareable log files - #1155
Conversation
…iles The registration coordinator logged through os.Logger, which the "Share application logs" export does not carry. A QA report of an identity that was created on Platform while its username never was arrived with no trace of which step failed or why. Route the coordinator's log lines through DWLogger, which writes the exported files and still mirrors to the console. The asset-lock status transitions, previously debug-only, now reach the file too, and a failure on the username step that happens outside the DPNS call (context check, draft save) is logged instead of passing silently. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe coordinator now uses a private ChangesCoordinator logging
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~10 minutes Change: Bug fix Suggested reviewers: Merge Risk: ⚪ Minimal · up to The logging migration routes coordinator messages to the intended log files. The changed values were already public, and file logging is initialized before registration; no actionable merge risk remains. Architecture SummaryArchitecture risk: 🟡 Medium · up to The change affects 1 system. Changed systems: Architecture concerns Review detailsSystems and components
Before / after behavior
Reliability and maintainability
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 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 |
|
✅ Final review complete — no blockers (commit 0eeef0f) · triage: low |
thepastaclaw
left a comment
There was a problem hiding this comment.
Final validation — Phase 1 + Phase 2
The change correctly routes identity-registration diagnostics through DWLogger into exportable application logs, preserves registration control flow, and adds logging for username-step failures and asset-lock status transitions. No in-scope defects were found; Swift syntax parsing and diff whitespace checks passed. Full build and runtime verification remain unconfirmed: the pinned DashUIKit dependency requires Swift tools 6.3, while the installed Xcode 16.4 provides Swift 6.1.2.
Review provenance
Source: reviewer 1: gemini-3.8-flash-high (agent: phase1-reviewer, role: general); reviewer 2: gpt-6-astra (agent: phase2-reviewer, role: general); final verifier: gpt-6-astra (agent: astra-verifier, role: final-verifier)
- Triage:
lowbygpt-6-astra(effort low) — The diff is a contained, single-file logging change that routes coordinator diagnostics to DWLogger and adds a failure log without altering registration, funds movement, or key-handling logic. - Phase 1 reviewers:
gemini-3.8-flash-high— general (completed, effort high); agentphase1-reviewer - Phase 1 model:
gemini-3.8-flash-high— antigravity quota: weekly 32% left, 5h 85% left - Fresh verifier:
gpt-6-astra— final-verifier; agentastra-verifier - Phase 2 reviewers:
gpt-6-astra— general (completed, effort medium); agentphase2-reviewer
llbartekll
left a comment
There was a problem hiding this comment.
LGTM. The change does what the description says and nothing else.
What I checked:
- The premise holds.
DiagnosticLogExporterbundles only the SwiftDashSDK sessions and theDWLoggerfiles. It does not readOSLogStore, so before this change the coordinator'sos.Loggerlines never reached a shared archive. - The lines reach the file in TestFlight.
ddLogLevelisInfoin non-DEBUG builds, so theDDLogInfobehindDWLogger.logpasses. CocoaLumberjack logs asynchronously, so routing these calls through it adds no file I/O on the main actor. - The migration is complete. No
privacy:arguments or OSLog symbols are left. All 53 call sites use one of the adapter's four methods (debug/info/warning/error). Every optional is unwrapped before it is interpolated, so noOptional(...)strings end up in the logs. - Exposure is unchanged. Every value was already
.public, so the only difference is that it now also goes to the file the user chooses to share.
Non-blocking:
- The new catch in
finishUsernameRegistrationalso runs for DPNS failures, whichregisterNameshas already logged. A DPNS failure therefore writes two lines, the second showing the error wrapped indpnsRegistration(...). That is harmless and arguably useful. The description says the catch covers failures "outside the DPNS call", but in practice it fires for every failure. - Other parts of this flow still log through
os.Logger:AssetLockRecoveryService(6 calls),DWIdentityRegistrationBridge(4),DWCurrentUserIdentityInfo(19) andUsernameMarketplaceService(8). If the next QA export points at one of them, it will need the same change.
I reviewed the code but did not build it locally.
…me-redesign Conflicts: the identity coordinator now logs through DWLogger (#1155), so this branch's os.Logger privacy annotations are dropped and its log lines kept; the Enable Voting comment takes develop's wording (#1176); the catalogs keep "Shield your funds first", still used by the funding-privacy screen, and drop "Shield", which nothing uses any more. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Issue being fixed or feature implemented
QA tested a TestFlight build on mainnet and reported a DashPay registration that stopped partway. The identity was created on Platform, but its username was never registered. The logs QA exported show nothing from the registration flow.
DWIdentityRegistrationCoordinatorlogs throughos.Logger, and the "Share application logs" export only includes theDWLoggerfiles. So those logs never showed which step failed or what the error was, and the cause could not be established.What was done?
DWLogger, the same waySwiftDashSDKHostalready does for lines that have to reach the export.DWLoggeralso still writes to the console, so Xcode and Console.app see the same lines as before. The logger keeps itsinfo/warning/error/debugshape, so call sites stay the same apart from theprivacy: .publicarguments, which a plainStringcannot take. Every argument was already.public, so no field is newly exposed.DWLoggerrecords everything at info level, so warnings and errors carry aWARNING/ERRORtag in the text.assetLockStatus → n), which was debug-only before, now reaches the file. It fires only when the status changes, and it is what shows whether the lock reached Consumed.finishUsernameRegistrationnow logs the error. Before, it recorded the failure without logging anything.How Has This Been Tested?
xcodebuild -scheme dashpay -sdk iphonesimulator ARCHS=arm64builds successfully. The build ran locally against a platform checkout three commits behindv4.2-dev. Linking on Xcode 27 needed the local-ld64→-ld_classicedit from fix(wallet): adopt the UIScene life cycle so the app launches on iOS 27 #1145, which is not part of this PR.Breaking Changes
None.
Checklist:
For repository code-owners and collaborators only
🤖 Generated with Claude Code
Summary by CodeRabbit