The Swift Package Index logo.Swift Package Index

Has it really been five years since Swift Package Index launched? Read our anniversary blog post!

Build Information

Successful build of XMTPRust, reference 0.1.1 (98d41c), with Swift 6.0 for macOS (SPM) on 30 Nov 2024 01:31:44 UTC.

Swift 6 data race errors: 1

Build Command

env DEVELOPER_DIR=/Applications/Xcode-16.1.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete -Xswiftc -enable-upcoming-feature -Xswiftc StrictConcurrency -Xswiftc -enable-upcoming-feature -Xswiftc DisableOutwardActorInference -Xswiftc -enable-upcoming-feature -Xswiftc GlobalActorIsolatedTypesUsability -Xswiftc -enable-upcoming-feature -Xswiftc InferSendableFromCaptures

Build Log

========================================
RunAll
========================================
Builder version: 4.58.1
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/xmtp/xmtp-rust-swift.git
Reference: 0.1.1
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/xmtp/xmtp-rust-swift
 * tag               0.1.1      -> FETCH_HEAD
HEAD is now at 98d41c6 fix: big dumb, forgot to update version in podspec
Cloned https://github.com/xmtp/xmtp-rust-swift.git
Revision (git rev-parse @):
98d41c61d2e0df55c1bc0427636ef5071b0333a0
SUCCESS checkout https://github.com/xmtp/xmtp-rust-swift.git at 0.1.1
========================================
ResolveProductDependencies
========================================
Resolving dependencies ...
{
  "identity": ".resolve-product-dependencies",
  "name": "resolve-dependencies",
  "url": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies",
  "version": "unspecified",
  "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies",
  "dependencies": [
    {
      "identity": "xmtp-rust-swift",
      "name": "XMTPRust",
      "url": "https://github.com/xmtp/xmtp-rust-swift.git",
      "version": "unspecified",
      "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/xmtp-rust-swift",
      "dependencies": [
      ]
    }
  ]
}
Fetching https://github.com/xmtp/xmtp-rust-swift.git
[1/606] Fetching xmtp-rust-swift
Fetched https://github.com/xmtp/xmtp-rust-swift.git from cache (116.23s)
Creating working copy for https://github.com/xmtp/xmtp-rust-swift.git
Working copy of https://github.com/xmtp/xmtp-rust-swift.git resolved at 0.1.1 (98d41c6)
warning: '.resolve-product-dependencies': dependency 'xmtp-rust-swift' is not used by any target
Found 0 product dependencies
========================================
Build
========================================
Selected platform:         macosSpm
Swift version:             6.0
Building package at path:  $PWD
https://github.com/xmtp/xmtp-rust-swift.git
{
  "dependencies" : [
  ],
  "manifest_display_name" : "XMTPRust",
  "name" : "XMTPRust",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
    {
      "name" : "ios",
      "version" : "13.0"
    },
    {
      "name" : "macos",
      "version" : "11.0"
    }
  ],
  "products" : [
    {
      "name" : "XMTPRust",
      "targets" : [
        "XMTPRust",
        "XMTPRustSwift"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "XMTPRustSwift",
      "module_type" : "BinaryTarget",
      "name" : "XMTPRustSwift",
      "path" : "XMTPRustSwift.xcframework",
      "product_memberships" : [
        "XMTPRust"
      ],
      "sources" : [
      ],
      "type" : "binary"
    },
    {
      "c99name" : "XMTPRust_Tests",
      "module_type" : "SwiftTarget",
      "name" : "XMTPRust-Tests",
      "path" : "Tests/XMTPRust-Tests",
      "sources" : [
        "XMTPRust_Tests.swift"
      ],
      "target_dependencies" : [
        "XMTPRust"
      ],
      "type" : "test"
    },
    {
      "c99name" : "XMTPRust",
      "module_type" : "SwiftTarget",
      "name" : "XMTPRust",
      "path" : "Sources/XMTPRust",
      "product_memberships" : [
        "XMTPRust"
      ],
      "sources" : [
        "ApiService.swift",
        "SwiftBridgeCore.swift",
        "xmtp_rust_swift.swift"
      ],
      "target_dependencies" : [
        "XMTPRustSwift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.3"
}
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-16.1.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete -Xswiftc -enable-upcoming-feature -Xswiftc StrictConcurrency -Xswiftc -enable-upcoming-feature -Xswiftc DisableOutwardActorInference -Xswiftc -enable-upcoming-feature -Xswiftc GlobalActorIsolatedTypesUsability -Xswiftc -enable-upcoming-feature -Xswiftc InferSendableFromCaptures
Building for debugging...
[0/3] Write sources
[1/3] Copying libxmtp_rust_swift.a
[2/3] Write swift-version--7754E27361AE5C74.txt
[4/7] Compiling XMTPRust xmtp_rust_swift.swift
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/xmtp_rust_swift.swift:10:26: warning: sending 'rustFnRetVal' risks causing data races; this is an error in the Swift 6 language mode
  8 |     return await withCheckedContinuation({ (continuation: CheckedContinuation<ResponseJson, Never>) in
  9 |         let callback = { rustFnRetVal in
 10 |             continuation.resume(with: rustFnRetVal)
    |                          |- warning: sending 'rustFnRetVal' risks causing data races; this is an error in the Swift 6 language mode
    |                          `- note: task-isolated 'rustFnRetVal' is passed as a 'sending' parameter; Uses in callee may race with later task-isolated uses
 11 |         }
 12 |
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/xmtp_rust_swift.swift:34:26: warning: sending 'rustFnRetVal' risks causing data races; this is an error in the Swift 6 language mode
 32 |     return await withCheckedContinuation({ (continuation: CheckedContinuation<ResponseJson, Never>) in
 33 |         let callback = { rustFnRetVal in
 34 |             continuation.resume(with: rustFnRetVal)
    |                          |- warning: sending 'rustFnRetVal' risks causing data races; this is an error in the Swift 6 language mode
    |                          `- note: task-isolated 'rustFnRetVal' is passed as a 'sending' parameter; Uses in callee may race with later task-isolated uses
 35 |         }
 36 |
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/xmtp_rust_swift.swift:58:26: warning: sending 'rustFnRetVal' risks causing data races; this is an error in the Swift 6 language mode
 56 |     return await withCheckedContinuation({ (continuation: CheckedContinuation<ResponseJson, Never>) in
 57 |         let callback = { rustFnRetVal in
 58 |             continuation.resume(with: rustFnRetVal)
    |                          |- warning: sending 'rustFnRetVal' risks causing data races; this is an error in the Swift 6 language mode
    |                          `- note: task-isolated 'rustFnRetVal' is passed as a 'sending' parameter; Uses in callee may race with later task-isolated uses
 59 |         }
 60 |
[5/7] Compiling XMTPRust SwiftBridgeCore.swift
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/SwiftBridgeCore.swift:24:1: warning: extension declares a conformance of imported type 'RustStr' to imported protocol 'Identifiable'; this will not behave correctly if the owners of 'XMTPRustSwift' introduce this conformance in the future
 22 |     }
 23 | }
 24 | extension RustStr: Identifiable {
    | |- warning: extension declares a conformance of imported type 'RustStr' to imported protocol 'Identifiable'; this will not behave correctly if the owners of 'XMTPRustSwift' introduce this conformance in the future
    | `- note: add '@retroactive' to silence this warning
 25 |     public var id: String {
 26 |         self.toString()
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/SwiftBridgeCore.swift:29:1: warning: extension declares a conformance of imported type 'RustStr' to imported protocol 'Equatable'; this will not behave correctly if the owners of 'XMTPRustSwift' introduce this conformance in the future
 27 |     }
 28 | }
 29 | extension RustStr: Equatable {
    | |- warning: extension declares a conformance of imported type 'RustStr' to imported protocol 'Equatable'; this will not behave correctly if the owners of 'XMTPRustSwift' introduce this conformance in the future
    | `- note: add '@retroactive' to silence this warning
 30 |     public static func == (lhs: RustStr, rhs: RustStr) -> Bool {
 31 |         return __swift_bridge__$RustStr$partial_eq(lhs, rhs);
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/SwiftBridgeCore.swift:207:36: warning: initialization of 'UnsafePointer<Element>' results in a dangling pointer
205 |     /// ```
206 |     func toUnsafeBufferPointer() -> UnsafeBufferPointer<Element> {
207 |         UnsafeBufferPointer(start: UnsafePointer(self), count: self.count)
    |                                    |             |- note: implicit argument conversion from 'Array<Element>' to 'UnsafePointer<Element>' produces a pointer valid only for the duration of the call to 'init(_:)'
    |                                    |             `- note: use the 'withUnsafeBufferPointer' method on Array in order to explicitly convert argument to buffer pointer valid for a defined scope
    |                                    `- warning: initialization of 'UnsafePointer<Element>' results in a dangling pointer
208 |     }
209 | }
[6/7] Emitting module XMTPRust
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/ApiService.swift:13:23: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'ApiService' may have shared mutable state; this is an error in the Swift 6 language mode
 9 |
10 | // The goal of this class is to provide a steady-ish Swift interface between Rust and xmtp-ios
11 | public class ApiService {
   |              `- note: class 'ApiService' does not conform to the 'Sendable' protocol
12 |     // Public static shared instance
13 |     public static let shared = ApiService()
   |                       |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'ApiService' may have shared mutable state; this is an error in the Swift 6 language mode
   |                       |- note: annotate 'shared' with '@MainActor' if property should only be accessed from the main actor
   |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
14 |
15 |     let environment: String
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/SwiftBridgeCore.swift:24:1: warning: extension declares a conformance of imported type 'RustStr' to imported protocol 'Identifiable'; this will not behave correctly if the owners of 'XMTPRustSwift' introduce this conformance in the future
 22 |     }
 23 | }
 24 | extension RustStr: Identifiable {
    | |- warning: extension declares a conformance of imported type 'RustStr' to imported protocol 'Identifiable'; this will not behave correctly if the owners of 'XMTPRustSwift' introduce this conformance in the future
    | `- note: add '@retroactive' to silence this warning
 25 |     public var id: String {
 26 |         self.toString()
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/SwiftBridgeCore.swift:29:1: warning: extension declares a conformance of imported type 'RustStr' to imported protocol 'Equatable'; this will not behave correctly if the owners of 'XMTPRustSwift' introduce this conformance in the future
 27 |     }
 28 | }
 29 | extension RustStr: Equatable {
    | |- warning: extension declares a conformance of imported type 'RustStr' to imported protocol 'Equatable'; this will not behave correctly if the owners of 'XMTPRustSwift' introduce this conformance in the future
    | `- note: add '@retroactive' to silence this warning
 30 |     public static func == (lhs: RustStr, rhs: RustStr) -> Bool {
 31 |         return __swift_bridge__$RustStr$partial_eq(lhs, rhs);
[7/7] Compiling XMTPRust ApiService.swift
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/ApiService.swift:13:23: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'ApiService' may have shared mutable state; this is an error in the Swift 6 language mode
 9 |
10 | // The goal of this class is to provide a steady-ish Swift interface between Rust and xmtp-ios
11 | public class ApiService {
   |              `- note: class 'ApiService' does not conform to the 'Sendable' protocol
12 |     // Public static shared instance
13 |     public static let shared = ApiService()
   |                       |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'ApiService' may have shared mutable state; this is an error in the Swift 6 language mode
   |                       |- note: annotate 'shared' with '@MainActor' if property should only be accessed from the main actor
   |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
14 |
15 |     let environment: String
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/ApiService.swift:41:13: warning: variable 'envelopeVec' was never mutated; consider changing to 'let' constant
39 |         // Call XMTPRust.publish_serialized with the given parameters, expect a XMTPRust.ResponseJson object
40 |         // that has { error: String, json: String }
41 |         var envelopeVec = RustVec<RustString>()
   |             `- warning: variable 'envelopeVec' was never mutated; consider changing to 'let' constant
42 |         for envStr in envelopes {
43 |             envelopeVec.push(value: envStr.intoRustString())
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/ApiService.swift:71:66: warning: capture of 'self' with non-sendable type 'ApiService' in a `@Sendable` closure; this is an error in the Swift 6 language mode
 9 |
10 | // The goal of this class is to provide a steady-ish Swift interface between Rust and xmtp-ios
11 | public class ApiService {
   |              `- note: class 'ApiService' does not conform to the 'Sendable' protocol
12 |     // Public static shared instance
13 |     public static let shared = ApiService()
   :
69 |                     // Call XMTPRust.subscribe_serialized with the given parameters, expect a String
70 |                     // that better be an encoded Xmtp_MessageApi_V1_SubscribeResponse with envelopes provided
71 |                     let response = await XMTPRust.subscribe_once(self.environment.intoRustString(), vec)
   |                                                                  `- warning: capture of 'self' with non-sendable type 'ApiService' in a `@Sendable` closure; this is an error in the Swift 6 language mode
72 |
73 |                     // If the error is not an empty string
/Users/admin/builder/spi-builder-workspace/Sources/XMTPRust/ApiService.swift:71:66: warning: capture of 'self' with non-sendable type 'ApiService' in an isolated closure; this is an error in the Swift 6 language mode
 9 |
10 | // The goal of this class is to provide a steady-ish Swift interface between Rust and xmtp-ios
11 | public class ApiService {
   |              `- note: class 'ApiService' does not conform to the 'Sendable' protocol
12 |     // Public static shared instance
13 |     public static let shared = ApiService()
   :
69 |                     // Call XMTPRust.subscribe_serialized with the given parameters, expect a String
70 |                     // that better be an encoded Xmtp_MessageApi_V1_SubscribeResponse with envelopes provided
71 |                     let response = await XMTPRust.subscribe_once(self.environment.intoRustString(), vec)
   |                                                                  `- warning: capture of 'self' with non-sendable type 'ApiService' in an isolated closure; this is an error in the Swift 6 language mode
72 |
73 |                     // If the error is not an empty string
Build complete! (6.09s)
Build complete.
{
  "dependencies" : [
  ],
  "manifest_display_name" : "XMTPRust",
  "name" : "XMTPRust",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
    {
      "name" : "ios",
      "version" : "13.0"
    },
    {
      "name" : "macos",
      "version" : "11.0"
    }
  ],
  "products" : [
    {
      "name" : "XMTPRust",
      "targets" : [
        "XMTPRust",
        "XMTPRustSwift"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "XMTPRustSwift",
      "module_type" : "BinaryTarget",
      "name" : "XMTPRustSwift",
      "path" : "XMTPRustSwift.xcframework",
      "product_memberships" : [
        "XMTPRust"
      ],
      "sources" : [
      ],
      "type" : "binary"
    },
    {
      "c99name" : "XMTPRust_Tests",
      "module_type" : "SwiftTarget",
      "name" : "XMTPRust-Tests",
      "path" : "Tests/XMTPRust-Tests",
      "sources" : [
        "XMTPRust_Tests.swift"
      ],
      "target_dependencies" : [
        "XMTPRust"
      ],
      "type" : "test"
    },
    {
      "c99name" : "XMTPRust",
      "module_type" : "SwiftTarget",
      "name" : "XMTPRust",
      "path" : "Sources/XMTPRust",
      "product_memberships" : [
        "XMTPRust"
      ],
      "sources" : [
        "ApiService.swift",
        "SwiftBridgeCore.swift",
        "xmtp_rust_swift.swift"
      ],
      "target_dependencies" : [
        "XMTPRustSwift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.3"
}
Done.