-
Notifications
You must be signed in to change notification settings - Fork 74
Release/v1.6.6 #2894
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: release/v1.6
Are you sure you want to change the base?
Release/v1.6.6 #2894
Conversation
- moves the `VectorClock` trait & implementation into `xmtp_proto`. debating whether the trait should be removed altogether and methods simply moved onto `GlobalCursor`, since it doesn't seem like we want multiple `VectorClock` types anyway. I mostly like the trait for the separation between more normal `HashMap` operations and formal `VectorClock` operations. - added an `lcc` and `gcc` function to `TopicCursor` which computes lcc & gcc with a iterative fold operation on all VectorClocks in `TopicCursor`.
smallvec backs a vec first with a fixed-size `Copy`-able Array (in this case `[u8;33]`) and if it grows larger "spills" the contents onto the heap. `Topics` should not grow beyond 33 bytes, since the largest topic identifier is an `InstallationId` at 32 bytes, so this should reduce cloning wherever `Topic`s are used moves Ids into their own files (`GroupId` and `InstallationId`)
<!-- 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 post its summary as a comment. --> ### Make `Conversations.stream_message_deletions` in [conversations.rs](https://github.com/xmtp/libxmtp/pull/2890/files#diff-305d8a9df912ee15a450791cf1af33e26798a0a4877f6a4dc457d291914bc126) async to add on_close support for the message deletion stream Change the N-API method `Conversations.stream_message_deletions` to `async`, returning a `Future` that yields `Result<StreamCloser>` after invoking `RustXmtpClient::stream_message_deletions_with_callback`. #### 📍Where to Start Start with the `Conversations::stream_message_deletions` N-API method in [conversations.rs](https://github.com/xmtp/libxmtp/pull/2890/files#diff-305d8a9df912ee15a450791cf1af33e26798a0a4877f6a4dc457d291914bc126). ---- <!-- Macroscope's review summary starts here --> <a href="https://app.macroscope.com">Macroscope</a> summarized abda21c. <!-- Macroscope's review summary ends here --> <!-- macroscope-ui-refresh --> <!-- Macroscope's pull request summary ends here -->
Dev flag was doing nothing. This fixes it.
|
Claude finished @neekolas's task —— View job Code Review CompleteReview Date: December 4, 2025, 11:14 PM UTC This PR represents a well-structured refactoring that improves code organization and prepares for future work. The changes are generally sound, but there are a few considerations to note: Positive Aspects
Concerns & Recommendations1. Potential Performance Issue with The new
pub fn cloned_vec(&self) -> Vec<u8> {
self.inner.clone().to_vec() // Double copy: clone SmallVec, then convert to Vec
}Recommendation: Consider adding 2. Missing Documentation The 3. Test Coverage Gap While there's a test for
4. Topic Byte Layout Assumption The code in xmtp_proto/src/types/topic.rs:109-112 uses an pub fn kind(&self) -> TopicKind {
self.inner[0]
.try_into()
.expect("A topic must always be built with a valid `TopicKind`")
}This is safe given the constructors, but could panic if 5. Minor Code Quality In xmtp_proto/src/types/global_cursor.rs:52, there's a typo in the doc comment: /// get the full [`super::Cursor`] that belongs to this [`OriginatorId``
Missing closing backtick. Security & CorrectnessNo security issues identified. The VectorClock implementation appears correct for causal ordering, and the SmallVec optimization maintains the same byte semantics. SummaryThis is solid refactoring work. The main concern is the performance impact of |
Release v1.6.6 and move
|
Putting together a draft PR for RC's