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 MockNetworking, reference 0.2.5 (2a9d3e), with Swift 6.0 for macOS (SPM) on 14 Oct 2024 21:21:23 UTC.

Swift 6 data race errors: 3

Build Command

env DEVELOPER_DIR=/Applications/Xcode-16.0.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete

Build Log

========================================
RunAll
========================================
Builder version: 4.55.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/Machx/MockNetworking.git
Reference: 0.2.5
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/Machx/MockNetworking
 * tag               0.2.5      -> FETCH_HEAD
HEAD is now at 2a9d3e8 refactor test  to also test url string
Cloned https://github.com/Machx/MockNetworking.git
Revision (git rev-parse @):
2a9d3e84d6589a1434b7628f60218e7be55bbd56
SUCCESS checkout https://github.com/Machx/MockNetworking.git at 0.2.5
Fetching https://github.com/Machx/Konkyo.git
[1/2411] Fetching konkyo
Fetched https://github.com/Machx/Konkyo.git from cache (0.88s)
Computing version for https://github.com/Machx/Konkyo.git
Computed https://github.com/Machx/Konkyo.git at 0.5.1 (0.51s)
Creating working copy for https://github.com/Machx/Konkyo.git
Working copy of https://github.com/Machx/Konkyo.git resolved at 0.5.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": "mocknetworking",
      "name": "MockNetworking",
      "url": "https://github.com/Machx/MockNetworking.git",
      "version": "unspecified",
      "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/MockNetworking",
      "dependencies": [
        {
          "identity": "konkyo",
          "name": "Konkyo",
          "url": "https://github.com/Machx/Konkyo.git",
          "version": "0.5.1",
          "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/Konkyo",
          "dependencies": [
          ]
        }
      ]
    }
  ]
}
Fetching https://github.com/Machx/MockNetworking.git
[1/819] Fetching mocknetworking
Fetched https://github.com/Machx/MockNetworking.git from cache (0.85s)
Fetching https://github.com/Machx/Konkyo.git from cache
Fetched https://github.com/Machx/Konkyo.git from cache (0.51s)
Computing version for https://github.com/Machx/Konkyo.git
Computed https://github.com/Machx/Konkyo.git at 0.5.1 (0.02s)
Creating working copy for https://github.com/Machx/Konkyo.git
Working copy of https://github.com/Machx/Konkyo.git resolved at 0.5.1
Creating working copy for https://github.com/Machx/MockNetworking.git
Working copy of https://github.com/Machx/MockNetworking.git resolved at 0.2.5 (2a9d3e8)
warning: '.resolve-product-dependencies': dependency 'mocknetworking' is not used by any target
Found 1 product dependencies
  - Konkyo
