Conversation
…gs 1.10.0, wasm-bindings 1.10.0)
|
Claude finished @cameronvoell's task —— View job Code Review CompleteReview Date: April 7, 2026 at 16:42 UTC Critical Issue
The workflow file appears to have proper conditional logic based on path changes, which is good. However, Macroscope's review comment flagged that jobs may have been temporarily disabled - I verified this is NOT the case in the current version. All test jobs properly use Code Quality Issues1. Dead Code in Android Test ( Lines 178-187 contain unreachable code copied from // Sync both clients until consent propagates to client2.
// Client1 publishes the worker-queued intent, client2 pulls the update.
waitUntil {
alixClient.preferences.sync()
alixClient2.preferences.sync()
group2.consentState() == ConsentState.DENIED
}
assertEquals(group2.consentState(), ConsentState.DENIED)This code references 2. Resource Cleanup Concern ( The test at line 322 creates Recommendation: Use 3. Test Flakiness ( Multiple iOS tests are skipped due to flakiness:
While skipping flaky tests is pragmatic for CI, this represents significant missing test coverage for critical functionality (message sync, archive sync, streaming). Consider investigating root causes. Test CoveragePositive:
Concerns:
Performance ConsiderationsNo obvious performance issues in the changed code. The PR description mentions a performance fix for apps with many conversations or disappearing messages, but I don't see the actual implementation changes in this diff - likely in a different PR. SecurityNo security concerns identified. The archive-based sync maintains encryption, and the manual sync request change actually improves security by giving developers explicit control over network activity. Release NotesWell-documented breaking changes and migration paths. The documentation clearly explains:
Recommendations
|
sdks/android/library/src/androidTest/java/org/xmtp/android/library/HistorySyncTest.kt
Show resolved
Hide resolved
ApprovabilityVerdict: Needs human review 2 blocking correctness issues found. There is an unresolved critical review comment identifying a compilation error in the Android test file (undefined variables You can customize Macroscope's approvability policy. Learn more. |
fixes device sync tests in mobile bindings, android, and ios so it correctly verifies functionality <!-- Macroscope's pull request summary starts here --> <!-- Macroscope will only edit the content between these invisible markers, and the markers themselves will not be visible in the GitHub rendered markdown. --> <!-- If you delete either of the start / end markers from your PR's description, Macroscope will append its summary at the bottom of the description. --> > [!NOTE] > ### Fix device sync mobile bindings tests for iOS, Android, and Rust > - Adds new tests for the full device sync request flow in [Rust bindings](https://github.com/xmtp/libxmtp/pull/3288/files#diff-04f42fcf088abf13f3a20c3e154feac6341b3e9938a0f46f831a23b21a0aed74), [Android](https://github.com/xmtp/libxmtp/pull/3288/files#diff-33ca4980924b8d59d5ffc62a9e4dd6a5a30413b2183b9a946f9bba9faa3ac79f), and [iOS](https://github.com/xmtp/libxmtp/pull/3288/files#diff-c046ca278ac5c7d2a98b0d5353c906570b0a18bfe3a192448723a3ef4ceab6fa), covering message replication, consent sync, and archive-based history restore. > - Replaces fixed delays with polling loops and explicit `sendSyncRequest` calls to make tests deterministic and less flaky. > - Adds archive upload/process tests (`testSyncDeviceArchive`) on both Android and iOS that validate pre-installation history is restored via a pinned archive. > - Updates `getrandom` from 0.3 to 0.4 with the `sys_rng` feature in the workspace hack crate to unblock builds. > - Behavioral Change: `testDisablingHistoryTransferDoesNotTransfer` now explicitly creates clients with `deviceSyncEnabled=false/true` and tightens assertions around which messages are visible post-sync. > > <!-- Macroscope's review summary starts here --> > > <sup><a href="https://app.macroscope.com">Macroscope</a> summarized 190a4e7.</sup> > <!-- Macroscope's review summary ends here --> > <!-- Macroscope's pull request summary ends here --> --------- Co-authored-by: cameronvoell <cameronvoell@users.noreply.github.com> Co-authored-by: Dakota Brink <git@kota.is>
eea6742 to
eec7151
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3327 +/- ##
==========================================
+ Coverage 83.04% 83.14% +0.09%
==========================================
Files 377 377
Lines 51255 51255
==========================================
+ Hits 42564 42615 +51
+ Misses 8691 8640 -51 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Dismissing prior approval to re-evaluate a24032c
Dismissing prior approval to re-evaluate ed55ae1
.github/workflows/test.yml
Outdated
| test-workspace: | ||
| needs: detect-changes | ||
| if: needs.detect-changes.outputs.workspace == 'true' | ||
| if: false |
There was a problem hiding this comment.
🟠 High workflows/test.yml:89
The commit hardcodes if: false for test-workspace, test-node, test-wasm, test-android, and test-bindings-check jobs, and hardcodes if: true for test-ios, while removing all other jobs from the final test gate's needs array. If merged, this disables CI test coverage for everything except iOS, allowing untested code to be merged without detection. The detect-changes job still runs but its outputs are never consumed.
- if: false
+ if: needs.detect-changes.outputs.workspace == 'true'🚀 Reply "fix it for me" or copy this AI Prompt for your agent:
In file .github/workflows/test.yml around line 89:
The commit hardcodes `if: false` for `test-workspace`, `test-node`, `test-wasm`, `test-android`, and `test-bindings-check` jobs, and hardcodes `if: true` for `test-ios`, while removing all other jobs from the final `test` gate's `needs` array. If merged, this disables CI test coverage for everything except iOS, allowing untested code to be merged without detection. The `detect-changes` job still runs but its outputs are never consumed.
668f62a to
3d28971
Compare
3d28971 to
3650b6f
Compare
| alixClient.preferences.sync() | ||
| alixClient2.preferences.sync() | ||
| group2.consentState() == ConsentState.DENIED | ||
| } | ||
|
|
||
| assertEquals(group2.consentState(), ConsentState.DENIED) | ||
| } |
There was a problem hiding this comment.
🔴 Critical library/HistorySyncTest.kt:181
Lines 181-186 reference undefined variables alixClient2 and group2, which will cause a compilation error. These variables don't exist in testSyncDeviceArchive() — only client1, client2, group, group2Before, and group2After are declared. This appears to be leftover code accidentally copied from testSyncConsent(). Remove these lines.
- // Sync both clients until consent propagates to client2.
- // Client1 publishes the worker-queued intent, client2 pulls the update.
- waitUntil {
- alixClient.preferences.sync()
- alixClient2.preferences.sync()
- group2.consentState() == ConsentState.DENIED
- }
-
- assertEquals(group2.consentState(), ConsentState.DENIED)🚀 Reply "fix it for me" or copy this AI Prompt for your agent:
In file sdks/android/library/src/androidTest/java/org/xmtp/android/library/HistorySyncTest.kt around lines 181-187:
Lines 181-186 reference undefined variables `alixClient2` and `group2`, which will cause a compilation error. These variables don't exist in `testSyncDeviceArchive()` — only `client1`, `client2`, `group`, `group2Before`, and `group2After` are declared. This appears to be leftover code accidentally copied from `testSyncConsent()`. Remove these lines.
Evidence trail:
- sdks/android/library/src/androidTest/java/org/xmtp/android/library/HistorySyncTest.kt lines 20-22: class-level properties `alixClient`, `boClient`, `caroClient`, `alixWallet` (no `alixClient2`)
- Lines 128-187: `testSyncDeviceArchive()` function - declares `client1`, `client2`, `group`, `group2Before`, `group2After`
- Lines 178-186: references `alixClient2.preferences.sync()` and `group2.consentState()` - neither variable exists in this function
- Lines 48-90: `testSyncConsent()` - declares `alixClient2` at line 58 and `group2` at lines 74-76, with identical code block at lines 82-89
Release 1.10.0 SDK updates with manual history sync into main
1.11.0-devand adds release notes for Android/iOS 4.10.0 and Node/WASM 1.10.0 SDKspreferences.sync()in favor of explicit archive management methodssendSyncRequestand process archives with a PIN; automatic history transfer on new installation no longer occurs📊 Macroscope summarized 0887d86. 1 file reviewed, 2 issues evaluated, 0 issues filtered, 1 comment posted
🗂️ Filtered Issues