Build Information
Successful build of TypedNotificationCenter, reference 2.1.2 (6e682f
), with Swift 6.1 for macOS (SPM) on 27 Apr 2025 09:50:56 UTC.
Swift 6 data race errors: 4
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/cyberbeni/typednotificationcenter.git
Reference: 2.1.2
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/cyberbeni/typednotificationcenter
* tag 2.1.2 -> FETCH_HEAD
HEAD is now at 6e682f9 Merge pull request #70 from Cyberbeni/xcframework-script-finetune
Cloned https://github.com/cyberbeni/typednotificationcenter.git
Revision (git rev-parse @):
6e682f918c89cc769218e4f41059d3cea6ea7e14
SUCCESS checkout https://github.com/cyberbeni/typednotificationcenter.git at 2.1.2
========================================
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": "typednotificationcenter",
"name": "TypedNotificationCenter",
"url": "https://github.com/cyberbeni/typednotificationcenter.git",
"version": "unspecified",
"path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/typednotificationcenter",
"dependencies": [
]
}
]
}
Fetching https://github.com/cyberbeni/typednotificationcenter.git
[1/2979] Fetching typednotificationcenter
Fetched https://github.com/cyberbeni/typednotificationcenter.git from cache (0.91s)
Creating working copy for https://github.com/cyberbeni/typednotificationcenter.git
Working copy of https://github.com/cyberbeni/typednotificationcenter.git resolved at 2.1.2 (6e682f9)
warning: '.resolve-product-dependencies': dependency 'typednotificationcenter' 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/cyberbeni/typednotificationcenter.git
https://github.com/cyberbeni/typednotificationcenter.git
{
"dependencies" : [
],
"manifest_display_name" : "TypedNotificationCenter",
"name" : "TypedNotificationCenter",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
{
"name" : "macos",
"version" : "10.13"
},
{
"name" : "ios",
"version" : "11.0"
},
{
"name" : "watchos",
"version" : "4.0"
},
{
"name" : "tvos",
"version" : "11.0"
}
],
"products" : [
{
"name" : "TypedNotificationCenter",
"targets" : [
"TypedNotificationCenter"
],
"type" : {
"library" : [
"automatic"
]
}
}
],
"targets" : [
{
"c99name" : "TypedNotificationCenterTests",
"module_type" : "SwiftTarget",
"name" : "TypedNotificationCenterTests",
"path" : "Tests/TypedNotificationCenterTests",
"sources" : [
"Bridged Notification tests/BridgedNotificationApiTests.swift",
"Bridged Notification tests/BridgedNotificationInternalTests.swift",
"Bridged Notification tests/NotificationNameApiTests.swift",
"Bridged Notification tests/Utility/SampleBridgedNotification.swift",
"Core tests/ApiTests.swift",
"Core tests/AsyncApiTests.swift",
"Core tests/Utility/SampleNotification.swift",
"Internal tests/InternalTests.swift",
"Utility/TestCase.swift",
"Utility/XCTestCase+Utils.swift"
],
"target_dependencies" : [
"TypedNotificationCenter"
],
"type" : "test"
},
{
"c99name" : "TypedNotificationCenterPerformanceTests",
"module_type" : "SwiftTarget",
"name" : "TypedNotificationCenterPerformanceTests",
"path" : "Tests/TypedNotificationCenterPerformanceTests",
"sources" : [
"BridgedNotification.swift",
"Posting.swift",
"Subscribing.swift",
"Unsubscribing.swift",
"Utility/PerformanceTestNotifications.swift",
"Utility/TestCase.swift"
],
"target_dependencies" : [
"TypedNotificationCenter"
],
"type" : "test"
},
{
"c99name" : "TypedNotificationCenter",
"module_type" : "SwiftTarget",
"name" : "TypedNotificationCenter",
"path" : "Sources/TypedNotificationCenter",
"product_memberships" : [
"TypedNotificationCenter"
],
"sources" : [
"BridgedNotifications/Core/BridgedNotification+ErrorHandlingCustomization.swift",
"BridgedNotifications/Core/BridgedNotification.swift",
"BridgedNotifications/Core/TypedNotificationCenter+BridgedNotification.swift",
"BridgedNotifications/Core/TypedNotificationObservation+NsNotification.swift",
"BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift",
"BridgedNotifications/GenericBridgedNotification/TypedNotificationObservation+GenericBridgedNotification.swift",
"BridgedNotifications/GenericBridgedNotification/TypedNotificationObservation+GenericNsNotification.swift",
"BridgedNotifications/PDFKit/PDFView.swift",
"BridgedNotifications/UIKit/UIResponder.swift",
"Core/TypeErasure/AnyPayloadTypedNotification.swift",
"Core/TypeErasure/AnyTypedNotification.swift",
"Core/TypeErasure/SameTypedNotification.swift",
"Core/TypedNotification.swift",
"Core/TypedNotificationCenter.swift",
"Core/TypedNotificationObservation.swift",
"Core/WeakBox.swift"
],
"type" : "library"
}
],
"tools_version" : "5.7"
}
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/18] Compiling TypedNotificationCenter TypedNotificationObservation.swift
[4/19] Compiling TypedNotificationCenter AnyTypedNotification.swift
[5/19] Compiling TypedNotificationCenter SameTypedNotification.swift
[6/19] Compiling TypedNotificationCenter TypedNotificationCenter.swift
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:127:20: warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'TypedNotificationCenter' may have shared mutable state; this is an error in the Swift 6 language mode
30 | typealias SenderIdentifier = ObjectIdentifier
31 |
32 | public final class TypedNotificationCenter {
| `- note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
33 | let observerLock = NSLock()
34 | var observers = [NotificationIdentifier: [SenderIdentifier: [ObjectIdentifier: WeakBox<AnyObject>]]]()
:
125 | }
126 |
127 | public static let `default` = TypedNotificationCenter()
| |- warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'TypedNotificationCenter' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: add '@MainActor' to make static property 'default' part of global actor 'MainActor'
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
128 |
129 | public func observe<T: TypedNotification>(_: T.Type, object: T.Sender?, queue: OperationQueue? = nil, block: @escaping T.ObservationBlock) -> TypedNotificationObservation {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:99:6: warning: capture of 'block' with non-sendable type '(T.Sender, T.Payload) -> Void' in a '@Sendable' closure
97 | {
98 | queue.addOperation {
99 | block(sender, payload)
| |- warning: capture of 'block' with non-sendable type '(T.Sender, T.Payload) -> Void' in a '@Sendable' closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
100 | }
101 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:99:12: warning: capture of 'sender' with non-sendable type 'T.Sender' in a '@Sendable' closure
97 | {
98 | queue.addOperation {
99 | block(sender, payload)
| `- warning: capture of 'sender' with non-sendable type 'T.Sender' in a '@Sendable' closure
100 | }
101 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:99:20: warning: capture of 'payload' with non-sendable type 'T.Payload' in a '@Sendable' closure
97 | {
98 | queue.addOperation {
99 | block(sender, payload)
| `- warning: capture of 'payload' with non-sendable type 'T.Payload' in a '@Sendable' closure
100 | }
101 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:113:6: warning: capture of 'block' with non-sendable type '(T.Sender, T.Payload) -> Void' in a '@Sendable' closure
111 | {
112 | queue.addOperation {
113 | block(sender, payload)
| |- warning: capture of 'block' with non-sendable type '(T.Sender, T.Payload) -> Void' in a '@Sendable' closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
114 | }
115 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:113:12: warning: capture of 'sender' with non-sendable type 'T.Sender' in a '@Sendable' closure
111 | {
112 | queue.addOperation {
113 | block(sender, payload)
| `- warning: capture of 'sender' with non-sendable type 'T.Sender' in a '@Sendable' closure
114 | }
115 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:113:20: warning: capture of 'payload' with non-sendable type 'T.Payload' in a '@Sendable' closure
111 | {
112 | queue.addOperation {
113 | block(sender, payload)
| `- warning: capture of 'payload' with non-sendable type 'T.Payload' in a '@Sendable' closure
114 | }
115 | } else {
[7/19] Compiling TypedNotificationCenter TypedNotification.swift
[8/19] Compiling TypedNotificationCenter TypedNotificationObservation+GenericNsNotification.swift
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationObservation+GenericNsNotification.swift:37:4: warning: capture of 'typedNotificationCenter' with non-sendable type 'TypedNotificationCenter?' in a '@Sendable' closure
35 | self.nsNotificationCenter = nsNotificationCenter
36 | observation = nsNotificationCenter.addObserver(forName: notificationName, object: nil, queue: nil, using: { [weak typedNotificationCenter] notification in
37 | typedNotificationCenter?.forwardGenericPost(
| `- warning: capture of 'typedNotificationCenter' with non-sendable type 'TypedNotificationCenter?' in a '@Sendable' closure
38 | notification.name,
39 | sender: notification.object as AnyObject?,
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:32:20: note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
30 | typealias SenderIdentifier = ObjectIdentifier
31 |
32 | public final class TypedNotificationCenter {
| `- note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
33 | let observerLock = NSLock()
34 | var observers = [NotificationIdentifier: [SenderIdentifier: [ObjectIdentifier: WeakBox<AnyObject>]]]()
[9/19] Compiling TypedNotificationCenter PDFView.swift
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationObservation+GenericNsNotification.swift:37:4: warning: capture of 'typedNotificationCenter' with non-sendable type 'TypedNotificationCenter?' in a '@Sendable' closure
35 | self.nsNotificationCenter = nsNotificationCenter
36 | observation = nsNotificationCenter.addObserver(forName: notificationName, object: nil, queue: nil, using: { [weak typedNotificationCenter] notification in
37 | typedNotificationCenter?.forwardGenericPost(
| `- warning: capture of 'typedNotificationCenter' with non-sendable type 'TypedNotificationCenter?' in a '@Sendable' closure
38 | notification.name,
39 | sender: notification.object as AnyObject?,
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:32:20: note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
30 | typealias SenderIdentifier = ObjectIdentifier
31 |
32 | public final class TypedNotificationCenter {
| `- note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
33 | let observerLock = NSLock()
34 | var observers = [NotificationIdentifier: [SenderIdentifier: [ObjectIdentifier: WeakBox<AnyObject>]]]()
[10/19] Compiling TypedNotificationCenter TypedNotificationCenter+GenericBridgedNotification.swift
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:59:6: warning: capture of 'block' with non-sendable type '(Notification) -> Void' in a '@Sendable' closure
57 | {
58 | queue.addOperation {
59 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| |- warning: capture of 'block' with non-sendable type '(Notification) -> Void' in a '@Sendable' closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
60 | }
61 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:59:57: warning: capture of 'sender' with non-sendable type 'AnyObject?' in a '@Sendable' closure
57 | {
58 | queue.addOperation {
59 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| `- warning: capture of 'sender' with non-sendable type 'AnyObject?' in a '@Sendable' closure
60 | }
61 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:59:75: warning: capture of 'payload' with non-sendable type '[AnyHashable : Any]?' in a '@Sendable' closure
57 | {
58 | queue.addOperation {
59 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| `- warning: capture of 'payload' with non-sendable type '[AnyHashable : Any]?' in a '@Sendable' closure
60 | }
61 | } else {
Swift.Optional:1:21: note: generic enum 'Optional' does not conform to the 'Sendable' protocol
1 | @frozen public enum Optional<Wrapped> : ~Copyable where Wrapped : ~Copyable {
| `- note: generic enum 'Optional' does not conform to the 'Sendable' protocol
2 | case none
3 | case some(Wrapped)
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:73:6: warning: capture of 'block' with non-sendable type '(Notification) -> Void' in a '@Sendable' closure
71 | {
72 | queue.addOperation {
73 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| |- warning: capture of 'block' with non-sendable type '(Notification) -> Void' in a '@Sendable' closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
74 | }
75 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:73:57: warning: capture of 'sender' with non-sendable type 'AnyObject?' in a '@Sendable' closure
71 | {
72 | queue.addOperation {
73 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| `- warning: capture of 'sender' with non-sendable type 'AnyObject?' in a '@Sendable' closure
74 | }
75 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:73:75: warning: capture of 'payload' with non-sendable type '[AnyHashable : Any]?' in a '@Sendable' closure
71 | {
72 | queue.addOperation {
73 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| `- warning: capture of 'payload' with non-sendable type '[AnyHashable : Any]?' in a '@Sendable' closure
74 | }
75 | } else {
Swift.Optional:1:21: note: generic enum 'Optional' does not conform to the 'Sendable' protocol
1 | @frozen public enum Optional<Wrapped> : ~Copyable where Wrapped : ~Copyable {
| `- note: generic enum 'Optional' does not conform to the 'Sendable' protocol
2 | case none
3 | case some(Wrapped)
[11/19] Compiling TypedNotificationCenter TypedNotificationObservation+GenericBridgedNotification.swift
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:59:6: warning: capture of 'block' with non-sendable type '(Notification) -> Void' in a '@Sendable' closure
57 | {
58 | queue.addOperation {
59 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| |- warning: capture of 'block' with non-sendable type '(Notification) -> Void' in a '@Sendable' closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
60 | }
61 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:59:57: warning: capture of 'sender' with non-sendable type 'AnyObject?' in a '@Sendable' closure
57 | {
58 | queue.addOperation {
59 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| `- warning: capture of 'sender' with non-sendable type 'AnyObject?' in a '@Sendable' closure
60 | }
61 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:59:75: warning: capture of 'payload' with non-sendable type '[AnyHashable : Any]?' in a '@Sendable' closure
57 | {
58 | queue.addOperation {
59 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| `- warning: capture of 'payload' with non-sendable type '[AnyHashable : Any]?' in a '@Sendable' closure
60 | }
61 | } else {
Swift.Optional:1:21: note: generic enum 'Optional' does not conform to the 'Sendable' protocol
1 | @frozen public enum Optional<Wrapped> : ~Copyable where Wrapped : ~Copyable {
| `- note: generic enum 'Optional' does not conform to the 'Sendable' protocol
2 | case none
3 | case some(Wrapped)
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:73:6: warning: capture of 'block' with non-sendable type '(Notification) -> Void' in a '@Sendable' closure
71 | {
72 | queue.addOperation {
73 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| |- warning: capture of 'block' with non-sendable type '(Notification) -> Void' in a '@Sendable' closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
74 | }
75 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:73:57: warning: capture of 'sender' with non-sendable type 'AnyObject?' in a '@Sendable' closure
71 | {
72 | queue.addOperation {
73 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| `- warning: capture of 'sender' with non-sendable type 'AnyObject?' in a '@Sendable' closure
74 | }
75 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift:73:75: warning: capture of 'payload' with non-sendable type '[AnyHashable : Any]?' in a '@Sendable' closure
71 | {
72 | queue.addOperation {
73 | block(Notification(name: notificationName, object: sender, userInfo: payload))
| `- warning: capture of 'payload' with non-sendable type '[AnyHashable : Any]?' in a '@Sendable' closure
74 | }
75 | } else {
Swift.Optional:1:21: note: generic enum 'Optional' does not conform to the 'Sendable' protocol
1 | @frozen public enum Optional<Wrapped> : ~Copyable where Wrapped : ~Copyable {
| `- note: generic enum 'Optional' does not conform to the 'Sendable' protocol
2 | case none
3 | case some(Wrapped)
[12/19] Compiling TypedNotificationCenter TypedNotificationCenter+BridgedNotification.swift
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/TypedNotificationObservation+NsNotification.swift:57:5: warning: capture of 'typedNotificationCenter' with non-sendable type 'TypedNotificationCenter?' in a '@Sendable' closure
55 | let PayloadType = T.Payload.self as! DictionaryRepresentable.Type
56 | let payload = try PayloadType.init(notification.userInfo ?? [:]) as! T.Payload
57 | typedNotificationCenter?._post(T.self, sender: sender, payload: payload)
| `- warning: capture of 'typedNotificationCenter' with non-sendable type 'TypedNotificationCenter?' in a '@Sendable' closure
58 | } catch {
59 | TypedNotificationCenter.invalidPayloadBlock(error, notification.userInfo, type.notificationName)
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:32:20: note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
30 | typealias SenderIdentifier = ObjectIdentifier
31 |
32 | public final class TypedNotificationCenter {
| `- note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
33 | let observerLock = NSLock()
34 | var observers = [NotificationIdentifier: [SenderIdentifier: [ObjectIdentifier: WeakBox<AnyObject>]]]()
[13/19] Compiling TypedNotificationCenter TypedNotificationObservation+NsNotification.swift
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/TypedNotificationObservation+NsNotification.swift:57:5: warning: capture of 'typedNotificationCenter' with non-sendable type 'TypedNotificationCenter?' in a '@Sendable' closure
55 | let PayloadType = T.Payload.self as! DictionaryRepresentable.Type
56 | let payload = try PayloadType.init(notification.userInfo ?? [:]) as! T.Payload
57 | typedNotificationCenter?._post(T.self, sender: sender, payload: payload)
| `- warning: capture of 'typedNotificationCenter' with non-sendable type 'TypedNotificationCenter?' in a '@Sendable' closure
58 | } catch {
59 | TypedNotificationCenter.invalidPayloadBlock(error, notification.userInfo, type.notificationName)
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:32:20: note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
30 | typealias SenderIdentifier = ObjectIdentifier
31 |
32 | public final class TypedNotificationCenter {
| `- note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
33 | let observerLock = NSLock()
34 | var observers = [NotificationIdentifier: [SenderIdentifier: [ObjectIdentifier: WeakBox<AnyObject>]]]()
[14/19] Compiling TypedNotificationCenter UIResponder.swift
[15/19] Compiling TypedNotificationCenter AnyPayloadTypedNotification.swift
[16/19] Compiling TypedNotificationCenter BridgedNotification+ErrorHandlingCustomization.swift
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/BridgedNotification+ErrorHandlingCustomization.swift:30:13: warning: static property 'invalidSenderBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
28 |
29 | public extension TypedNotificationCenter {
30 | static var invalidSenderBlock: (Any?, Notification.Name) -> Void = { sender, notificationName in
| |- warning: static property 'invalidSenderBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'invalidSenderBlock' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: add '@MainActor' to make static property 'invalidSenderBlock' part of global actor 'MainActor'
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
31 | assertionFailure("Invalid sender(\(sender ?? NSNull())) for \"\(notificationName)\"")
32 | }
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/BridgedNotification+ErrorHandlingCustomization.swift:34:13: warning: static property 'invalidPayloadBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
32 | }
33 |
34 | static var invalidPayloadBlock: (Error, [AnyHashable: Any]?, Notification.Name) -> Void = { error, _, _ in
| |- warning: static property 'invalidPayloadBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'invalidPayloadBlock' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: add '@MainActor' to make static property 'invalidPayloadBlock' part of global actor 'MainActor'
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
35 | assertionFailure(error.localizedDescription)
36 | }
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/BridgedNotification.swift:31:13: warning: stored property 'source' of 'Sendable'-conforming struct 'NotificationDecodingError' has non-sendable type '[AnyHashable : Any]'; this is an error in the Swift 6 language mode
29 | public struct NotificationDecodingError: LocalizedError {
30 | public var type: Any.Type
31 | public var source: [AnyHashable: Any]
| `- warning: stored property 'source' of 'Sendable'-conforming struct 'NotificationDecodingError' has non-sendable type '[AnyHashable : Any]'; this is an error in the Swift 6 language mode
32 |
33 | public init(type: Any.Type, source: [AnyHashable: Any]) {
Swift.Dictionary:1:23: note: generic struct 'Dictionary' does not conform to the 'Sendable' protocol
1 | @frozen public struct Dictionary<Key, Value> where Key : Hashable {
| `- note: generic struct 'Dictionary' does not conform to the 'Sendable' protocol
2 | public typealias Element = (key: Key, value: Value)
3 | @inlinable public init(_immutableCocoaDictionary: __owned AnyObject)
[17/19] Compiling TypedNotificationCenter BridgedNotification.swift
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/BridgedNotification+ErrorHandlingCustomization.swift:30:13: warning: static property 'invalidSenderBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
28 |
29 | public extension TypedNotificationCenter {
30 | static var invalidSenderBlock: (Any?, Notification.Name) -> Void = { sender, notificationName in
| |- warning: static property 'invalidSenderBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'invalidSenderBlock' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: add '@MainActor' to make static property 'invalidSenderBlock' part of global actor 'MainActor'
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
31 | assertionFailure("Invalid sender(\(sender ?? NSNull())) for \"\(notificationName)\"")
32 | }
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/BridgedNotification+ErrorHandlingCustomization.swift:34:13: warning: static property 'invalidPayloadBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
32 | }
33 |
34 | static var invalidPayloadBlock: (Error, [AnyHashable: Any]?, Notification.Name) -> Void = { error, _, _ in
| |- warning: static property 'invalidPayloadBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'invalidPayloadBlock' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: add '@MainActor' to make static property 'invalidPayloadBlock' part of global actor 'MainActor'
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
35 | assertionFailure(error.localizedDescription)
36 | }
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/BridgedNotification.swift:31:13: warning: stored property 'source' of 'Sendable'-conforming struct 'NotificationDecodingError' has non-sendable type '[AnyHashable : Any]'; this is an error in the Swift 6 language mode
29 | public struct NotificationDecodingError: LocalizedError {
30 | public var type: Any.Type
31 | public var source: [AnyHashable: Any]
| `- warning: stored property 'source' of 'Sendable'-conforming struct 'NotificationDecodingError' has non-sendable type '[AnyHashable : Any]'; this is an error in the Swift 6 language mode
32 |
33 | public init(type: Any.Type, source: [AnyHashable: Any]) {
Swift.Dictionary:1:23: note: generic struct 'Dictionary' does not conform to the 'Sendable' protocol
1 | @frozen public struct Dictionary<Key, Value> where Key : Hashable {
| `- note: generic struct 'Dictionary' does not conform to the 'Sendable' protocol
2 | public typealias Element = (key: Key, value: Value)
3 | @inlinable public init(_immutableCocoaDictionary: __owned AnyObject)
[18/19] Emitting module TypedNotificationCenter
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/BridgedNotification+ErrorHandlingCustomization.swift:30:13: warning: static property 'invalidSenderBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
28 |
29 | public extension TypedNotificationCenter {
30 | static var invalidSenderBlock: (Any?, Notification.Name) -> Void = { sender, notificationName in
| |- warning: static property 'invalidSenderBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'invalidSenderBlock' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: add '@MainActor' to make static property 'invalidSenderBlock' part of global actor 'MainActor'
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
31 | assertionFailure("Invalid sender(\(sender ?? NSNull())) for \"\(notificationName)\"")
32 | }
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/BridgedNotification+ErrorHandlingCustomization.swift:34:13: warning: static property 'invalidPayloadBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
32 | }
33 |
34 | static var invalidPayloadBlock: (Error, [AnyHashable: Any]?, Notification.Name) -> Void = { error, _, _ in
| |- warning: static property 'invalidPayloadBlock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'invalidPayloadBlock' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: add '@MainActor' to make static property 'invalidPayloadBlock' part of global actor 'MainActor'
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
35 | assertionFailure(error.localizedDescription)
36 | }
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/BridgedNotifications/Core/BridgedNotification.swift:31:13: warning: stored property 'source' of 'Sendable'-conforming struct 'NotificationDecodingError' has non-sendable type '[AnyHashable : Any]'; this is an error in the Swift 6 language mode
29 | public struct NotificationDecodingError: LocalizedError {
30 | public var type: Any.Type
31 | public var source: [AnyHashable: Any]
| `- warning: stored property 'source' of 'Sendable'-conforming struct 'NotificationDecodingError' has non-sendable type '[AnyHashable : Any]'; this is an error in the Swift 6 language mode
32 |
33 | public init(type: Any.Type, source: [AnyHashable: Any]) {
Swift.Dictionary:1:23: note: generic struct 'Dictionary' does not conform to the 'Sendable' protocol
1 | @frozen public struct Dictionary<Key, Value> where Key : Hashable {
| `- note: generic struct 'Dictionary' does not conform to the 'Sendable' protocol
2 | public typealias Element = (key: Key, value: Value)
3 | @inlinable public init(_immutableCocoaDictionary: __owned AnyObject)
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Core/TypedNotificationCenter.swift:127:20: warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'TypedNotificationCenter' may have shared mutable state; this is an error in the Swift 6 language mode
30 | typealias SenderIdentifier = ObjectIdentifier
31 |
32 | public final class TypedNotificationCenter {
| `- note: class 'TypedNotificationCenter' does not conform to the 'Sendable' protocol
33 | let observerLock = NSLock()
34 | var observers = [NotificationIdentifier: [SenderIdentifier: [ObjectIdentifier: WeakBox<AnyObject>]]]()
:
125 | }
126 |
127 | public static let `default` = TypedNotificationCenter()
| |- warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'TypedNotificationCenter' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: add '@MainActor' to make static property 'default' part of global actor 'MainActor'
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
128 |
129 | public func observe<T: TypedNotification>(_: T.Type, object: T.Sender?, queue: OperationQueue? = nil, block: @escaping T.ObservationBlock) -> TypedNotificationObservation {
[19/19] Compiling TypedNotificationCenter WeakBox.swift
Build complete! (5.74s)
warning: 'spi-builder-workspace': found 1 file(s) which are unhandled; explicitly declare them as resources or exclude from the target
/Users/admin/builder/spi-builder-workspace/Sources/TypedNotificationCenter/Info.plist
Build complete.
{
"dependencies" : [
],
"manifest_display_name" : "TypedNotificationCenter",
"name" : "TypedNotificationCenter",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
{
"name" : "macos",
"version" : "10.13"
},
{
"name" : "ios",
"version" : "11.0"
},
{
"name" : "watchos",
"version" : "4.0"
},
{
"name" : "tvos",
"version" : "11.0"
}
],
"products" : [
{
"name" : "TypedNotificationCenter",
"targets" : [
"TypedNotificationCenter"
],
"type" : {
"library" : [
"automatic"
]
}
}
],
"targets" : [
{
"c99name" : "TypedNotificationCenterTests",
"module_type" : "SwiftTarget",
"name" : "TypedNotificationCenterTests",
"path" : "Tests/TypedNotificationCenterTests",
"sources" : [
"Bridged Notification tests/BridgedNotificationApiTests.swift",
"Bridged Notification tests/BridgedNotificationInternalTests.swift",
"Bridged Notification tests/NotificationNameApiTests.swift",
"Bridged Notification tests/Utility/SampleBridgedNotification.swift",
"Core tests/ApiTests.swift",
"Core tests/AsyncApiTests.swift",
"Core tests/Utility/SampleNotification.swift",
"Internal tests/InternalTests.swift",
"Utility/TestCase.swift",
"Utility/XCTestCase+Utils.swift"
],
"target_dependencies" : [
"TypedNotificationCenter"
],
"type" : "test"
},
{
"c99name" : "TypedNotificationCenterPerformanceTests",
"module_type" : "SwiftTarget",
"name" : "TypedNotificationCenterPerformanceTests",
"path" : "Tests/TypedNotificationCenterPerformanceTests",
"sources" : [
"BridgedNotification.swift",
"Posting.swift",
"Subscribing.swift",
"Unsubscribing.swift",
"Utility/PerformanceTestNotifications.swift",
"Utility/TestCase.swift"
],
"target_dependencies" : [
"TypedNotificationCenter"
],
"type" : "test"
},
{
"c99name" : "TypedNotificationCenter",
"module_type" : "SwiftTarget",
"name" : "TypedNotificationCenter",
"path" : "Sources/TypedNotificationCenter",
"product_memberships" : [
"TypedNotificationCenter"
],
"sources" : [
"BridgedNotifications/Core/BridgedNotification+ErrorHandlingCustomization.swift",
"BridgedNotifications/Core/BridgedNotification.swift",
"BridgedNotifications/Core/TypedNotificationCenter+BridgedNotification.swift",
"BridgedNotifications/Core/TypedNotificationObservation+NsNotification.swift",
"BridgedNotifications/GenericBridgedNotification/TypedNotificationCenter+GenericBridgedNotification.swift",
"BridgedNotifications/GenericBridgedNotification/TypedNotificationObservation+GenericBridgedNotification.swift",
"BridgedNotifications/GenericBridgedNotification/TypedNotificationObservation+GenericNsNotification.swift",
"BridgedNotifications/PDFKit/PDFView.swift",
"BridgedNotifications/UIKit/UIResponder.swift",
"Core/TypeErasure/AnyPayloadTypedNotification.swift",
"Core/TypeErasure/AnyTypedNotification.swift",
"Core/TypeErasure/SameTypedNotification.swift",
"Core/TypedNotification.swift",
"Core/TypedNotificationCenter.swift",
"Core/TypedNotificationObservation.swift",
"Core/WeakBox.swift"
],
"type" : "library"
}
],
"tools_version" : "5.7"
}
Done.