Skip to content

Commit

Permalink
Merge pull request #62 from xmtp/cv/fork-prevention-sync-all-improvem…
Browse files Browse the repository at this point in the history
…ents

Possible group fork fixes, sync all group improvements
  • Loading branch information
cameronvoell authored Aug 26, 2024
2 parents 5ff057e + 93e9479 commit c27b586
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions LibXMTP.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'LibXMTP'
s.version = '0.5.8-beta0'
s.version = '0.5.8-beta1'
s.summary = 'XMTP shared Rust code that powers cross-platform SDKs'

s.homepage = 'https://github.com/xmtp/libxmtp-swift'
Expand All @@ -10,7 +10,7 @@ Pod::Spec.new do |s|
s.platform = :ios, '14.0', :macos, '11.0'
s.swift_version = '5.3'

s.source = { :http => "https://github.com/xmtp/libxmtp/releases/download/swift-bindings-abe9373/LibXMTPSwiftFFI.zip", :type => :zip }
s.source = { :http => "https://github.com/xmtp/libxmtp/releases/download/swift-bindings-023fef7/LibXMTPSwiftFFI.zip", :type => :zip }
s.vendored_frameworks = 'LibXMTPSwiftFFI.xcframework'
s.source_files = 'Sources/LibXMTP/**/*'
end
4 changes: 2 additions & 2 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ let package = Package(
),
.binaryTarget(
name: "LibXMTPSwiftFFI",
url: "https://github.com/xmtp/libxmtp/releases/download/swift-bindings-abe9373/LibXMTPSwiftFFI.zip",
checksum: "c47979bb43d430e3ac6a878963cbb1f5264b83b36daee2a6b1f1ee43c0670d95"
url: "https://github.com/xmtp/libxmtp/releases/download/swift-bindings-023fef7/LibXMTPSwiftFFI.zip",
checksum: "02f660eb2361cc0dd90bfccae40b89e53d869856d1b6a742f45d314e9cc832e8"
),
.testTarget(name: "LibXMTPTests", dependencies: ["LibXMTP"]),
]
Expand Down
6 changes: 3 additions & 3 deletions Sources/LibXMTP/libxmtp-version.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
Version: abe93739
Branch: main
Date: 2024-08-21 21:35:33 +0000
Version: 023fef7e
Branch: HEAD
Date: 2024-08-26 15:07:03 +0000
14 changes: 7 additions & 7 deletions Sources/LibXMTP/xmtpv3.swift
Original file line number Diff line number Diff line change
Expand Up @@ -520,7 +520,7 @@ public protocol FfiConversationsProtocol: AnyObject {

func sync() async throws

func syncAllGroups() async throws
func syncAllGroups() async throws -> UInt32
}

open class FfiConversations:
Expand Down Expand Up @@ -664,18 +664,18 @@ open class FfiConversations:
)
}

open func syncAllGroups() async throws {
open func syncAllGroups() async throws -> UInt32 {
return
try await uniffiRustCallAsync(
rustFutureFunc: {
uniffi_xmtpv3_fn_method_fficonversations_sync_all_groups(
self.uniffiClonePointer()
)
},
pollFunc: ffi_xmtpv3_rust_future_poll_void,
completeFunc: ffi_xmtpv3_rust_future_complete_void,
freeFunc: ffi_xmtpv3_rust_future_free_void,
liftFunc: { $0 },
pollFunc: ffi_xmtpv3_rust_future_poll_u32,
completeFunc: ffi_xmtpv3_rust_future_complete_u32,
freeFunc: ffi_xmtpv3_rust_future_free_u32,
liftFunc: FfiConverterUInt32.lift,
errorHandler: FfiConverterTypeGenericError.lift
)
}
Expand Down Expand Up @@ -5176,7 +5176,7 @@ private var initializationResult: InitializationResult = {
if uniffi_xmtpv3_checksum_method_fficonversations_sync() != 9054 {
return InitializationResult.apiChecksumMismatch
}
if uniffi_xmtpv3_checksum_method_fficonversations_sync_all_groups() != 62850 {
if uniffi_xmtpv3_checksum_method_fficonversations_sync_all_groups() != 3433 {
return InitializationResult.apiChecksumMismatch
}
if uniffi_xmtpv3_checksum_method_ffigroup_add_admin() != 4600 {
Expand Down

0 comments on commit c27b586

Please sign in to comment.