========================================
Build
========================================
Selected platform:         macosSpm
Swift version:             6.0
Building package at path:  $PWD
https://github.com/Machx/MockNetworking.git
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-16.0.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Building for debugging...
[0/3] Write sources
[2/3] Write swift-version--4A847ED0836F2485.txt
[4/20] Compiling Konkyo Condition.swift
[5/20] Compiling Konkyo Mutex.swift
[6/20] Compiling Konkyo LoggingExtensions.swift
[7/20] Compiling Konkyo ViewModel.swift
[8/21] Compiling Konkyo NetworkingExtensions.swift
[9/21] Compiling Konkyo Settings.swift
[10/21] Compiling Konkyo RollingDictionary.swift
[11/21] Compiling Konkyo Debouncer.swift
[12/21] Emitting module Konkyo
[13/21] Compiling Konkyo UnfairLock.swift
[14/21] Compiling Konkyo NSLockExtensions.swift
[15/21] Compiling Konkyo UIApplicationExtensions.swift
[16/21] Compiling Konkyo Initialization.swift
[17/21] Compiling Konkyo Log.swift
[18/21] Compiling Konkyo ViewExtension.swift
[19/21] Compiling Konkyo CPUInfo.swift
[20/21] Compiling Konkyo AsynchronousOperationBase.swift
[21/21] Compiling Konkyo Atomic.swift
[22/28] Compiling MockNetworking Dictionary.swift
[23/28] Compiling MockNetworking URLSession.swift
[24/28] Compiling MockNetworking MockPropertyResponse.swift
[25/28] Emitting module MockNetworking
/Users/admin/builder/spi-builder-workspace/Sources/MockNetworking/MockResponseStore.swift:22:13: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockResponseStore' may have shared mutable state; this is an error in the Swift 6 language mode
19 | ///
20 | /// This class is thread safe and will atomically read & update values.
21 | final class MockResponseStore {
   |             `- note: class 'MockResponseStore' does not conform to the 'Sendable' protocol
22 | 	static let shared = MockResponseStore()
   |             |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockResponseStore' 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
23 |
24 | 	// Actual backing store for the URL Responses.
/Users/admin/builder/spi-builder-workspace/Sources/MockNetworking/MockURLProtocol.swift:37:20: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockURLProtocol' may have shared mutable state; this is an error in the Swift 6 language mode
 24 |
 25 | /// Class Responsible for setting up a Mock Network Infrastructure for Network Tests.
 26 | public final class MockURLProtocol: URLProtocol {
    |                    `- note: class 'MockURLProtocol' does not conform to the 'Sendable' protocol
 27 |
 28 | 	public enum MockNetworkingErrors: Error {
    :
 35 | 	}
 36 |
 37 | 	public static let shared = MockURLProtocol()
    |                    |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockURLProtocol' 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
 38 |
 39 | 	//MARK: - Required URLProtocol API's
/Users/admin/builder/spi-builder-workspace/Sources/MockNetworking/MockURLProtocol.swift:104:21: warning: static property '_isRegistered' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
102 | 	//MARK: - Registration API's
103 |
104 | 	private static var _isRegistered = false
    |                     |- warning: static property '_isRegistered' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                     |- note: convert '_isRegistered' to a 'let' constant to make 'Sendable' shared state immutable
    |                     |- note: annotate '_isRegistered' 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
105 |
106 | 	/// Registers MockURLProtocol and sets the values that should be responded to the given URL.
[26/28] Compiling MockNetworking MockURLProtocol.swift
/Users/admin/builder/spi-builder-workspace/Sources/MockNetworking/MockURLProtocol.swift:37:20: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockURLProtocol' may have shared mutable state; this is an error in the Swift 6 language mode
 24 |
 25 | /// Class Responsible for setting up a Mock Network Infrastructure for Network Tests.
 26 | public final class MockURLProtocol: URLProtocol {
    |                    `- note: class 'MockURLProtocol' does not conform to the 'Sendable' protocol
 27 |
 28 | 	public enum MockNetworkingErrors: Error {
    :
 35 | 	}
 36 |
 37 | 	public static let shared = MockURLProtocol()
    |                    |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockURLProtocol' 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
 38 |
 39 | 	//MARK: - Required URLProtocol API's
/Users/admin/builder/spi-builder-workspace/Sources/MockNetworking/MockURLProtocol.swift:104:21: warning: static property '_isRegistered' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
102 | 	//MARK: - Registration API's
103 |
104 | 	private static var _isRegistered = false
    |                     |- warning: static property '_isRegistered' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                     |- note: convert '_isRegistered' to a 'let' constant to make 'Sendable' shared state immutable
    |                     |- note: annotate '_isRegistered' 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
105 |
106 | 	/// Registers MockURLProtocol and sets the values that should be responded to the given URL.
/Users/admin/builder/spi-builder-workspace/Sources/MockNetworking/MockResponseStore.swift:22:13: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockResponseStore' may have shared mutable state; this is an error in the Swift 6 language mode
19 | ///
20 | /// This class is thread safe and will atomically read & update values.
21 | final class MockResponseStore {
   |             `- note: class 'MockResponseStore' does not conform to the 'Sendable' protocol
22 | 	static let shared = MockResponseStore()
   |             |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockResponseStore' 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
23 |
24 | 	// Actual backing store for the URL Responses.
[27/28] Compiling MockNetworking MockResponseStore.swift
/Users/admin/builder/spi-builder-workspace/Sources/MockNetworking/MockResponseStore.swift:22:13: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockResponseStore' may have shared mutable state; this is an error in the Swift 6 language mode
19 | ///
20 | /// This class is thread safe and will atomically read & update values.
21 | final class MockResponseStore {
   |             `- note: class 'MockResponseStore' does not conform to the 'Sendable' protocol
22 | 	static let shared = MockResponseStore()
   |             |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'MockResponseStore' 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
23 |
24 | 	// Actual backing store for the URL Responses.
[28/28] Compiling MockNetworking HTTPURLResponse.swift
Build complete! (17.90s)
Build complete.
{
  "dependencies" : [
    {
      "identity" : "konkyo",
      "requirement" : {
        "exact" : [
          "0.5.1"
        ]
      },
      "type" : "sourceControl",
      "url" : "https://github.com/Machx/Konkyo.git"
    }
  ],
  "manifest_display_name" : "MockNetworking",
  "name" : "MockNetworking",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
    {
      "name" : "macos",
      "version" : "14.0"
    },
    {
      "name" : "ios",
      "version" : "16.0"
    }
  ],
  "products" : [
    {
      "name" : "MockNetworking",
      "targets" : [
        "MockNetworking"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "MockNetworkingTests",
      "module_type" : "SwiftTarget",
      "name" : "MockNetworkingTests",
      "path" : "Tests/MockNetworkingTests",
      "sources" : [
        "MockNetworkingTests.swift"
      ],
      "target_dependencies" : [
        "MockNetworking"
      ],
      "type" : "test"
    },
    {
      "c99name" : "MockNetworking",
      "module_type" : "SwiftTarget",
      "name" : "MockNetworking",
      "path" : "Sources/MockNetworking",
      "product_dependencies" : [
        "Konkyo"
      ],
      "product_memberships" : [
        "MockNetworking"
      ],
      "sources" : [
        "Extensions/Dictionary.swift",
        "Extensions/HTTPURLResponse.swift",
        "Extensions/URLSession.swift",
        "MockPropertyResponse.swift",
        "MockResponseStore.swift",
        "MockURLProtocol.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.9"
}
Done.