The Swift Package Index logo.Swift Package Index

Track the adoption of Swift 6 strict concurrency checks for data race safety. How many packages are Ready for Swift 6?

Build Information

Successful build of NetworkKit, reference master (8fa2cf), with Swift 6.1 for macOS (SPM) on 26 Apr 2025 00:20:42 UTC.

Swift 6 data race errors: 1

Build Command

env DEVELOPER_DIR=/Applications/Xcode-16.3.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.61.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/cs4alhaider/NetworkKit.git
Reference: master
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/cs4alhaider/NetworkKit
 * branch            master     -> FETCH_HEAD
 * [new branch]      master     -> origin/master
HEAD is now at 8fa2cf2 Update README.md
Cloned https://github.com/cs4alhaider/NetworkKit.git
Revision (git rev-parse @):
8fa2cf2b83833e188bc8ca820296f9679f1bbf54
SUCCESS checkout https://github.com/cs4alhaider/NetworkKit.git at master
========================================
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": "networkkit",
      "name": "NetworkKit",
      "url": "https://github.com/cs4alhaider/NetworkKit.git",
      "version": "unspecified",
      "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/NetworkKit",
      "dependencies": [
      ]
    }
  ]
}
Fetching https://github.com/cs4alhaider/NetworkKit.git
[1/201] Fetching networkkit
Fetched https://github.com/cs4alhaider/NetworkKit.git from cache (0.66s)
Creating working copy for https://github.com/cs4alhaider/NetworkKit.git
Working copy of https://github.com/cs4alhaider/NetworkKit.git resolved at master (8fa2cf2)
warning: '.resolve-product-dependencies': dependency 'networkkit' is not used by any target
Found 0 product dependencies
========================================
Build
========================================
Selected platform:         macosSpm
Swift version:             6.1
Building package at path:  $PWD
https://github.com/cs4alhaider/NetworkKit.git
https://github.com/cs4alhaider/NetworkKit.git
{
  "dependencies" : [
  ],
  "manifest_display_name" : "NetworkKit",
  "name" : "NetworkKit",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
  ],
  "products" : [
    {
      "name" : "NetworkKit",
      "targets" : [
        "NetworkKit"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "NetworkKitTests",
      "module_type" : "SwiftTarget",
      "name" : "NetworkKitTests",
      "path" : "Tests/NetworkKitTests",
      "sources" : [
        "NetworkKitTests.swift",
        "XCTestManifests.swift"
      ],
      "target_dependencies" : [
        "NetworkKit"
      ],
      "type" : "test"
    },
    {
      "c99name" : "NetworkKit",
      "module_type" : "SwiftTarget",
      "name" : "NetworkKit",
      "path" : "Sources/NetworkKit",
      "product_memberships" : [
        "NetworkKit"
      ],
      "sources" : [
        "ApiError.swift",
        "Empty.swift",
        "Endpoint.swift",
        "Extension+Array.swift",
        "Extension+Collection.swift",
        "Extension+Dictionary.swift",
        "Extension+Encodable.swift",
        "Extension+Error.swift",
        "Extension+String.swift",
        "Extension+URL.swift",
        "Extensions.swift",
        "FileError.swift",
        "FileExtension.swift",
        "HTTPMethod.swift",
        "NetworkKit.swift",
        "NetworkService.swift",
        "Path.swift",
        "Router.swift",
        "Typealias.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.3"
}
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-16.3.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/2] Write sources
[1/2] Write swift-version-2F0A5646E1D333AE.txt
[3/21] Compiling NetworkKit Path.swift
[4/21] Compiling NetworkKit Router.swift
[5/22] Emitting module NetworkKit
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:13:16: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'NetworkService' may have shared mutable state; this is an error in the Swift 6 language mode
  8 | import Foundation
  9 |
 10 | public final class NetworkService {
    |                    `- note: class 'NetworkService' does not conform to the 'Sendable' protocol
 11 |
 12 |     private init() {}
 13 |     static let shared = NetworkService()
    |                |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'NetworkService' may have shared mutable state; this is an error in the Swift 6 language mode
    |                |- note: add '@MainActor' to make static property 'shared' part of global actor 'MainActor'
    |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 14 |
 15 |     // MARK:- public methods
[6/22] Compiling NetworkKit ApiError.swift
[7/22] Compiling NetworkKit Empty.swift
[8/22] Compiling NetworkKit Extensions.swift
[9/22] Compiling NetworkKit FileError.swift
[10/22] Compiling NetworkKit FileExtension.swift
[11/22] Compiling NetworkKit HTTPMethod.swift
[12/22] Compiling NetworkKit Extension+Encodable.swift
[13/22] Compiling NetworkKit Extension+Error.swift
[14/22] Compiling NetworkKit NetworkKit.swift
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:13:16: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'NetworkService' may have shared mutable state; this is an error in the Swift 6 language mode
  8 | import Foundation
  9 |
 10 | public final class NetworkService {
    |                    `- note: class 'NetworkService' does not conform to the 'Sendable' protocol
 11 |
 12 |     private init() {}
 13 |     static let shared = NetworkService()
    |                |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'NetworkService' may have shared mutable state; this is an error in the Swift 6 language mode
    |                |- note: add '@MainActor' to make static property 'shared' part of global actor 'MainActor'
    |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 14 |
 15 |     // MARK:- public methods
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:88:21: warning: capture of 'completion' with non-sendable type 'DataResult' (aka '(Result<Data, any Error>) -> ()') in a '@Sendable' closure
 86 |             if let error = error {
 87 |                 DispatchQueue.main.async {
 88 |                     completion(.failure(error))
    |                     |- warning: capture of 'completion' with non-sendable type 'DataResult' (aka '(Result<Data, any Error>) -> ()') in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
 89 |                 }
 90 |                 return
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:119:16: warning: capture of 'endpoint' with non-sendable type 'any Endpoint' in a '@Sendable' closure
117 |
118 |             #if DEBUG
119 |             if endpoint.isPrintable {
    |                `- warning: capture of 'endpoint' with non-sendable type 'any Endpoint' in a '@Sendable' closure
120 |                 print("""
121 |                     =================================================================
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/Endpoint.swift:11:17: note: protocol 'Endpoint' does not conform to the 'Sendable' protocol
  9 |
 10 | /// The endpoint interface, any server router should implement this interface to be able to connect
 11 | public protocol Endpoint {
    |                 `- note: protocol 'Endpoint' does not conform to the 'Sendable' protocol
 12 |
 13 |     // MARK:- Properties
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:230:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
228 |             let object = try decoder.decode(T.self, from: data)
229 |             DispatchQueue.main.async {
230 |                 completion(.success(object))
    |                 |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
231 |             }
232 |         } catch let error {
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:220:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
218 |         guard T.self != Empty.self else {
219 |             DispatchQueue.main.async {
220 |                 completion(.success(Empty() as! T))
    |                 |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
221 |             }
222 |             return
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:234:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
232 |         } catch let error {
233 |             DispatchQueue.main.async {
234 |                 completion(.failure(error))
    |                 |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
235 |             }
236 |         }
[15/22] Compiling NetworkKit NetworkService.swift
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:13:16: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'NetworkService' may have shared mutable state; this is an error in the Swift 6 language mode
  8 | import Foundation
  9 |
 10 | public final class NetworkService {
    |                    `- note: class 'NetworkService' does not conform to the 'Sendable' protocol
 11 |
 12 |     private init() {}
 13 |     static let shared = NetworkService()
    |                |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'NetworkService' may have shared mutable state; this is an error in the Swift 6 language mode
    |                |- note: add '@MainActor' to make static property 'shared' part of global actor 'MainActor'
    |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 14 |
 15 |     // MARK:- public methods
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:88:21: warning: capture of 'completion' with non-sendable type 'DataResult' (aka '(Result<Data, any Error>) -> ()') in a '@Sendable' closure
 86 |             if let error = error {
 87 |                 DispatchQueue.main.async {
 88 |                     completion(.failure(error))
    |                     |- warning: capture of 'completion' with non-sendable type 'DataResult' (aka '(Result<Data, any Error>) -> ()') in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
 89 |                 }
 90 |                 return
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:119:16: warning: capture of 'endpoint' with non-sendable type 'any Endpoint' in a '@Sendable' closure
117 |
118 |             #if DEBUG
119 |             if endpoint.isPrintable {
    |                `- warning: capture of 'endpoint' with non-sendable type 'any Endpoint' in a '@Sendable' closure
120 |                 print("""
121 |                     =================================================================
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/Endpoint.swift:11:17: note: protocol 'Endpoint' does not conform to the 'Sendable' protocol
  9 |
 10 | /// The endpoint interface, any server router should implement this interface to be able to connect
 11 | public protocol Endpoint {
    |                 `- note: protocol 'Endpoint' does not conform to the 'Sendable' protocol
 12 |
 13 |     // MARK:- Properties
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:230:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
228 |             let object = try decoder.decode(T.self, from: data)
229 |             DispatchQueue.main.async {
230 |                 completion(.success(object))
    |                 |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
231 |             }
232 |         } catch let error {
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:220:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
218 |         guard T.self != Empty.self else {
219 |             DispatchQueue.main.async {
220 |                 completion(.success(Empty() as! T))
    |                 |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
221 |             }
222 |             return
/Users/admin/builder/spi-builder-workspace/Sources/NetworkKit/NetworkService.swift:234:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
232 |         } catch let error {
233 |             DispatchQueue.main.async {
234 |                 completion(.failure(error))
    |                 |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
235 |             }
236 |         }
[16/22] Compiling NetworkKit Extension+String.swift
[17/22] Compiling NetworkKit Extension+URL.swift
[18/22] Compiling NetworkKit Extension+Collection.swift
[19/22] Compiling NetworkKit Extension+Dictionary.swift
[20/22] Compiling NetworkKit Endpoint.swift
[21/22] Compiling NetworkKit Extension+Array.swift
[22/22] Compiling NetworkKit Typealias.swift
Build complete! (5.69s)
Build complete.
{
  "dependencies" : [
  ],
  "manifest_display_name" : "NetworkKit",
  "name" : "NetworkKit",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
  ],
  "products" : [
    {
      "name" : "NetworkKit",
      "targets" : [
        "NetworkKit"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "NetworkKitTests",
      "module_type" : "SwiftTarget",
      "name" : "NetworkKitTests",
      "path" : "Tests/NetworkKitTests",
      "sources" : [
        "NetworkKitTests.swift",
        "XCTestManifests.swift"
      ],
      "target_dependencies" : [
        "NetworkKit"
      ],
      "type" : "test"
    },
    {
      "c99name" : "NetworkKit",
      "module_type" : "SwiftTarget",
      "name" : "NetworkKit",
      "path" : "Sources/NetworkKit",
      "product_memberships" : [
        "NetworkKit"
      ],
      "sources" : [
        "ApiError.swift",
        "Empty.swift",
        "Endpoint.swift",
        "Extension+Array.swift",
        "Extension+Collection.swift",
        "Extension+Dictionary.swift",
        "Extension+Encodable.swift",
        "Extension+Error.swift",
        "Extension+String.swift",
        "Extension+URL.swift",
        "Extensions.swift",
        "FileError.swift",
        "FileExtension.swift",
        "HTTPMethod.swift",
        "NetworkKit.swift",
        "NetworkService.swift",
        "Path.swift",
        "Router.swift",
        "Typealias.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.3"
}
Done.