Build Information
Successful build of DSFToggleButton, reference master (434fab
), with Swift 6.1 for macOS (SPM) on 29 Apr 2025 04:19:06 UTC.
Swift 6 data race errors: 2
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/dagronf/DSFToggleButton.git
Reference: master
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/dagronf/DSFToggleButton
* branch master -> FETCH_HEAD
* [new branch] master -> origin/master
HEAD is now at 434fab2 Update copyright
Cloned https://github.com/dagronf/DSFToggleButton.git
Revision (git rev-parse @):
434fab25cde1d9876350107a5edb1825a8e29fda
SPI manifest file found: $PWD/.spi.yml
SUCCESS checkout https://github.com/dagronf/DSFToggleButton.git at master
Fetching https://github.com/dagronf/DSFAppearanceManager
[1/459] Fetching dsfappearancemanager
Fetched https://github.com/dagronf/DSFAppearanceManager from cache (0.97s)
Computing version for https://github.com/dagronf/DSFAppearanceManager
Computed https://github.com/dagronf/DSFAppearanceManager at 3.5.1 (1.54s)
Creating working copy for https://github.com/dagronf/DSFAppearanceManager
Working copy of https://github.com/dagronf/DSFAppearanceManager resolved at 3.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": "dsftogglebutton",
"name": "DSFToggleButton",
"url": "https://github.com/dagronf/DSFToggleButton.git",
"version": "unspecified",
"path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/DSFToggleButton",
"dependencies": [
{
"identity": "dsfappearancemanager",
"name": "DSFAppearanceManager",
"url": "https://github.com/dagronf/DSFAppearanceManager",
"version": "3.5.1",
"path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/DSFAppearanceManager",
"dependencies": [
]
}
]
}
]
}
Fetching https://github.com/dagronf/DSFToggleButton.git
[1/494] Fetching dsftogglebutton
Fetched https://github.com/dagronf/DSFToggleButton.git from cache (0.73s)
Fetching https://github.com/dagronf/DSFAppearanceManager from cache
Fetched https://github.com/dagronf/DSFAppearanceManager from cache (0.39s)
Computing version for https://github.com/dagronf/DSFAppearanceManager
Computed https://github.com/dagronf/DSFAppearanceManager at 3.5.1 (0.44s)
Creating working copy for https://github.com/dagronf/DSFToggleButton.git
Working copy of https://github.com/dagronf/DSFToggleButton.git resolved at master (434fab2)
Creating working copy for https://github.com/dagronf/DSFAppearanceManager
Working copy of https://github.com/dagronf/DSFAppearanceManager resolved at 3.5.1
warning: '.resolve-product-dependencies': dependency 'dsftogglebutton' is not used by any target
Found 1 product dependencies
- DSFAppearanceManager
========================================
Build
========================================
Selected platform: macosSpm
Swift version: 6.1
Building package at path: $PWD
https://github.com/dagronf/DSFToggleButton.git
https://github.com/dagronf/DSFToggleButton.git
{
"dependencies" : [
{
"identity" : "dsfappearancemanager",
"requirement" : {
"range" : [
{
"lower_bound" : "3.5.0",
"upper_bound" : "3.6.0"
}
]
},
"type" : "sourceControl",
"url" : "https://github.com/dagronf/DSFAppearanceManager"
}
],
"manifest_display_name" : "DSFToggleButton",
"name" : "DSFToggleButton",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
{
"name" : "macos",
"version" : "10.13"
}
],
"products" : [
{
"name" : "DSFToggleButton",
"targets" : [
"DSFToggleButton"
],
"type" : {
"library" : [
"automatic"
]
}
},
{
"name" : "DSFToggleButton-static",
"targets" : [
"DSFToggleButton"
],
"type" : {
"library" : [
"static"
]
}
},
{
"name" : "DSFToggleButton-shared",
"targets" : [
"DSFToggleButton"
],
"type" : {
"library" : [
"dynamic"
]
}
}
],
"targets" : [
{
"c99name" : "DSFToggleButtonTests",
"module_type" : "SwiftTarget",
"name" : "DSFToggleButtonTests",
"path" : "Tests/DSFToggleButtonTests",
"sources" : [
"DSFToggleButtonTests.swift"
],
"target_dependencies" : [
"DSFToggleButton"
],
"type" : "test"
},
{
"c99name" : "DSFToggleButton",
"module_type" : "SwiftTarget",
"name" : "DSFToggleButton",
"path" : "Sources/DSFToggleButton",
"product_dependencies" : [
"DSFAppearanceManager"
],
"product_memberships" : [
"DSFToggleButton",
"DSFToggleButton-static",
"DSFToggleButton-shared"
],
"sources" : [
"DSFToggleButton+SwiftUI.swift",
"DSFToggleButton+extensions.swift",
"DSFToggleButton.swift"
],
"type" : "library"
}
],
"tools_version" : "5.4"
}
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/7] Write sources
[2/7] Write swift-version-2F0A5646E1D333AE.txt
[4/19] Compiling DSFAppearanceManager DSFDebounce.swift
[5/20] Compiling DSFAppearanceManager WeakBox.swift
[6/20] Compiling DSFAppearanceManager NSWindow+Appearance.swift
[7/20] Compiling DSFAppearanceManager DSFSimpleLock.swift
[8/20] Compiling DSFAppearanceManager WeakBag.swift
[9/20] Compiling DSFAppearanceManager NSAppearance+extensions.swift
[10/20] Compiling DSFAppearanceManager AutoplayAnimatedImages.swift
[11/20] Compiling DSFAppearanceManager DSFAppearanceManager+Listeners.swift
[12/20] Compiling DSFAppearanceManager DSFAppearanceCache.swift
[13/20] Compiling DSFAppearanceManager DSFAppearanceManager+ChangeDetector.swift
[14/20] Compiling DSFAppearanceManager DSFAppearanceManager.swift
[15/20] Compiling DSFAppearanceManager NSView+Appearance.swift
[16/20] Emitting module DSFAppearanceManager
[17/24] Compiling DSFToggleButton DSFToggleButton.swift
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton.swift:241:14: warning: main actor-isolated instance method 'appearanceDidChange()' cannot be used to satisfy nonisolated requirement from protocol 'DSFAppearanceCacheNotifiable'; this is an error in the Swift 6 language mode
191 | }
192 |
193 | extension DSFToggleButton: DSFAppearanceCacheNotifiable {
| `- note: add '@preconcurrency' to the 'DSFAppearanceCacheNotifiable' conformance to defer isolation checking to run time
194 | private func setup() {
195 | self.wantsLayer = true
:
239 | }
240 |
241 | public func appearanceDidChange() {
| |- warning: main actor-isolated instance method 'appearanceDidChange()' cannot be used to satisfy nonisolated requirement from protocol 'DSFAppearanceCacheNotifiable'; this is an error in the Swift 6 language mode
| `- note: add 'nonisolated' to 'appearanceDidChange()' to make this instance method not isolated to the actor
242 | self.configureForCurrentState(animated: false)
243 | }
/Users/admin/builder/spi-builder-workspace/.build/checkouts/DSFAppearanceManager/Sources/DSFAppearanceManager/DSFAppearanceCache.swift:38:13: note: mark the protocol requirement 'appearanceDidChange()' 'async' to allow actor-isolated conformances
36 | /// A protocol for receiving appearance notifications
37 | @objc public protocol DSFAppearanceCacheNotifiable: NSObjectProtocol {
38 | @objc func appearanceDidChange()
| `- note: mark the protocol requirement 'appearanceDidChange()' 'async' to allow actor-isolated conformances
39 | }
40 |
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton.swift:172:8: warning: main actor-isolated property 'cell' can not be referenced from a nonisolated context; this is an error in the Swift 6 language mode
170 | DSFAppearanceCache.shared.deregister(self)
171 | self.stateChangeBlock = nil
172 | self.cell?.unbind(.value)
| `- warning: main actor-isolated property 'cell' can not be referenced from a nonisolated context; this is an error in the Swift 6 language mode
173 | }
174 |
/Applications/Xcode-16.3.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSControl.h:129:47: note: property declared here
127 | @property (class, nullable) Class cellClass;
128 |
129 | @property (nullable, strong) __kindof NSCell *cell;
| `- note: property declared here
130 |
131 | - (nullable __kindof NSCell *)selectedCell;
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton.swift:234:9: warning: call to main actor-isolated instance method 'rebuildLayers()' in a synchronous nonisolated context; this is an error in the Swift 6 language mode
232 | }
233 | CATransaction.setDisableActions(true)
234 | self.rebuildLayers()
| `- warning: call to main actor-isolated instance method 'rebuildLayers()' in a synchronous nonisolated context; this is an error in the Swift 6 language mode
235 | self.needsDisplay = true
236 | }
:
306 | #endif
307 |
308 | private func rebuildLayers() {
| |- note: calls to instance method 'rebuildLayers()' from outside of its actor context are implicitly asynchronous
| `- note: main actor isolation inferred from inheritance from class 'NSButton'
309 | // LAYERS:
310 | // Lowest
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton.swift:235:9: warning: main actor-isolated property 'needsDisplay' can not be mutated from a Sendable closure; this is an error in the Swift 6 language mode
233 | CATransaction.setDisableActions(true)
234 | self.rebuildLayers()
235 | self.needsDisplay = true
| `- warning: main actor-isolated property 'needsDisplay' can not be mutated from a Sendable closure; this is an error in the Swift 6 language mode
236 | }
237 |
/Applications/Xcode-16.3.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.4.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSView.h:187:16: note: mutation of this property is only permitted within the actor
185 | @property (readonly) BOOL canDraw API_DEPRECATED("If a view needs display, -drawRect: or -updateLayer will be called automatically when the view is able to draw. To check whether a view is in a window, call -window. To check whether a view is hidden, call -isHiddenOrHasHiddenAncestor.", macos(10.0,10.14));
186 | - (void)setNeedsDisplayInRect:(NSRect)invalidRect;
187 | @property BOOL needsDisplay;
| `- note: mutation of this property is only permitted within the actor
188 | - (void)lockFocus API_DEPRECATED("To draw, subclass NSView and implement -drawRect:; AppKit's automatic deferred display mechanism will call -drawRect: as necessary to display the view.", macos(10.0,10.14));
189 | - (void)unlockFocus API_DEPRECATED("To draw, subclass NSView and implement -drawRect:; AppKit's automatic deferred display mechanism will call -drawRect: as necessary to display the view.", macos(10.0,10.14));
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton.swift:259:8: warning: call to main actor-isolated instance method 'setup()' in a synchronous nonisolated context; this is an error in the Swift 6 language mode
192 |
193 | extension DSFToggleButton: DSFAppearanceCacheNotifiable {
194 | private func setup() {
| |- note: calls to instance method 'setup()' from outside of its actor context are implicitly asynchronous
| `- note: main actor isolation inferred from inheritance from class 'NSButton'
195 | self.wantsLayer = true
196 |
:
257 | public extension DSFToggleButton {
258 | override func prepareForInterfaceBuilder() {
259 | self.setup()
| `- warning: call to main actor-isolated instance method 'setup()' in a synchronous nonisolated context; this is an error in the Swift 6 language mode
260 | }
261 |
<unknown>:0: note: a function type must be marked '@Sendable' to conform to 'Sendable'
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton.swift:171:25: warning: cannot access property 'stateChangeBlock' with a non-sendable type '((DSFToggleButton) -> Void)?' from nonisolated deinit; this is an error in the Swift 6 language mode
169 | deinit {
170 | DSFAppearanceCache.shared.deregister(self)
171 | self.stateChangeBlock = nil
| `- warning: cannot access property 'stateChangeBlock' with a non-sendable type '((DSFToggleButton) -> Void)?' from nonisolated deinit; this is an error in the Swift 6 language mode
172 | self.cell?.unbind(.value)
173 | }
[18/24] Compiling DSFToggleButton DSFToggleButton+extensions.swift
[19/24] Compiling DSFToggleButton DSFToggleButton+SwiftUI.swift
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton+SwiftUI.swift:87:44: warning: cannot form key path to main actor-isolated property 'state'; this is an error in the Swift 6 language mode
85 | var button: DSFToggleButton? {
86 | didSet {
87 | self.observer = self.button?.observe(\.state, options: [.new], changeHandler: { [weak self] obj, change in
| `- warning: cannot form key path to main actor-isolated property 'state'; this is an error in the Swift 6 language mode
88 | self?.parent.stateChanged?(change.newValue ?? .off)
89 | })
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton+SwiftUI.swift:88:6: warning: capture of 'self' with non-sendable type 'DSFToggleButton.SwiftUI.Coordinator?' in a '@Sendable' closure
80 | @available(macOS 11, *)
81 | public extension DSFToggleButton.SwiftUI {
82 | class Coordinator: NSObject {
| `- note: class 'Coordinator' does not conform to the 'Sendable' protocol
83 | let parent: DSFToggleButton.SwiftUI
84 | var observer: NSKeyValueObservation?
:
86 | didSet {
87 | self.observer = self.button?.observe(\.state, options: [.new], changeHandler: { [weak self] obj, change in
88 | self?.parent.stateChanged?(change.newValue ?? .off)
| `- warning: capture of 'self' with non-sendable type 'DSFToggleButton.SwiftUI.Coordinator?' in a '@Sendable' closure
89 | })
90 | }
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton+SwiftUI.swift:99:17: warning: main actor-isolated property 'target' can not be mutated from a nonisolated context; this is an error in the Swift 6 language mode
97 | deinit {
98 | self.observer = nil
99 | self.button?.target = nil
| `- warning: main actor-isolated property 'target' can not be mutated from a nonisolated context; this is an error in the Swift 6 language mode
100 | }
101 |
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton.swift:140:28: note: mutation of this property is only permitted within the actor
138 |
139 | private weak var _target: AnyObject?
140 | @objc override public var target: AnyObject? {
| `- note: mutation of this property is only permitted within the actor
141 | didSet {
142 | self.twiddleTarget()
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton+SwiftUI.swift:103:30: warning: main actor-isolated property 'state' can not be referenced from a nonisolated context; this is an error in the Swift 6 language mode
100 | }
101 |
102 | @objc func buttonPressed(_ sender: AnyObject) {
| `- note: add '@MainActor' to make instance method 'buttonPressed' part of global actor 'MainActor'
103 | let newVal = self.button?.state ?? .off
| `- warning: main actor-isolated property 'state' can not be referenced from a nonisolated context; this is an error in the Swift 6 language mode
104 |
105 | // Update our internal state so that it's reflected up through the binding
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton.swift:103:28: note: property declared here
101 |
102 | // `didSet` is called when the user programatically changes the state
103 | @objc override public var state: NSControl.StateValue {
| `- note: property declared here
104 | didSet {
105 | self.configureForCurrentState(animated: true)
[20/24] Emitting module DSFToggleButton
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton+SwiftUI.swift:87:44: warning: cannot form key path to main actor-isolated property 'state'; this is an error in the Swift 6 language mode
85 | var button: DSFToggleButton? {
86 | didSet {
87 | self.observer = self.button?.observe(\.state, options: [.new], changeHandler: { [weak self] obj, change in
| `- warning: cannot form key path to main actor-isolated property 'state'; this is an error in the Swift 6 language mode
88 | self?.parent.stateChanged?(change.newValue ?? .off)
89 | })
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton+SwiftUI.swift:88:6: warning: capture of 'self' with non-sendable type 'DSFToggleButton.SwiftUI.Coordinator?' in a '@Sendable' closure
80 | @available(macOS 11, *)
81 | public extension DSFToggleButton.SwiftUI {
82 | class Coordinator: NSObject {
| `- note: class 'Coordinator' does not conform to the 'Sendable' protocol
83 | let parent: DSFToggleButton.SwiftUI
84 | var observer: NSKeyValueObservation?
:
86 | didSet {
87 | self.observer = self.button?.observe(\.state, options: [.new], changeHandler: { [weak self] obj, change in
88 | self?.parent.stateChanged?(change.newValue ?? .off)
| `- warning: capture of 'self' with non-sendable type 'DSFToggleButton.SwiftUI.Coordinator?' in a '@Sendable' closure
89 | })
90 | }
/Users/admin/builder/spi-builder-workspace/Sources/DSFToggleButton/DSFToggleButton.swift:241:14: warning: main actor-isolated instance method 'appearanceDidChange()' cannot be used to satisfy nonisolated requirement from protocol 'DSFAppearanceCacheNotifiable'; this is an error in the Swift 6 language mode
191 | }
192 |
193 | extension DSFToggleButton: DSFAppearanceCacheNotifiable {
| `- note: add '@preconcurrency' to the 'DSFAppearanceCacheNotifiable' conformance to defer isolation checking to run time
194 | private func setup() {
195 | self.wantsLayer = true
:
239 | }
240 |
241 | public func appearanceDidChange() {
| |- warning: main actor-isolated instance method 'appearanceDidChange()' cannot be used to satisfy nonisolated requirement from protocol 'DSFAppearanceCacheNotifiable'; this is an error in the Swift 6 language mode
| `- note: add 'nonisolated' to 'appearanceDidChange()' to make this instance method not isolated to the actor
242 | self.configureForCurrentState(animated: false)
243 | }
/Users/admin/builder/spi-builder-workspace/.build/checkouts/DSFAppearanceManager/Sources/DSFAppearanceManager/DSFAppearanceCache.swift:38:13: note: mark the protocol requirement 'appearanceDidChange()' 'async' to allow actor-isolated conformances
36 | /// A protocol for receiving appearance notifications
37 | @objc public protocol DSFAppearanceCacheNotifiable: NSObjectProtocol {
38 | @objc func appearanceDidChange()
| `- note: mark the protocol requirement 'appearanceDidChange()' 'async' to allow actor-isolated conformances
39 | }
40 |
[20/24] Write Objects.LinkFileList
[22/24] Archiving libDSFToggleButton-static.a
[23/24] Linking libDSFToggleButton-shared.dylib
Build complete! (10.62s)
Build complete.
{
"dependencies" : [
{
"identity" : "dsfappearancemanager",
"requirement" : {
"range" : [
{
"lower_bound" : "3.5.0",
"upper_bound" : "3.6.0"
}
]
},
"type" : "sourceControl",
"url" : "https://github.com/dagronf/DSFAppearanceManager"
}
],
"manifest_display_name" : "DSFToggleButton",
"name" : "DSFToggleButton",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
{
"name" : "macos",
"version" : "10.13"
}
],
"products" : [
{
"name" : "DSFToggleButton",
"targets" : [
"DSFToggleButton"
],
"type" : {
"library" : [
"automatic"
]
}
},
{
"name" : "DSFToggleButton-static",
"targets" : [
"DSFToggleButton"
],
"type" : {
"library" : [
"static"
]
}
},
{
"name" : "DSFToggleButton-shared",
"targets" : [
"DSFToggleButton"
],
"type" : {
"library" : [
"dynamic"
]
}
}
],
"targets" : [
{
"c99name" : "DSFToggleButtonTests",
"module_type" : "SwiftTarget",
"name" : "DSFToggleButtonTests",
"path" : "Tests/DSFToggleButtonTests",
"sources" : [
"DSFToggleButtonTests.swift"
],
"target_dependencies" : [
"DSFToggleButton"
],
"type" : "test"
},
{
"c99name" : "DSFToggleButton",
"module_type" : "SwiftTarget",
"name" : "DSFToggleButton",
"path" : "Sources/DSFToggleButton",
"product_dependencies" : [
"DSFAppearanceManager"
],
"product_memberships" : [
"DSFToggleButton",
"DSFToggleButton-static",
"DSFToggleButton-shared"
],
"sources" : [
"DSFToggleButton+SwiftUI.swift",
"DSFToggleButton+extensions.swift",
"DSFToggleButton.swift"
],
"type" : "library"
}
],
"tools_version" : "5.4"
}
Done.