The Swift Package Index logo.Swift Package Index

Build Information

Successful build of Promises, reference master (2949f5), with Swift 6.1 for Android on 27 May 2025 09:42:16 UTC.

Swift 6 data race errors: 0

Build Command

bash -c docker run --pull=always --rm -v "checkouts-4606859-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:android-6.1-latest swift build --swift-sdk aarch64-unknown-linux-android24 -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 2>&1

Build Log

========================================
RunAll
========================================
Builder version: 4.63.1
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/khanlou/Promise.git
Reference: master
Initialized empty Git repository in /host/spi-builder-workspace/.git/
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: 	git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: 	git branch -m <name>
From https://github.com/khanlou/Promise
 * branch            master     -> FETCH_HEAD
 * [new branch]      master     -> origin/master
HEAD is now at 2949f58 Add promise async getter (#79)
Cloned https://github.com/khanlou/Promise.git
Revision (git rev-parse @):
2949f58f2ca81964447a1435f6e162d5cb4bb092
SUCCESS checkout https://github.com/khanlou/Promise.git at master
========================================
Build
========================================
Selected platform:         android
Swift version:             6.1
Building package at path:  $PWD
https://github.com/khanlou/Promise.git
https://github.com/khanlou/Promise.git
WARNING: environment variable SUPPRESS_SWIFT_6_FLAGS is not set
{
  "dependencies" : [
  ],
  "manifest_display_name" : "Promises",
  "name" : "Promises",
  "path" : "/host/spi-builder-workspace",
  "platforms" : [
  ],
  "products" : [
    {
      "name" : "Promise",
      "targets" : [
        "Promise"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "PromiseTests",
      "module_type" : "SwiftTarget",
      "name" : "PromiseTests",
      "path" : "PromiseTests",
      "sources" : [
        "ExecutionContextTests.swift",
        "PromiseAllTests.swift",
        "PromiseAlwaysTests.swift",
        "PromiseDelayTests.swift",
        "PromiseEnsureTests.swift",
        "PromiseErrorMatcherTests.swift",
        "PromiseErrorTests.swift",
        "PromiseKickoffTests.swift",
        "PromiseRaceTests.swift",
        "PromiseRecoverTests.swift",
        "PromiseRetryTests.swift",
        "PromiseTests.swift",
        "PromiseThrowsTests.swift",
        "PromiseZipTests.swift",
        "Wrench.swift",
        "delay.swift"
      ],
      "target_dependencies" : [
        "Promise"
      ],
      "type" : "test"
    },
    {
      "c99name" : "Promise",
      "module_type" : "SwiftTarget",
      "name" : "Promise",
      "path" : "Promise",
      "product_memberships" : [
        "Promise"
      ],
      "sources" : [
        "Promise+Extras.swift",
        "Promise.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "4.0"
}
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4606859-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:android-6.1-latest swift build --swift-sdk aarch64-unknown-linux-android24 -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 2>&1
android-6.1-latest: Pulling from finestructure/spi-images
Digest: sha256:9f3c606dcd2a4f06d17ba472aa533c43685ba7ba19a5c9bc23518a066eb7f86a
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:android-6.1-latest
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-24593BA9C3E375BF.txt
[3/5] Compiling Promise Promise.swift
/host/spi-builder-workspace/Promise/Promise.swift:21:29: warning: passing non-sendable parameter 'work' to function expecting a @Sendable closure
 18 | extension DispatchQueue: ExecutionContext {
 19 |
 20 |     public func execute(_ work: @escaping () -> Void) {
    |                           `- note: parameter 'work' is implicitly non-sendable
 21 |         self.async(execute: work)
    |                             `- warning: passing non-sendable parameter 'work' to function expecting a @Sendable closure
 22 |     }
 23 | }
/host/spi-builder-workspace/Promise/Promise.swift:41:35: warning: passing non-sendable parameter 'work' to function expecting a @Sendable closure
 37 |     }
 38 |
 39 |     public func execute(_ work: @escaping () -> Void) {
    |                           `- note: parameter 'work' is implicitly non-sendable
 40 |         guard valid else { return }
 41 |         self.queue.async(execute: work)
    |                                   `- warning: passing non-sendable parameter 'work' to function expecting a @Sendable closure
 42 |     }
 43 |
/host/spi-builder-workspace/Promise/Promise.swift:177:21: warning: capture of 'work' with non-sendable type '(@escaping (Value) -> Void, @escaping (any Error) -> Void) throws -> Void' in a '@Sendable' closure; this is an error in the Swift 6 language mode
175 |         queue.async(execute: {
176 |             do {
177 |                 try work(self.fulfill, self.reject)
    |                     |- warning: capture of 'work' with non-sendable type '(@escaping (Value) -> Void, @escaping (any Error) -> Void) throws -> Void' in a '@Sendable' closure; this is an error in the Swift 6 language mode
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
178 |             } catch let error {
179 |                 self.reject(error)
/host/spi-builder-workspace/Promise/Promise.swift:177:26: warning: capture of 'self' with non-sendable type 'Promise<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
131 |
132 |
133 | public final class Promise<Value> {
    |                    `- note: generic class 'Promise' does not conform to the 'Sendable' protocol
134 |
135 |     private var state: State<Value>
    :
175 |         queue.async(execute: {
176 |             do {
177 |                 try work(self.fulfill, self.reject)
    |                          `- warning: capture of 'self' with non-sendable type 'Promise<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
178 |             } catch let error {
179 |                 self.reject(error)
/host/spi-builder-workspace/Promise/Promise.swift:298:50: warning: capture of 'self' with non-sendable type 'Promise<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
131 |
132 |
133 | public final class Promise<Value> {
    |                    `- note: generic class 'Promise' does not conform to the 'Sendable' protocol
134 |
135 |     private var state: State<Value>
    :
296 |     private func updateState(_ newState: State<Value>) {
297 |         lockQueue.async(execute: {
298 |             guard case .pending(let callbacks) = self.state else { return }
    |                                                  `- warning: capture of 'self' with non-sendable type 'Promise<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
299 |             self.state = newState
300 |             self.fireIfCompleted(callbacks: callbacks)
/host/spi-builder-workspace/Promise/Promise.swift:299:26: warning: capture of 'newState' with non-sendable type 'State<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
 64 | }
 65 |
 66 | enum State<Value>: CustomStringConvertible {
    |      `- note: consider making generic enum 'State' conform to the 'Sendable' protocol
 67 |
 68 |     /// The promise has not completed yet.
    :
297 |         lockQueue.async(execute: {
298 |             guard case .pending(let callbacks) = self.state else { return }
299 |             self.state = newState
    |                          `- warning: capture of 'newState' with non-sendable type 'State<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
300 |             self.fireIfCompleted(callbacks: callbacks)
301 |         })
/host/spi-builder-workspace/Promise/Promise.swift:307:20: warning: capture of 'self' with non-sendable type 'Promise<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
131 |
132 |
133 | public final class Promise<Value> {
    |                    `- note: generic class 'Promise' does not conform to the 'Sendable' protocol
134 |
135 |     private var state: State<Value>
    :
305 |         let callback = Callback(onFulfilled: onFulfilled, onRejected: onRejected, executionContext: queue)
306 |         lockQueue.async(flags: .barrier, execute: {
307 |             switch self.state {
    |                    `- warning: capture of 'self' with non-sendable type 'Promise<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
308 |             case .pending(let callbacks):
309 |                 self.state = .pending(callbacks: callbacks + [callback])
/host/spi-builder-workspace/Promise/Promise.swift:309:63: warning: capture of 'callback' with non-sendable type 'Callback<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
 44 | }
 45 |
 46 | struct Callback<Value> {
    |        `- note: consider making generic struct 'Callback' conform to the 'Sendable' protocol
 47 |     let onFulfilled: (Value) -> Void
 48 |     let onRejected: (Error) -> Void
    :
307 |             switch self.state {
308 |             case .pending(let callbacks):
309 |                 self.state = .pending(callbacks: callbacks + [callback])
    |                                                               `- warning: capture of 'callback' with non-sendable type 'Callback<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
310 |             case .fulfilled(let value):
311 |                 callback.callFulfill(value)
/host/spi-builder-workspace/Promise/Promise.swift:323:20: warning: capture of 'self' with non-sendable type 'Promise<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
131 |
132 |
133 | public final class Promise<Value> {
    |                    `- note: generic class 'Promise' does not conform to the 'Sendable' protocol
134 |
135 |     private var state: State<Value>
    :
321 |         }
322 |         lockQueue.async(execute: {
323 |             switch self.state {
    |                    `- warning: capture of 'self' with non-sendable type 'Promise<Value>' in a '@Sendable' closure; this is an error in the Swift 6 language mode
324 |             case .pending:
325 |                 break
/host/spi-builder-workspace/Promise/Promise.swift:327:40: warning: capture of 'callbacks' with non-sendable type '[Callback<Value>]' in a '@Sendable' closure; this is an error in the Swift 6 language mode
 44 | }
 45 |
 46 | struct Callback<Value> {
    |        `- note: consider making generic struct 'Callback' conform to the 'Sendable' protocol
 47 |     let onFulfilled: (Value) -> Void
 48 |     let onRejected: (Error) -> Void
    :
325 |                 break
326 |             case let .fulfilled(value):
327 |                 var mutableCallbacks = callbacks
    |                                        `- warning: capture of 'callbacks' with non-sendable type '[Callback<Value>]' in a '@Sendable' closure; this is an error in the Swift 6 language mode
328 |                 let firstCallback = mutableCallbacks.removeFirst()
329 |                 firstCallback.callFulfill(value, completion: {
/host/spi-builder-workspace/Promise/Promise.swift:330:21: warning: capture of 'self' with non-sendable type 'Promise<Value>' in an isolated closure; this is an error in the Swift 6 language mode
131 |
132 |
133 | public final class Promise<Value> {
    |                    `- note: generic class 'Promise' does not conform to the 'Sendable' protocol
134 |
135 |     private var state: State<Value>
    :
328 |                 let firstCallback = mutableCallbacks.removeFirst()
329 |                 firstCallback.callFulfill(value, completion: {
330 |                     self.fireIfCompleted(callbacks: mutableCallbacks)
    |                     `- warning: capture of 'self' with non-sendable type 'Promise<Value>' in an isolated closure; this is an error in the Swift 6 language mode
331 |                 })
332 |             case let .rejected(error):
/host/spi-builder-workspace/Promise/Promise.swift:336:21: warning: capture of 'self' with non-sendable type 'Promise<Value>' in an isolated closure; this is an error in the Swift 6 language mode
131 |
132 |
133 | public final class Promise<Value> {
    |                    `- note: generic class 'Promise' does not conform to the 'Sendable' protocol
134 |
135 |     private var state: State<Value>
    :
334 |                 let firstCallback = mutableCallbacks.removeFirst()
335 |                 firstCallback.callReject(error, completion: {
336 |                     self.fireIfCompleted(callbacks: mutableCallbacks)
    |                     `- warning: capture of 'self' with non-sendable type 'Promise<Value>' in an isolated closure; this is an error in the Swift 6 language mode
337 |                 })
338 |             }
[4/5] Emitting module Promise
[5/5] Compiling Promise Promise+Extras.swift
/host/spi-builder-workspace/Promise/Promise+Extras.swift:48:17: warning: sending 'fulfill' risks causing data races; this is an error in the Swift 6 language mode
 46 |         return Promise<()>(work: { fulfill, reject in
 47 |             DispatchQueue.main.asyncAfter(deadline: .now() + delay, execute: {
 48 |                 fulfill(())
    |                 |- warning: sending 'fulfill' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'fulfill' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
 49 |             })
 50 |         })
/host/spi-builder-workspace/Promise/Promise+Extras.swift:311:30: warning: sending value of non-Sendable type 'Result<Value, any Error>' risks causing data races; this is an error in the Swift 6 language mode
309 |         try await withCheckedThrowingContinuation { continuation in
310 |             self.then(on: queue) { value in
311 |                 continuation.resume(with: .success(value))
    |                              |- warning: sending value of non-Sendable type 'Result<Value, any Error>' risks causing data races; this is an error in the Swift 6 language mode
    |                              `- note: Passing task-isolated value of non-Sendable type 'Result<Value, any Error>' as a 'sending' parameter risks causing races inbetween task-isolated uses and uses reachable from the callee
312 |             }.catch(on: queue) { error in
313 |                 continuation.resume(with: .failure(error))
Build complete! (11.24s)
Build complete.
{
  "dependencies" : [
  ],
  "manifest_display_name" : "Promises",
  "name" : "Promises",
  "path" : "/host/spi-builder-workspace",
  "platforms" : [
  ],
  "products" : [
    {
      "name" : "Promise",
      "targets" : [
        "Promise"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "PromiseTests",
      "module_type" : "SwiftTarget",
      "name" : "PromiseTests",
      "path" : "PromiseTests",
      "sources" : [
        "ExecutionContextTests.swift",
        "PromiseAllTests.swift",
        "PromiseAlwaysTests.swift",
        "PromiseDelayTests.swift",
        "PromiseEnsureTests.swift",
        "PromiseErrorMatcherTests.swift",
        "PromiseErrorTests.swift",
        "PromiseKickoffTests.swift",
        "PromiseRaceTests.swift",
        "PromiseRecoverTests.swift",
        "PromiseRetryTests.swift",
        "PromiseTests.swift",
        "PromiseThrowsTests.swift",
        "PromiseZipTests.swift",
        "Wrench.swift",
        "delay.swift"
      ],
      "target_dependencies" : [
        "Promise"
      ],
      "type" : "test"
    },
    {
      "c99name" : "Promise",
      "module_type" : "SwiftTarget",
      "name" : "Promise",
      "path" : "Promise",
      "product_memberships" : [
        "Promise"
      ],
      "sources" : [
        "Promise+Extras.swift",
        "Promise.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "4.0"
}
android-6.1-latest: Pulling from finestructure/spi-images
Digest: sha256:9f3c606dcd2a4f06d17ba472aa533c43685ba7ba19a5c9bc23518a066eb7f86a
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:android-6.1-latest
Done.