This is a staging environment. For live and up-to-date package information, visit swiftpackageindex.com.

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 YPersistence with Swift 6.0 for macOS (SPM).

Swift 6 data race errors: 1

Build Command

env DEVELOPER_DIR=/Applications/Xcode-15.3.0.app xcrun --toolchain org.swift.600202405261a swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete

Build Log

========================================
RunAll
========================================
Builder version: 4.40.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/codeandtheory/ypersistence-ios.git
Reference: main
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/codeandtheory/ypersistence-ios
 * branch            main       -> FETCH_HEAD
 * [new branch]      main       -> origin/main
HEAD is now at 7de3f7c [1346] Mark functionality for records (#14)
Cloned https://github.com/codeandtheory/ypersistence-ios.git
Revision (git rev-parse @):
7de3f7c4ef82dabd8db12406cfb5b7c004caef45
SPI manifest file found: $workDir/.spi.yml
SUCCESS checkout https://github.com/codeandtheory/ypersistence-ios.git at main
========================================
Build
========================================
Selected platform:         macosSpm
Swift version:             6.0
Building package at path:  $workDir
https://github.com/codeandtheory/ypersistence-ios.git
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-15.3.0.app xcrun --toolchain org.swift.600202405261a swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-6F35C1178C84523A.txt
[3/20] Compiling YPersistence ModelRepresentable.swift
[4/20] Compiling YPersistence RecordFromModel.swift
[5/21] Compiling YPersistence RecordToModel.swift
[6/21] Compiling YPersistence SyncRecord.swift
[7/21] Compiling YPersistence SortColumn.swift
[8/21] Compiling YPersistence PersistenceManager+Fetch.swift
[9/21] Compiling YPersistence PersistenceManager+Save.swift
[10/21] Compiling YPersistence PersistenceManager+Sync.swift
/Users/admin/builder/spi-builder-workspace/Sources/YPersistence/Manager/PersistenceManager.swift:25:61: warning: reference to var 'NSErrorMergePolicy' is not concurrency-safe because it involves shared mutable state; this is an error in the Swift 6 language mode
 23 |     ///   - mergePolicy: The merge policy to use for each context. Default = `NSErrorMergePolicy`.
 24 |     ///   It is the only policy that requires action to correct any potential conflicts.
 25 |     public init(modelName: String, mergePolicy: AnyObject = NSErrorMergePolicy, bundle: Bundle = .main) {
    |                                                             `- warning: reference to var 'NSErrorMergePolicy' is not concurrency-safe because it involves shared mutable state; this is an error in the Swift 6 language mode
 26 |         guard let model = NSManagedObjectModel(from: modelName, in: bundle) else {
 27 |             preconditionFailure("There must be a valid Core Data model.")
CoreData.NSErrorMergePolicy:2:12: note: var declared here
1 | @available(macOS 10.4, *)
2 | public var NSErrorMergePolicy: AnyObject
  |            `- note: var declared here
[11/21] Compiling YPersistence PersistenceManager.swift
/Users/admin/builder/spi-builder-workspace/Sources/YPersistence/Manager/PersistenceManager.swift:25:61: warning: reference to var 'NSErrorMergePolicy' is not concurrency-safe because it involves shared mutable state; this is an error in the Swift 6 language mode
 23 |     ///   - mergePolicy: The merge policy to use for each context. Default = `NSErrorMergePolicy`.
 24 |     ///   It is the only policy that requires action to correct any potential conflicts.
 25 |     public init(modelName: String, mergePolicy: AnyObject = NSErrorMergePolicy, bundle: Bundle = .main) {
    |                                                             `- warning: reference to var 'NSErrorMergePolicy' is not concurrency-safe because it involves shared mutable state; this is an error in the Swift 6 language mode
 26 |         guard let model = NSManagedObjectModel(from: modelName, in: bundle) else {
 27 |             preconditionFailure("There must be a valid Core Data model.")
CoreData.NSErrorMergePolicy:2:12: note: var declared here
1 | @available(macOS 10.4, *)
2 | public var NSErrorMergePolicy: AnyObject
  |            `- note: var declared here
[12/21] Compiling YPersistence CoreModel.swift
[13/21] Compiling YPersistence DataRecord.swift
[14/21] Compiling YPersistence SortInfo.swift
[15/21] Compiling YPersistence DispatchQueue+executeOnMain.swift
/Users/admin/builder/spi-builder-workspace/Sources/YPersistence/Extensions/DispatchQueue+executeOnMain.swift:24:40: warning: capture of 'work' with non-sendable type '@convention(block) () -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
22 |         } else {
23 |             // If we're not on main, then run it asynchronously on main
24 |             DispatchQueue.main.async { work() }
   |                                        |- warning: capture of 'work' with non-sendable type '@convention(block) () -> 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'
25 |         }
26 |     }
/Users/admin/builder/spi-builder-workspace/Sources/YPersistence/Extensions/DispatchQueue+executeOnMain.swift:24:40: warning: sending 'work' risks causing data races; this is an error in the Swift 6 language mode
22 |         } else {
23 |             // If we're not on main, then run it asynchronously on main
24 |             DispatchQueue.main.async { work() }
   |                                        |- warning: sending 'work' risks causing data races; this is an error in the Swift 6 language mode
   |                                        `- note: task-isolated 'work' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
25 |         }
26 |     }
[16/21] Compiling YPersistence NSManagedObjectContext+SaveChanges.swift
/Users/admin/builder/spi-builder-workspace/Sources/YPersistence/Extensions/DispatchQueue+executeOnMain.swift:24:40: warning: capture of 'work' with non-sendable type '@convention(block) () -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
22 |         } else {
23 |             // If we're not on main, then run it asynchronously on main
24 |             DispatchQueue.main.async { work() }
   |                                        |- warning: capture of 'work' with non-sendable type '@convention(block) () -> 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'
25 |         }
26 |     }
/Users/admin/builder/spi-builder-workspace/Sources/YPersistence/Extensions/DispatchQueue+executeOnMain.swift:24:40: warning: sending 'work' risks causing data races; this is an error in the Swift 6 language mode
22 |         } else {
23 |             // If we're not on main, then run it asynchronously on main
24 |             DispatchQueue.main.async { work() }
   |                                        |- warning: sending 'work' risks causing data races; this is an error in the Swift 6 language mode
   |                                        `- note: task-isolated 'work' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
25 |         }
26 |     }
[17/21] Compiling YPersistence PersistenceManager+Clear.swift
[18/21] Compiling YPersistence PersistenceManager+Delete.swift
[19/21] Emitting module YPersistence
/Users/admin/builder/spi-builder-workspace/Sources/YPersistence/Manager/PersistenceManager.swift:25:61: warning: reference to var 'NSErrorMergePolicy' is not concurrency-safe because it involves shared mutable state; this is an error in the Swift 6 language mode
 23 |     ///   - mergePolicy: The merge policy to use for each context. Default = `NSErrorMergePolicy`.
 24 |     ///   It is the only policy that requires action to correct any potential conflicts.
 25 |     public init(modelName: String, mergePolicy: AnyObject = NSErrorMergePolicy, bundle: Bundle = .main) {
    |                                                             `- warning: reference to var 'NSErrorMergePolicy' is not concurrency-safe because it involves shared mutable state; this is an error in the Swift 6 language mode
 26 |         guard let model = NSManagedObjectModel(from: modelName, in: bundle) else {
 27 |             preconditionFailure("There must be a valid Core Data model.")
CoreData.NSErrorMergePolicy:2:12: note: var declared here
1 | @available(macOS 10.4, *)
2 | public var NSErrorMergePolicy: AnyObject
  |            `- note: var declared here
[20/21] Compiling YPersistence NSManagedObjectModel+init.swift
[21/21] Compiling YPersistence PersistenceManager+BulkDelete.swift
Build complete! (20.89s)
Build complete.
{
  "dependencies" : [
  ],
  "manifest_display_name" : "YPersistence",
  "name" : "YPersistence",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
  ],
  "products" : [
    {
      "name" : "YPersistence",
      "targets" : [
        "YPersistence"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "YPersistenceTests",
      "module_type" : "SwiftTarget",
      "name" : "YPersistenceTests",
      "path" : "Tests/YPersistenceTests",
      "sources" : [
        "DataModel/Human/ManagedFruit.swift",
        "DataModel/Human/ManagedGroceryProduct.swift",
        "DataModel/Machine/_ManagedFruit.swift",
        "DataModel/Machine/_ManagedGroceryProduct.swift",
        "DataModel/Mocks/Fruit.swift",
        "DataModel/Mocks/GroceryProduct.swift",
        "Extensions/DispatchQueue+executeOnMainTests.swift",
        "Extensions/NSManagedObjectContext+SaveChangesTests.swift",
        "Extensions/NSManagedObjectModel+initTests.swift",
        "Manager/PersistenceManager+BulkDeleteTests.swift",
        "Manager/PersistenceManager+ClearTests.swift",
        "Manager/PersistenceManager+DeleteTests.swift",
        "Manager/PersistenceManager+FetchTests.swift",
        "Manager/PersistenceManager+SaveTests.swift",
        "Manager/PersistenceManager+SyncTests.swift",
        "Manager/PersistenceManagerBaseTests.swift",
        "Manager/PersistenceManagerTests.swift",
        "Protocols/DataRecordTests.swift",
        "Protocols/SyncRecordTests.swift",
        "SortColumnTests.swift",
        "SortInfoTests.swift"
      ],
      "target_dependencies" : [
        "YPersistence"
      ],
      "type" : "test"
    },
    {
      "c99name" : "YPersistence",
      "module_type" : "SwiftTarget",
      "name" : "YPersistence",
      "path" : "Sources/YPersistence",
      "product_memberships" : [
        "YPersistence"
      ],
      "sources" : [
        "Extensions/DispatchQueue+executeOnMain.swift",
        "Extensions/NSManagedObjectContext+SaveChanges.swift",
        "Extensions/NSManagedObjectModel+init.swift",
        "Manager/PersistenceManager+BulkDelete.swift",
        "Manager/PersistenceManager+Clear.swift",
        "Manager/PersistenceManager+Delete.swift",
        "Manager/PersistenceManager+Fetch.swift",
        "Manager/PersistenceManager+Save.swift",
        "Manager/PersistenceManager+Sync.swift",
        "Manager/PersistenceManager.swift",
        "Protocols/CoreModel.swift",
        "Protocols/DataRecord.swift",
        "Protocols/ModelRepresentable.swift",
        "Protocols/RecordFromModel.swift",
        "Protocols/RecordToModel.swift",
        "Protocols/SyncRecord.swift",
        "SortColumn.swift",
        "SortInfo.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.5"
}
Done.
This is a staging environment. For live and up-to-date package information, visit swiftpackageindex.com.