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 CustomButton, reference v2.0.0 (1cd273), with Swift 6.0 for macOS (SPM) on 1 Nov 2024 07:14:20 UTC.

Swift 6 data race errors: 0

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

Build Log

========================================
RunAll
========================================
Builder version: 4.56.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/sindresorhus/CustomButton.git
Reference: v2.0.0
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/sindresorhus/CustomButton
 * tag               v2.0.0     -> FETCH_HEAD
HEAD is now at 1cd2732 Minor tweak
Cloned https://github.com/sindresorhus/CustomButton.git
Revision (git rev-parse @):
1cd273286636677c92dcccaeced4192b956cb503
SUCCESS checkout https://github.com/sindresorhus/CustomButton.git at v2.0.0
========================================
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": "custombutton",
      "name": "CustomButton",
      "url": "https://github.com/sindresorhus/CustomButton.git",
      "version": "unspecified",
      "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/CustomButton",
      "dependencies": [
      ]
    }
  ]
}
Fetching https://github.com/sindresorhus/CustomButton.git
[1/184] Fetching custombutton
Fetched https://github.com/sindresorhus/CustomButton.git from cache (0.94s)
Creating working copy for https://github.com/sindresorhus/CustomButton.git
Working copy of https://github.com/sindresorhus/CustomButton.git resolved at v2.0.0 (1cd2732)
warning: '.resolve-product-dependencies': dependency 'custombutton' 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/sindresorhus/CustomButton.git
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
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version--7754E27361AE5C74.txt
[3/5] Compiling CustomButton Utilities.swift
/Users/admin/builder/spi-builder-workspace/Sources/CustomButton/Utilities.swift:60:28: warning: main actor-isolated property 'bounds' can not be referenced from a nonisolated autoclosure; this is an error in the Swift 6 language mode
 58 | 	) {
 59 | 		self.view = view
 60 | 		self.rect = rect ?? view.bounds
    |                            `- warning: main actor-isolated property 'bounds' can not be referenced from a nonisolated autoclosure; this is an error in the Swift 6 language mode
 61 | 		self.options = options
 62 | 	}
AppKit.NSView:76:25: note: property declared here
 74 |     @available(swift, obsoleted: 3, renamed: "rotate(byDegrees:)")
 75 |     open func rotateByAngle(_ angle: CGFloat)
 76 |     @MainActor open var bounds: NSRect { get set }
    |                         `- note: property declared here
 77 |     open var isFlipped: Bool { get }
 78 |     @available(swift, obsoleted: 3, renamed: "isFlipped")
/Users/admin/builder/spi-builder-workspace/Sources/CustomButton/Utilities.swift:70:10: warning: call to main actor-isolated instance method 'removeTrackingArea' in a synchronous nonisolated context; this is an error in the Swift 6 language mode
 66 | 	- Note: This should be called in your `NSView#updateTrackingAreas()` method.
 67 | 	*/
 68 | 	func update() {
    |       `- note: add '@MainActor' to make instance method 'update()' part of global actor 'MainActor'
 69 | 		if let oldTrackingArea = trackingArea {
 70 | 			view?.removeTrackingArea(oldTrackingArea)
    |          `- warning: call to main actor-isolated instance method 'removeTrackingArea' in a synchronous nonisolated context; this is an error in the Swift 6 language mode
 71 | 		}
 72 |
AppKit.NSView:5:26: note: calls to instance method 'removeTrackingArea' from outside of its actor context are implicitly asynchronous
 3 |     @MainActor open func addTrackingArea(_ trackingArea: NSTrackingArea)
 4 |     @available(macOS 10.5, *)
 5 |     @MainActor open func removeTrackingArea(_ trackingArea: NSTrackingArea)
   |                          `- note: calls to instance method 'removeTrackingArea' from outside of its actor context are implicitly asynchronous
 6 |     @available(macOS 10.5, *)
 7 |     open var trackingAreas: [NSTrackingArea] { get }
/Users/admin/builder/spi-builder-workspace/Sources/CustomButton/Utilities.swift:83:9: warning: call to main actor-isolated instance method 'addTrackingArea' in a synchronous nonisolated context; this is an error in the Swift 6 language mode
 66 | 	- Note: This should be called in your `NSView#updateTrackingAreas()` method.
 67 | 	*/
 68 | 	func update() {
    |       `- note: add '@MainActor' to make instance method 'update()' part of global actor 'MainActor'
 69 | 		if let oldTrackingArea = trackingArea {
 70 | 			view?.removeTrackingArea(oldTrackingArea)
    :
 81 | 		)
 82 |
 83 | 		view?.addTrackingArea(newTrackingArea)
    |         `- warning: call to main actor-isolated instance method 'addTrackingArea' in a synchronous nonisolated context; this is an error in the Swift 6 language mode
 84 | 		trackingArea = newTrackingArea
 85 | 	}
AppKit.NSView:3:26: note: calls to instance method 'addTrackingArea' from outside of its actor context are implicitly asynchronous
 1 | extension NSView {
 2 |     @available(macOS 10.5, *)
 3 |     @MainActor open func addTrackingArea(_ trackingArea: NSTrackingArea)
   |                          `- note: calls to instance method 'addTrackingArea' from outside of its actor context are implicitly asynchronous
 4 |     @available(macOS 10.5, *)
 5 |     @MainActor open func removeTrackingArea(_ trackingArea: NSTrackingArea)
/Users/admin/builder/spi-builder-workspace/Sources/CustomButton/Utilities.swift:70:10: warning: sending 'oldTrackingArea' risks causing data races; this is an error in the Swift 6 language mode
 68 | 	func update() {
 69 | 		if let oldTrackingArea = trackingArea {
 70 | 			view?.removeTrackingArea(oldTrackingArea)
    |          |- warning: sending 'oldTrackingArea' risks causing data races; this is an error in the Swift 6 language mode
    |          `- note: sending task-isolated 'oldTrackingArea' to main actor-isolated instance method 'removeTrackingArea' risks causing data races between main actor-isolated and task-isolated uses
 71 | 		}
 72 |
/Users/admin/builder/spi-builder-workspace/Sources/CustomButton/Utilities.swift:83:9: warning: sending 'newTrackingArea' risks causing data races; this is an error in the Swift 6 language mode
 81 | 		)
 82 |
 83 | 		view?.addTrackingArea(newTrackingArea)
    |         |- warning: sending 'newTrackingArea' risks causing data races; this is an error in the Swift 6 language mode
    |         `- note: sending 'newTrackingArea' to main actor-isolated instance method 'addTrackingArea' risks causing data races between main actor-isolated and local nonisolated uses
 84 | 		trackingArea = newTrackingArea
    |                  `- note: access can happen concurrently
 85 | 	}
 86 | }
[4/5] Emitting module CustomButton
[5/5] Compiling CustomButton CustomButton.swift
Build complete! (7.36s)
Build complete.
{
  "dependencies" : [
  ],
  "manifest_display_name" : "CustomButton",
  "name" : "CustomButton",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
    {
      "name" : "macos",
      "version" : "10.12"
    }
  ],
  "products" : [
    {
      "name" : "CustomButton",
      "targets" : [
        "CustomButton"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "CustomButton",
      "module_type" : "SwiftTarget",
      "name" : "CustomButton",
      "path" : "Sources/CustomButton",
      "product_memberships" : [
        "CustomButton"
      ],
      "sources" : [
        "CustomButton.swift",
        "Utilities.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.2"
}
Done.