Build Information
Successful build of SignalRClient, reference master (655e8b
), with Swift 6.0 for macOS (SPM) on 3 Feb 2025 12:34:20 UTC.
Swift 6 data race errors: 11
Build Command
env DEVELOPER_DIR=/Applications/Xcode-16.2.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.60.1
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/moozzyk/SignalR-Client-Swift.git
Reference: master
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/moozzyk/SignalR-Client-Swift
* branch master -> FETCH_HEAD
* [new branch] master -> origin/master
HEAD is now at 655e8bd Add HubConnection extension methods for non-void hub methods with client streams
Cloned https://github.com/moozzyk/SignalR-Client-Swift.git
Revision (git rev-parse @):
655e8bde45b4e3fc737c8ced9da242e3a76f3e69
SUCCESS checkout https://github.com/moozzyk/SignalR-Client-Swift.git at master
========================================
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": "signalr-client-swift",
"name": "SignalRClient",
"url": "https://github.com/moozzyk/SignalR-Client-Swift.git",
"version": "unspecified",
"path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/SignalR-Client-Swift",
"dependencies": [
]
}
]
}
Fetching https://github.com/moozzyk/SignalR-Client-Swift.git
[1/3815] Fetching signalr-client-swift
Fetched https://github.com/moozzyk/SignalR-Client-Swift.git from cache (1.38s)
Creating working copy for https://github.com/moozzyk/SignalR-Client-Swift.git
Working copy of https://github.com/moozzyk/SignalR-Client-Swift.git resolved at master (655e8bd)
warning: '.resolve-product-dependencies': dependency 'signalr-client-swift' 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/moozzyk/SignalR-Client-Swift.git
https://github.com/moozzyk/SignalR-Client-Swift.git
{
"dependencies" : [
],
"manifest_display_name" : "SignalRClient",
"name" : "SignalRClient",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
],
"products" : [
{
"name" : "SignalRClient",
"targets" : [
"SignalRClient"
],
"type" : {
"library" : [
"automatic"
]
}
}
],
"swift_languages_versions" : [
"4",
"4.2",
"5"
],
"targets" : [
{
"c99name" : "SignalRClientTests",
"module_type" : "SwiftTarget",
"name" : "SignalRClientTests",
"path" : "Tests/SignalRClientTests",
"sources" : [
"ClientStreamWorkerTests.swift",
"Constants.swift",
"Fakes.swift",
"HandshakeProtocolTests.swift",
"HttpConnectionTests.swift",
"HubConnectionExtensionsTests.swift",
"HubConnectionTests.swift",
"HubProtocolFake.swift",
"JSONHubProtocolTests.swift",
"LoggerTests.swift",
"LongPollingTransportTests.swift",
"NegotiationResponseTests.swift",
"ReconnectPolicyTests.swift",
"ReconnectableConnectionTests.swift",
"ServerInvocationHandlerTests.swift",
"TestTransport.swift",
"TestTransportDelegate.swift",
"TestUtils.swift",
"TransportTypeTests.swift",
"WebsocketsTransportTests.swift"
],
"target_dependencies" : [
"SignalRClient"
],
"type" : "test"
},
{
"c99name" : "SignalRClient",
"module_type" : "SwiftTarget",
"name" : "SignalRClient",
"path" : "Sources/SignalRClient",
"product_memberships" : [
"SignalRClient"
],
"sources" : [
"ClientStreamWorker.swift",
"CodableHelpers.swift",
"Connection.swift",
"ConnectionDelegate.swift",
"DefaultHttpClient.swift",
"DefaultTransportFactory.swift",
"HandshakeProtocol.swift",
"HttpClientProtocol.swift",
"HttpConnection.swift",
"HttpConnectionOptions.swift",
"HttpResponse.swift",
"HubConnection.swift",
"HubConnectionBuilder.swift",
"HubConnectionDelegate.swift",
"HubConnectionExtensions.swift",
"HubConnectionOptions.swift",
"HubProtocol.swift",
"JSONHubProtocol.swift",
"Logger.swift",
"LongPollingTransport.swift",
"NegotiationResponse.swift",
"ReconnectPolicy.swift",
"ReconnectableConnection.swift",
"ServerInvocationHandler.swift",
"SignalRError.swift",
"StreamHandle.swift",
"TransferFormat.swift",
"Transport.swift",
"TransportDelegate.swift",
"TransportType.swift",
"WebsocketsTransport.swift"
],
"type" : "library"
}
],
"tools_version" : "5.0"
}
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-16.2.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-5BDAB9E9C0126B9D.txt
[3/31] Emitting module SignalRClient
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:79:16: warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
77 |
78 | private class DefaultHttpClientSessionDelegate: NSObject, URLSessionDelegate {
79 | static var shared = DefaultHttpClientSessionDelegate()
| |- warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'shared' to a 'let' constant to make 'Sendable' shared state immutable
| |- 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
80 |
81 | var authenticationChallengeHandler:
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:78:15: warning: non-final class 'DefaultHttpClientSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
76 | }
77 |
78 | private class DefaultHttpClientSessionDelegate: NSObject, URLSessionDelegate {
| `- warning: non-final class 'DefaultHttpClientSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
79 | static var shared = DefaultHttpClientSessionDelegate()
80 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:81:9: warning: stored property 'authenticationChallengeHandler' of 'Sendable'-conforming class 'DefaultHttpClientSessionDelegate' is mutable; this is an error in the Swift 6 language mode
79 | static var shared = DefaultHttpClientSessionDelegate()
80 |
81 | var authenticationChallengeHandler:
| `- warning: stored property 'authenticationChallengeHandler' of 'Sendable'-conforming class 'DefaultHttpClientSessionDelegate' is mutable; this is an error in the Swift 6 language mode
82 | (
83 | (
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:18:23: warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
16 | }
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
| |- warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'longPolling' 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
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:268:16: warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
262 | }
263 |
264 | public class PingMessage: HubMessage, Encodable {
| `- note: class 'PingMessage' does not conform to the 'Sendable' protocol
265 | public let type = MessageType.Ping
266 | private init() {}
267 |
268 | static let instance = PingMessage()
| |- warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'instance' 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
269 | }
270 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:19:16: warning: static property 'serverSentEvents' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
| |- warning: static property 'serverSentEvents' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'serverSentEvents' 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
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:12:14: warning: non-final class 'WebsocketsTransport' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
10 |
11 | @available(OSX 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
12 | public class WebsocketsTransport: NSObject, Transport, URLSessionWebSocketDelegate {
| `- warning: non-final class 'WebsocketsTransport' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
13 | private let logger: Logger
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:13:17: warning: stored property 'logger' of 'Sendable'-conforming class 'WebsocketsTransport' has non-sendable type 'any Logger'; this is an error in the Swift 6 language mode
11 | @available(OSX 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
12 | public class WebsocketsTransport: NSObject, Transport, URLSessionWebSocketDelegate {
13 | private let logger: Logger
| `- warning: stored property 'logger' of 'Sendable'-conforming class 'WebsocketsTransport' has non-sendable type 'any Logger'; this is an error in the Swift 6 language mode
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
15 | private var urlSession: URLSession?
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/Logger.swift:19:17: note: protocol 'Logger' does not conform to the 'Sendable' protocol
17 |
18 | /// Protocol for implementing loggers.
19 | public protocol Logger {
| `- note: protocol 'Logger' does not conform to the 'Sendable' protocol
20 | /**
21 | Invoked by the client to write a log entry.
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:15:17: warning: stored property 'urlSession' of 'Sendable'-conforming class 'WebsocketsTransport' is mutable; this is an error in the Swift 6 language mode
13 | private let logger: Logger
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
15 | private var urlSession: URLSession?
| `- warning: stored property 'urlSession' of 'Sendable'-conforming class 'WebsocketsTransport' is mutable; this is an error in the Swift 6 language mode
16 | private var webSocketTask: URLSessionWebSocketTask?
17 | private var authenticationChallengeHandler:
[4/34] Compiling SignalRClient TransportDelegate.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:18:23: warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
16 | }
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
| |- warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'longPolling' 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
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:19:16: warning: static property 'serverSentEvents' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
| |- warning: static property 'serverSentEvents' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'serverSentEvents' 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
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:12:14: warning: non-final class 'WebsocketsTransport' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
10 |
11 | @available(OSX 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
12 | public class WebsocketsTransport: NSObject, Transport, URLSessionWebSocketDelegate {
| `- warning: non-final class 'WebsocketsTransport' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
13 | private let logger: Logger
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:13:17: warning: stored property 'logger' of 'Sendable'-conforming class 'WebsocketsTransport' has non-sendable type 'any Logger'; this is an error in the Swift 6 language mode
11 | @available(OSX 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
12 | public class WebsocketsTransport: NSObject, Transport, URLSessionWebSocketDelegate {
13 | private let logger: Logger
| `- warning: stored property 'logger' of 'Sendable'-conforming class 'WebsocketsTransport' has non-sendable type 'any Logger'; this is an error in the Swift 6 language mode
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
15 | private var urlSession: URLSession?
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/Logger.swift:19:17: note: protocol 'Logger' does not conform to the 'Sendable' protocol
17 |
18 | /// Protocol for implementing loggers.
19 | public protocol Logger {
| `- note: protocol 'Logger' does not conform to the 'Sendable' protocol
20 | /**
21 | Invoked by the client to write a log entry.
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:15:17: warning: stored property 'urlSession' of 'Sendable'-conforming class 'WebsocketsTransport' is mutable; this is an error in the Swift 6 language mode
13 | private let logger: Logger
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
15 | private var urlSession: URLSession?
| `- warning: stored property 'urlSession' of 'Sendable'-conforming class 'WebsocketsTransport' is mutable; this is an error in the Swift 6 language mode
16 | private var webSocketTask: URLSessionWebSocketTask?
17 | private var authenticationChallengeHandler:
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:53:57: warning: passing non-sendable parameter 'sendDidComplete' to function expecting a @Sendable closure
49 | }
50 |
51 | public func send(data: Data, sendDidComplete: @escaping (Error?) -> Void) {
| `- note: parameter 'sendDidComplete' is implicitly non-sendable
52 | let message = URLSessionWebSocketTask.Message.data(data)
53 | webSocketTask?.send(message, completionHandler: sendDidComplete)
| `- warning: passing non-sendable parameter 'sendDidComplete' to function expecting a @Sendable closure
54 | }
55 |
[5/34] Compiling SignalRClient TransportType.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:18:23: warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
16 | }
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
| |- warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'longPolling' 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
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:19:16: warning: static property 'serverSentEvents' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
| |- warning: static property 'serverSentEvents' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'serverSentEvents' 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
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:12:14: warning: non-final class 'WebsocketsTransport' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
10 |
11 | @available(OSX 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
12 | public class WebsocketsTransport: NSObject, Transport, URLSessionWebSocketDelegate {
| `- warning: non-final class 'WebsocketsTransport' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
13 | private let logger: Logger
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:13:17: warning: stored property 'logger' of 'Sendable'-conforming class 'WebsocketsTransport' has non-sendable type 'any Logger'; this is an error in the Swift 6 language mode
11 | @available(OSX 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
12 | public class WebsocketsTransport: NSObject, Transport, URLSessionWebSocketDelegate {
13 | private let logger: Logger
| `- warning: stored property 'logger' of 'Sendable'-conforming class 'WebsocketsTransport' has non-sendable type 'any Logger'; this is an error in the Swift 6 language mode
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
15 | private var urlSession: URLSession?
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/Logger.swift:19:17: note: protocol 'Logger' does not conform to the 'Sendable' protocol
17 |
18 | /// Protocol for implementing loggers.
19 | public protocol Logger {
| `- note: protocol 'Logger' does not conform to the 'Sendable' protocol
20 | /**
21 | Invoked by the client to write a log entry.
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:15:17: warning: stored property 'urlSession' of 'Sendable'-conforming class 'WebsocketsTransport' is mutable; this is an error in the Swift 6 language mode
13 | private let logger: Logger
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
15 | private var urlSession: URLSession?
| `- warning: stored property 'urlSession' of 'Sendable'-conforming class 'WebsocketsTransport' is mutable; this is an error in the Swift 6 language mode
16 | private var webSocketTask: URLSessionWebSocketTask?
17 | private var authenticationChallengeHandler:
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:53:57: warning: passing non-sendable parameter 'sendDidComplete' to function expecting a @Sendable closure
49 | }
50 |
51 | public func send(data: Data, sendDidComplete: @escaping (Error?) -> Void) {
| `- note: parameter 'sendDidComplete' is implicitly non-sendable
52 | let message = URLSessionWebSocketTask.Message.data(data)
53 | webSocketTask?.send(message, completionHandler: sendDidComplete)
| `- warning: passing non-sendable parameter 'sendDidComplete' to function expecting a @Sendable closure
54 | }
55 |
[6/34] Compiling SignalRClient WebsocketsTransport.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:18:23: warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
16 | }
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
| |- warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'longPolling' 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
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:19:16: warning: static property 'serverSentEvents' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
| |- warning: static property 'serverSentEvents' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'serverSentEvents' 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
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:12:14: warning: non-final class 'WebsocketsTransport' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
10 |
11 | @available(OSX 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
12 | public class WebsocketsTransport: NSObject, Transport, URLSessionWebSocketDelegate {
| `- warning: non-final class 'WebsocketsTransport' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
13 | private let logger: Logger
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:13:17: warning: stored property 'logger' of 'Sendable'-conforming class 'WebsocketsTransport' has non-sendable type 'any Logger'; this is an error in the Swift 6 language mode
11 | @available(OSX 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
12 | public class WebsocketsTransport: NSObject, Transport, URLSessionWebSocketDelegate {
13 | private let logger: Logger
| `- warning: stored property 'logger' of 'Sendable'-conforming class 'WebsocketsTransport' has non-sendable type 'any Logger'; this is an error in the Swift 6 language mode
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
15 | private var urlSession: URLSession?
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/Logger.swift:19:17: note: protocol 'Logger' does not conform to the 'Sendable' protocol
17 |
18 | /// Protocol for implementing loggers.
19 | public protocol Logger {
| `- note: protocol 'Logger' does not conform to the 'Sendable' protocol
20 | /**
21 | Invoked by the client to write a log entry.
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:15:17: warning: stored property 'urlSession' of 'Sendable'-conforming class 'WebsocketsTransport' is mutable; this is an error in the Swift 6 language mode
13 | private let logger: Logger
14 | private let dispatchQueue = DispatchQueue(label: "SignalR.webSocketTransport.queue")
15 | private var urlSession: URLSession?
| `- warning: stored property 'urlSession' of 'Sendable'-conforming class 'WebsocketsTransport' is mutable; this is an error in the Swift 6 language mode
16 | private var webSocketTask: URLSessionWebSocketTask?
17 | private var authenticationChallengeHandler:
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/WebsocketsTransport.swift:53:57: warning: passing non-sendable parameter 'sendDidComplete' to function expecting a @Sendable closure
49 | }
50 |
51 | public func send(data: Data, sendDidComplete: @escaping (Error?) -> Void) {
| `- note: parameter 'sendDidComplete' is implicitly non-sendable
52 | let message = URLSessionWebSocketTask.Message.data(data)
53 | webSocketTask?.send(message, completionHandler: sendDidComplete)
| `- warning: passing non-sendable parameter 'sendDidComplete' to function expecting a @Sendable closure
54 | }
55 |
[7/34] Compiling SignalRClient HttpClientProtocol.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:212:13: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
210 | logger.log(logLevel: .debug, message: "Invoking connectionDidFailToOpen")
211 | options.callbackQueue.async {
212 | self.delegate?.connectionDidFailToOpen(error: error)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
213 | }
214 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:223:17: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
221 | // Never synchronously respond to avoid upstream deadlocks based on async assumptions
222 | options.callbackQueue.async {
223 | sendDidComplete(SignalRError.invalidState)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
224 | }
225 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:255:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
253 | logger.log(logLevel: .debug, message: "Invoking connectionDidClose (\(#function): \(#line))")
254 | options.callbackQueue.async {
255 | self.delegate?.connectionDidClose(error: stopError)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
256 | }
257 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:271:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
269 | self.connectionId = connectionId
270 | options.callbackQueue.async {
271 | self.delegate?.connectionDidOpen(connection: self)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
272 | }
273 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:281:13: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
279 | logger.log(logLevel: .debug, message: "Received data from transport")
280 | options.callbackQueue.async {
281 | self.delegate?.connectionDidReceiveData(connection: self, data: data)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
282 | }
283 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:298:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
296 | logger.log(logLevel: .debug, message: "Invoking connectionDidFailToOpen")
297 | options.callbackQueue.async {
298 | self.delegate?.connectionDidFailToOpen(error: self.stopError ?? error!)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
299 | }
300 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:306:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
304 |
305 | options.callbackQueue.async {
306 | self.delegate?.connectionDidClose(error: self.stopError ?? error)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
307 | }
308 | }
[8/34] Compiling SignalRClient HttpConnection.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:212:13: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
210 | logger.log(logLevel: .debug, message: "Invoking connectionDidFailToOpen")
211 | options.callbackQueue.async {
212 | self.delegate?.connectionDidFailToOpen(error: error)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
213 | }
214 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:223:17: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
221 | // Never synchronously respond to avoid upstream deadlocks based on async assumptions
222 | options.callbackQueue.async {
223 | sendDidComplete(SignalRError.invalidState)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
224 | }
225 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:255:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
253 | logger.log(logLevel: .debug, message: "Invoking connectionDidClose (\(#function): \(#line))")
254 | options.callbackQueue.async {
255 | self.delegate?.connectionDidClose(error: stopError)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
256 | }
257 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:271:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
269 | self.connectionId = connectionId
270 | options.callbackQueue.async {
271 | self.delegate?.connectionDidOpen(connection: self)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
272 | }
273 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:281:13: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
279 | logger.log(logLevel: .debug, message: "Received data from transport")
280 | options.callbackQueue.async {
281 | self.delegate?.connectionDidReceiveData(connection: self, data: data)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
282 | }
283 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:298:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
296 | logger.log(logLevel: .debug, message: "Invoking connectionDidFailToOpen")
297 | options.callbackQueue.async {
298 | self.delegate?.connectionDidFailToOpen(error: self.stopError ?? error!)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
299 | }
300 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:306:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
304 |
305 | options.callbackQueue.async {
306 | self.delegate?.connectionDidClose(error: self.stopError ?? error)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
307 | }
308 | }
[9/34] Compiling SignalRClient HttpConnectionOptions.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:212:13: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
210 | logger.log(logLevel: .debug, message: "Invoking connectionDidFailToOpen")
211 | options.callbackQueue.async {
212 | self.delegate?.connectionDidFailToOpen(error: error)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
213 | }
214 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:223:17: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
221 | // Never synchronously respond to avoid upstream deadlocks based on async assumptions
222 | options.callbackQueue.async {
223 | sendDidComplete(SignalRError.invalidState)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
224 | }
225 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:255:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
253 | logger.log(logLevel: .debug, message: "Invoking connectionDidClose (\(#function): \(#line))")
254 | options.callbackQueue.async {
255 | self.delegate?.connectionDidClose(error: stopError)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
256 | }
257 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:271:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
269 | self.connectionId = connectionId
270 | options.callbackQueue.async {
271 | self.delegate?.connectionDidOpen(connection: self)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
272 | }
273 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:281:13: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
279 | logger.log(logLevel: .debug, message: "Received data from transport")
280 | options.callbackQueue.async {
281 | self.delegate?.connectionDidReceiveData(connection: self, data: data)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
282 | }
283 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:298:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
296 | logger.log(logLevel: .debug, message: "Invoking connectionDidFailToOpen")
297 | options.callbackQueue.async {
298 | self.delegate?.connectionDidFailToOpen(error: self.stopError ?? error!)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
299 | }
300 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HttpConnection.swift:306:17: warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
9 | import Foundation
10 |
11 | public class HttpConnection: Connection {
| `- note: class 'HttpConnection' does not conform to the 'Sendable' protocol
12 | private let connectionQueue: DispatchQueue
13 | private let startDispatchGroup: DispatchGroup
:
304 |
305 | options.callbackQueue.async {
306 | self.delegate?.connectionDidClose(error: self.stopError ?? error)
| `- warning: capture of 'self' with non-sendable type 'HttpConnection' in a `@Sendable` closure
307 | }
308 | }
[10/34] Compiling SignalRClient ClientStreamWorker.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:42:27: warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
40 | return
41 | }
42 | streamTask = Task {
| `- warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
43 | for await value in stream {
| `- note: closure captures 'self' which is accessible to code in the current task
44 | if Task.isCancelled {
45 | logger.log(logLevel: .info, message: "Client Stream \(streamId) processing has been canceled")
[11/34] Compiling SignalRClient CodableHelpers.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:42:27: warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
40 | return
41 | }
42 | streamTask = Task {
| `- warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
43 | for await value in stream {
| `- note: closure captures 'self' which is accessible to code in the current task
44 | if Task.isCancelled {
45 | logger.log(logLevel: .info, message: "Client Stream \(streamId) processing has been canceled")
[12/34] Compiling SignalRClient Connection.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:42:27: warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
40 | return
41 | }
42 | streamTask = Task {
| `- warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
43 | for await value in stream {
| `- note: closure captures 'self' which is accessible to code in the current task
44 | if Task.isCancelled {
45 | logger.log(logLevel: .info, message: "Client Stream \(streamId) processing has been canceled")
[13/34] Compiling SignalRClient ConnectionDelegate.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:42:27: warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
40 | return
41 | }
42 | streamTask = Task {
| `- warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
43 | for await value in stream {
| `- note: closure captures 'self' which is accessible to code in the current task
44 | if Task.isCancelled {
45 | logger.log(logLevel: .info, message: "Client Stream \(streamId) processing has been canceled")
[14/34] Compiling SignalRClient HubConnectionDelegate.swift
[15/34] Compiling SignalRClient HubConnectionExtensions.swift
[16/34] Compiling SignalRClient HubConnectionOptions.swift
[17/34] Compiling SignalRClient LongPollingTransport.swift
[18/34] Compiling SignalRClient NegotiationResponse.swift
[19/34] Compiling SignalRClient ReconnectPolicy.swift
[20/34] Compiling SignalRClient ReconnectableConnection.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ReconnectableConnection.swift:70:17: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
68 | // Never synchronously respond to avoid upstream deadlocks based on async assumptions
69 | callbackQueue.async {
70 | sendDidComplete(SignalRError.connectionIsReconnecting)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
71 | }
72 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:39:17: warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
37 | self.invocationDidComplete = { result, error in
38 | callbackQueue.async {
39 | clientStreamWorkers.forEach { $0.stop() }
| `- warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
40 | invocationDidComplete(result, error)
41 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:10:19: note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
8 | import Foundation
9 |
10 | internal protocol ClientStreamWorker {
| `- note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
11 | var streamId: String { get }
12 | func start()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:40:17: warning: capture of 'invocationDidComplete' with non-sendable type '(T?, (any Error)?) -> Void' in a `@Sendable` closure
38 | callbackQueue.async {
39 | clientStreamWorkers.forEach { $0.stop() }
40 | invocationDidComplete(result, error)
| |- warning: capture of 'invocationDidComplete' with non-sendable type '(T?, (any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
41 | }
42 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:40:39: warning: capture of 'result' with non-sendable type 'T?' in a `@Sendable` closure
19 | }
20 |
21 | internal class InvocationHandler<T: Decodable>: ServerInvocationHandler {
| `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
22 | private let logger: Logger
23 | public private(set) var method: String
:
38 | callbackQueue.async {
39 | clientStreamWorkers.forEach { $0.stop() }
40 | invocationDidComplete(result, error)
| `- warning: capture of 'result' with non-sendable type 'T?' in a `@Sendable` closure
41 | }
42 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:122:67: warning: capture of 'streamItemReceived' with non-sendable type '(T) -> Void' in a `@Sendable` closure
120 | self.arguments = arguments
121 | self.clientStreamWorkers = clientStreamWorkers
122 | self.streamItemReceived = { item in callbackQueue.async { streamItemReceived(item) } }
| |- warning: capture of 'streamItemReceived' with non-sendable type '(T) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
123 | self.invocationDidComplete = { error in
124 | callbackQueue.async {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:122:86: warning: capture of 'item' with non-sendable type 'T' in a `@Sendable` closure
103 | }
104 |
105 | internal class StreamInvocationHandler<T: Decodable>: ServerInvocationHandler {
| `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
106 | private let logger: Logger
107 | public private(set) var method: String
:
120 | self.arguments = arguments
121 | self.clientStreamWorkers = clientStreamWorkers
122 | self.streamItemReceived = { item in callbackQueue.async { streamItemReceived(item) } }
| `- warning: capture of 'item' with non-sendable type 'T' in a `@Sendable` closure
123 | self.invocationDidComplete = { error in
124 | callbackQueue.async {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:125:17: warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
123 | self.invocationDidComplete = { error in
124 | callbackQueue.async {
125 | clientStreamWorkers.forEach { $0.stop() }
| `- warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
126 | invocationDidComplete(error)
127 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:10:19: note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
8 | import Foundation
9 |
10 | internal protocol ClientStreamWorker {
| `- note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
11 | var streamId: String { get }
12 | func start()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:126:17: warning: capture of 'invocationDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
124 | callbackQueue.async {
125 | clientStreamWorkers.forEach { $0.stop() }
126 | invocationDidComplete(error)
| |- warning: capture of 'invocationDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
127 | }
128 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ReconnectableConnection.swift:139:21: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
137 | // TODO: not great but running on the connectionQueue deadlocks
138 | DispatchQueue.main.asyncAfter(deadline: .now() + nextAttemptInterval) {
139 | self.startInternal()
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
140 | }
141 | // running on a random (possibly main) queue but HubConnection will
[21/34] Compiling SignalRClient ServerInvocationHandler.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ReconnectableConnection.swift:70:17: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
68 | // Never synchronously respond to avoid upstream deadlocks based on async assumptions
69 | callbackQueue.async {
70 | sendDidComplete(SignalRError.connectionIsReconnecting)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
71 | }
72 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:39:17: warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
37 | self.invocationDidComplete = { result, error in
38 | callbackQueue.async {
39 | clientStreamWorkers.forEach { $0.stop() }
| `- warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
40 | invocationDidComplete(result, error)
41 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:10:19: note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
8 | import Foundation
9 |
10 | internal protocol ClientStreamWorker {
| `- note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
11 | var streamId: String { get }
12 | func start()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:40:17: warning: capture of 'invocationDidComplete' with non-sendable type '(T?, (any Error)?) -> Void' in a `@Sendable` closure
38 | callbackQueue.async {
39 | clientStreamWorkers.forEach { $0.stop() }
40 | invocationDidComplete(result, error)
| |- warning: capture of 'invocationDidComplete' with non-sendable type '(T?, (any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
41 | }
42 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:40:39: warning: capture of 'result' with non-sendable type 'T?' in a `@Sendable` closure
19 | }
20 |
21 | internal class InvocationHandler<T: Decodable>: ServerInvocationHandler {
| `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
22 | private let logger: Logger
23 | public private(set) var method: String
:
38 | callbackQueue.async {
39 | clientStreamWorkers.forEach { $0.stop() }
40 | invocationDidComplete(result, error)
| `- warning: capture of 'result' with non-sendable type 'T?' in a `@Sendable` closure
41 | }
42 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:122:67: warning: capture of 'streamItemReceived' with non-sendable type '(T) -> Void' in a `@Sendable` closure
120 | self.arguments = arguments
121 | self.clientStreamWorkers = clientStreamWorkers
122 | self.streamItemReceived = { item in callbackQueue.async { streamItemReceived(item) } }
| |- warning: capture of 'streamItemReceived' with non-sendable type '(T) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
123 | self.invocationDidComplete = { error in
124 | callbackQueue.async {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:122:86: warning: capture of 'item' with non-sendable type 'T' in a `@Sendable` closure
103 | }
104 |
105 | internal class StreamInvocationHandler<T: Decodable>: ServerInvocationHandler {
| `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
106 | private let logger: Logger
107 | public private(set) var method: String
:
120 | self.arguments = arguments
121 | self.clientStreamWorkers = clientStreamWorkers
122 | self.streamItemReceived = { item in callbackQueue.async { streamItemReceived(item) } }
| `- warning: capture of 'item' with non-sendable type 'T' in a `@Sendable` closure
123 | self.invocationDidComplete = { error in
124 | callbackQueue.async {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:125:17: warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
123 | self.invocationDidComplete = { error in
124 | callbackQueue.async {
125 | clientStreamWorkers.forEach { $0.stop() }
| `- warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
126 | invocationDidComplete(error)
127 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:10:19: note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
8 | import Foundation
9 |
10 | internal protocol ClientStreamWorker {
| `- note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
11 | var streamId: String { get }
12 | func start()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:126:17: warning: capture of 'invocationDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
124 | callbackQueue.async {
125 | clientStreamWorkers.forEach { $0.stop() }
126 | invocationDidComplete(error)
| |- warning: capture of 'invocationDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
127 | }
128 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ReconnectableConnection.swift:139:21: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
137 | // TODO: not great but running on the connectionQueue deadlocks
138 | DispatchQueue.main.asyncAfter(deadline: .now() + nextAttemptInterval) {
139 | self.startInternal()
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
140 | }
141 | // running on a random (possibly main) queue but HubConnection will
[22/34] Compiling SignalRClient SignalRError.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ReconnectableConnection.swift:70:17: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
68 | // Never synchronously respond to avoid upstream deadlocks based on async assumptions
69 | callbackQueue.async {
70 | sendDidComplete(SignalRError.connectionIsReconnecting)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
71 | }
72 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:39:17: warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
37 | self.invocationDidComplete = { result, error in
38 | callbackQueue.async {
39 | clientStreamWorkers.forEach { $0.stop() }
| `- warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
40 | invocationDidComplete(result, error)
41 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:10:19: note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
8 | import Foundation
9 |
10 | internal protocol ClientStreamWorker {
| `- note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
11 | var streamId: String { get }
12 | func start()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:40:17: warning: capture of 'invocationDidComplete' with non-sendable type '(T?, (any Error)?) -> Void' in a `@Sendable` closure
38 | callbackQueue.async {
39 | clientStreamWorkers.forEach { $0.stop() }
40 | invocationDidComplete(result, error)
| |- warning: capture of 'invocationDidComplete' with non-sendable type '(T?, (any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
41 | }
42 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:40:39: warning: capture of 'result' with non-sendable type 'T?' in a `@Sendable` closure
19 | }
20 |
21 | internal class InvocationHandler<T: Decodable>: ServerInvocationHandler {
| `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
22 | private let logger: Logger
23 | public private(set) var method: String
:
38 | callbackQueue.async {
39 | clientStreamWorkers.forEach { $0.stop() }
40 | invocationDidComplete(result, error)
| `- warning: capture of 'result' with non-sendable type 'T?' in a `@Sendable` closure
41 | }
42 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:122:67: warning: capture of 'streamItemReceived' with non-sendable type '(T) -> Void' in a `@Sendable` closure
120 | self.arguments = arguments
121 | self.clientStreamWorkers = clientStreamWorkers
122 | self.streamItemReceived = { item in callbackQueue.async { streamItemReceived(item) } }
| |- warning: capture of 'streamItemReceived' with non-sendable type '(T) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
123 | self.invocationDidComplete = { error in
124 | callbackQueue.async {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:122:86: warning: capture of 'item' with non-sendable type 'T' in a `@Sendable` closure
103 | }
104 |
105 | internal class StreamInvocationHandler<T: Decodable>: ServerInvocationHandler {
| `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
106 | private let logger: Logger
107 | public private(set) var method: String
:
120 | self.arguments = arguments
121 | self.clientStreamWorkers = clientStreamWorkers
122 | self.streamItemReceived = { item in callbackQueue.async { streamItemReceived(item) } }
| `- warning: capture of 'item' with non-sendable type 'T' in a `@Sendable` closure
123 | self.invocationDidComplete = { error in
124 | callbackQueue.async {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:125:17: warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
123 | self.invocationDidComplete = { error in
124 | callbackQueue.async {
125 | clientStreamWorkers.forEach { $0.stop() }
| `- warning: capture of 'clientStreamWorkers' with non-sendable type '[any ClientStreamWorker]' in a `@Sendable` closure
126 | invocationDidComplete(error)
127 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ClientStreamWorker.swift:10:19: note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
8 | import Foundation
9 |
10 | internal protocol ClientStreamWorker {
| `- note: protocol 'ClientStreamWorker' does not conform to the 'Sendable' protocol
11 | var streamId: String { get }
12 | func start()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:126:17: warning: capture of 'invocationDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
124 | callbackQueue.async {
125 | clientStreamWorkers.forEach { $0.stop() }
126 | invocationDidComplete(error)
| |- warning: capture of 'invocationDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
127 | }
128 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ReconnectableConnection.swift:139:21: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
137 | // TODO: not great but running on the connectionQueue deadlocks
138 | DispatchQueue.main.asyncAfter(deadline: .now() + nextAttemptInterval) {
139 | self.startInternal()
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
140 | }
141 | // running on a random (possibly main) queue but HubConnection will
[23/34] Compiling SignalRClient StreamHandle.swift
[24/34] Compiling SignalRClient TransferFormat.swift
[25/34] Compiling SignalRClient Transport.swift
[26/34] Compiling SignalRClient HttpResponse.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:173:25: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
171 | }
172 | self.callbackQueue.async {
173 | sendDidComplete(error)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
174 | }
175 | })
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:180:17: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
178 | logLevel: .error, message: "Sending to server side hub method '\(method)' failed. Error: \(error)")
179 | self.callbackQueue.async {
180 | sendDidComplete(error)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
181 | }
182 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:360:17: warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
358 | logger.log(logLevel: .error, message: "Invalid stream handle")
359 | callbackQueue.async {
360 | cancelDidFail(SignalRError.invalidOperation(message: "Invalid stream handle."))
| |- warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
361 | }
362 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:376:29: warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
374 | message: "Sending cancellation of server side streaming hub returned error: \(e)")
375 | self.callbackQueue.async {
376 | cancelDidFail(e)
| |- warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
377 | }
378 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:386:17: warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
384 | logLevel: .error, message: "Sending cancellation of server side streaming hub method failed: \(error)")
385 | self.callbackQueue.async {
386 | cancelDidFail(error)
| |- warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
387 | }
388 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:478:13: warning: capture of 'invocationHandler' with non-sendable type 'any ServerInvocationHandler' in a `@Sendable` closure
476 |
477 | callbackQueue.async {
478 | invocationHandler.raiseError(error: error)
| `- warning: capture of 'invocationHandler' with non-sendable type 'any ServerInvocationHandler' in a `@Sendable` closure
479 | }
480 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:11:19: note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
9 | import Foundation
10 |
11 | internal protocol ServerInvocationHandler {
| `- note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
12 | var method: String { get }
13 | var arguments: [Encodable] { get }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:486:17: warning: capture of 'errorHandler' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
484 | logger.log(logLevel: .error, message: "Attempting to send data before connection has been started.")
485 | callbackQueue.async {
486 | errorHandler(
| |- warning: capture of 'errorHandler' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
487 | SignalRError.invalidOperation(
488 | message: "Attempting to send data before connection has been started."))
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:513:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
511 | logger.log(logLevel: .error, message: "Parsing handshake response failed: \(e)")
512 | callbackQueue.async {
513 | self.delegate?.connectionDidFailToOpen(error: e)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
514 | }
515 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:519:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
517 | if originalHandshakeStatus.isReconnect {
518 | callbackQueue.async {
519 | self.delegate?.connectionDidReconnect()
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
520 | }
521 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:523:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
521 | } else {
522 | callbackQueue.async {
523 | self.delegate?.connectionDidOpen(hubConnection: self)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
524 | }
525 | resetKeepAlive()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:562:17: warning: capture of 'serverInvocationHandler' with non-sendable type '(any ServerInvocationHandler)?' in a `@Sendable` closure
560 | if serverInvocationHandler != nil {
561 | callbackQueue.async {
562 | serverInvocationHandler!.processCompletion(completionMessage: message)
| `- warning: capture of 'serverInvocationHandler' with non-sendable type '(any ServerInvocationHandler)?' in a `@Sendable` closure
563 | }
564 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:11:19: note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
9 | import Foundation
10 |
11 | internal protocol ServerInvocationHandler {
| `- note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
12 | var method: String { get }
13 | var arguments: [Encodable] { get }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:562:79: warning: capture of 'message' with non-sendable type 'CompletionMessage' in a `@Sendable` closure
560 | if serverInvocationHandler != nil {
561 | callbackQueue.async {
562 | serverInvocationHandler!.processCompletion(completionMessage: message)
| `- warning: capture of 'message' with non-sendable type 'CompletionMessage' in a `@Sendable` closure
563 | }
564 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:164:14: note: class 'CompletionMessage' does not conform to the 'Sendable' protocol
162 | }
163 |
164 | public class CompletionMessage: HubMessage, Codable {
| `- note: class 'CompletionMessage' does not conform to the 'Sendable' protocol
165 | public let type = MessageType.Completion
166 | public let invocationId: String
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:562:17: warning: reference to captured var 'serverInvocationHandler' in concurrently-executing code
560 | if serverInvocationHandler != nil {
561 | callbackQueue.async {
562 | serverInvocationHandler!.processCompletion(completionMessage: message)
| `- warning: reference to captured var 'serverInvocationHandler' in concurrently-executing code
563 | }
564 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:596:25: warning: capture of 'callback' with non-sendable type '((ArgumentExtractor) throws -> Void)?' in a `@Sendable` closure
594 | callbackQueue.async {
595 | do {
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
| |- warning: capture of 'callback' with non-sendable type '((ArgumentExtractor) throws -> Void)?' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
597 | } catch {
598 | self.logger.log(
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:596:78: warning: capture of 'message' with non-sendable type 'ClientInvocationMessage' in a `@Sendable` closure
594 | callbackQueue.async {
595 | do {
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
| `- warning: capture of 'message' with non-sendable type 'ClientInvocationMessage' in a `@Sendable` closure
597 | } catch {
598 | self.logger.log(
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:80:14: note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
78 | }
79 |
80 | public class ClientInvocationMessage: HubMessage, Decodable {
| `- note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
81 | public let type = MessageType.Invocation
82 | public let target: String
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:598:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
597 | } catch {
598 | self.logger.log(
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
599 | logLevel: .error,
600 | message: "Invoking client hub method \(message.target) failed due to: \(error)")
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:596:25: warning: reference to captured var 'callback' in concurrently-executing code
594 | callbackQueue.async {
595 | do {
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
| `- warning: reference to captured var 'callback' in concurrently-executing code
597 | } catch {
598 | self.logger.log(
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:600:64: warning: implicit capture of 'message' requires that 'ClientInvocationMessage' conforms to `Sendable`; this is an error in the Swift 6 language mode
598 | self.logger.log(
599 | logLevel: .error,
600 | message: "Invoking client hub method \(message.target) failed due to: \(error)")
| `- warning: implicit capture of 'message' requires that 'ClientInvocationMessage' conforms to `Sendable`; this is an error in the Swift 6 language mode
601 | }
602 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:80:14: note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
78 | }
79 |
80 | public class ClientInvocationMessage: HubMessage, Decodable {
| `- note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
81 | public let type = MessageType.Invocation
82 | public let target: String
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:628:13: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
626 | handshakeStatus = .needsHandling(false)
627 | callbackQueue.async {
628 | self.delegate?.connectionDidClose(error: error)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
629 | }
630 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:634:13: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
632 | fileprivate func connectionDidFailToOpen(error: Error) {
633 | callbackQueue.async {
634 | self.delegate?.connectionDidFailToOpen(error: error)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
635 | }
636 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:641:13: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
639 | handshakeStatus = .needsHandling(true)
640 | callbackQueue.async {
641 | self.delegate?.connectionWillReconnect(error: error)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
642 | }
643 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:268:16: warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
262 | }
263 |
264 | public class PingMessage: HubMessage, Encodable {
| `- note: class 'PingMessage' does not conform to the 'Sendable' protocol
265 | public let type = MessageType.Ping
266 | private init() {}
267 |
268 | static let instance = PingMessage()
| |- warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'instance' 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
269 | }
270 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
[27/34] Compiling SignalRClient HubConnection.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:173:25: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
171 | }
172 | self.callbackQueue.async {
173 | sendDidComplete(error)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
174 | }
175 | })
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:180:17: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
178 | logLevel: .error, message: "Sending to server side hub method '\(method)' failed. Error: \(error)")
179 | self.callbackQueue.async {
180 | sendDidComplete(error)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
181 | }
182 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:360:17: warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
358 | logger.log(logLevel: .error, message: "Invalid stream handle")
359 | callbackQueue.async {
360 | cancelDidFail(SignalRError.invalidOperation(message: "Invalid stream handle."))
| |- warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
361 | }
362 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:376:29: warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
374 | message: "Sending cancellation of server side streaming hub returned error: \(e)")
375 | self.callbackQueue.async {
376 | cancelDidFail(e)
| |- warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
377 | }
378 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:386:17: warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
384 | logLevel: .error, message: "Sending cancellation of server side streaming hub method failed: \(error)")
385 | self.callbackQueue.async {
386 | cancelDidFail(error)
| |- warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
387 | }
388 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:478:13: warning: capture of 'invocationHandler' with non-sendable type 'any ServerInvocationHandler' in a `@Sendable` closure
476 |
477 | callbackQueue.async {
478 | invocationHandler.raiseError(error: error)
| `- warning: capture of 'invocationHandler' with non-sendable type 'any ServerInvocationHandler' in a `@Sendable` closure
479 | }
480 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:11:19: note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
9 | import Foundation
10 |
11 | internal protocol ServerInvocationHandler {
| `- note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
12 | var method: String { get }
13 | var arguments: [Encodable] { get }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:486:17: warning: capture of 'errorHandler' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
484 | logger.log(logLevel: .error, message: "Attempting to send data before connection has been started.")
485 | callbackQueue.async {
486 | errorHandler(
| |- warning: capture of 'errorHandler' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
487 | SignalRError.invalidOperation(
488 | message: "Attempting to send data before connection has been started."))
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:513:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
511 | logger.log(logLevel: .error, message: "Parsing handshake response failed: \(e)")
512 | callbackQueue.async {
513 | self.delegate?.connectionDidFailToOpen(error: e)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
514 | }
515 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:519:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
517 | if originalHandshakeStatus.isReconnect {
518 | callbackQueue.async {
519 | self.delegate?.connectionDidReconnect()
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
520 | }
521 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:523:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
521 | } else {
522 | callbackQueue.async {
523 | self.delegate?.connectionDidOpen(hubConnection: self)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
524 | }
525 | resetKeepAlive()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:562:17: warning: capture of 'serverInvocationHandler' with non-sendable type '(any ServerInvocationHandler)?' in a `@Sendable` closure
560 | if serverInvocationHandler != nil {
561 | callbackQueue.async {
562 | serverInvocationHandler!.processCompletion(completionMessage: message)
| `- warning: capture of 'serverInvocationHandler' with non-sendable type '(any ServerInvocationHandler)?' in a `@Sendable` closure
563 | }
564 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:11:19: note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
9 | import Foundation
10 |
11 | internal protocol ServerInvocationHandler {
| `- note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
12 | var method: String { get }
13 | var arguments: [Encodable] { get }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:562:79: warning: capture of 'message' with non-sendable type 'CompletionMessage' in a `@Sendable` closure
560 | if serverInvocationHandler != nil {
561 | callbackQueue.async {
562 | serverInvocationHandler!.processCompletion(completionMessage: message)
| `- warning: capture of 'message' with non-sendable type 'CompletionMessage' in a `@Sendable` closure
563 | }
564 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:164:14: note: class 'CompletionMessage' does not conform to the 'Sendable' protocol
162 | }
163 |
164 | public class CompletionMessage: HubMessage, Codable {
| `- note: class 'CompletionMessage' does not conform to the 'Sendable' protocol
165 | public let type = MessageType.Completion
166 | public let invocationId: String
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:562:17: warning: reference to captured var 'serverInvocationHandler' in concurrently-executing code
560 | if serverInvocationHandler != nil {
561 | callbackQueue.async {
562 | serverInvocationHandler!.processCompletion(completionMessage: message)
| `- warning: reference to captured var 'serverInvocationHandler' in concurrently-executing code
563 | }
564 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:596:25: warning: capture of 'callback' with non-sendable type '((ArgumentExtractor) throws -> Void)?' in a `@Sendable` closure
594 | callbackQueue.async {
595 | do {
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
| |- warning: capture of 'callback' with non-sendable type '((ArgumentExtractor) throws -> Void)?' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
597 | } catch {
598 | self.logger.log(
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:596:78: warning: capture of 'message' with non-sendable type 'ClientInvocationMessage' in a `@Sendable` closure
594 | callbackQueue.async {
595 | do {
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
| `- warning: capture of 'message' with non-sendable type 'ClientInvocationMessage' in a `@Sendable` closure
597 | } catch {
598 | self.logger.log(
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:80:14: note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
78 | }
79 |
80 | public class ClientInvocationMessage: HubMessage, Decodable {
| `- note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
81 | public let type = MessageType.Invocation
82 | public let target: String
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:598:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
597 | } catch {
598 | self.logger.log(
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
599 | logLevel: .error,
600 | message: "Invoking client hub method \(message.target) failed due to: \(error)")
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:596:25: warning: reference to captured var 'callback' in concurrently-executing code
594 | callbackQueue.async {
595 | do {
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
| `- warning: reference to captured var 'callback' in concurrently-executing code
597 | } catch {
598 | self.logger.log(
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:600:64: warning: implicit capture of 'message' requires that 'ClientInvocationMessage' conforms to `Sendable`; this is an error in the Swift 6 language mode
598 | self.logger.log(
599 | logLevel: .error,
600 | message: "Invoking client hub method \(message.target) failed due to: \(error)")
| `- warning: implicit capture of 'message' requires that 'ClientInvocationMessage' conforms to `Sendable`; this is an error in the Swift 6 language mode
601 | }
602 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:80:14: note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
78 | }
79 |
80 | public class ClientInvocationMessage: HubMessage, Decodable {
| `- note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
81 | public let type = MessageType.Invocation
82 | public let target: String
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:628:13: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
626 | handshakeStatus = .needsHandling(false)
627 | callbackQueue.async {
628 | self.delegate?.connectionDidClose(error: error)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
629 | }
630 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:634:13: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
632 | fileprivate func connectionDidFailToOpen(error: Error) {
633 | callbackQueue.async {
634 | self.delegate?.connectionDidFailToOpen(error: error)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
635 | }
636 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:641:13: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
639 | handshakeStatus = .needsHandling(true)
640 | callbackQueue.async {
641 | self.delegate?.connectionWillReconnect(error: error)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
642 | }
643 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:268:16: warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
262 | }
263 |
264 | public class PingMessage: HubMessage, Encodable {
| `- note: class 'PingMessage' does not conform to the 'Sendable' protocol
265 | public let type = MessageType.Ping
266 | private init() {}
267 |
268 | static let instance = PingMessage()
| |- warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'instance' 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
269 | }
270 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
[28/34] Compiling SignalRClient HubConnectionBuilder.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:173:25: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
171 | }
172 | self.callbackQueue.async {
173 | sendDidComplete(error)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
174 | }
175 | })
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:180:17: warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
178 | logLevel: .error, message: "Sending to server side hub method '\(method)' failed. Error: \(error)")
179 | self.callbackQueue.async {
180 | sendDidComplete(error)
| |- warning: capture of 'sendDidComplete' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
181 | }
182 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:360:17: warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
358 | logger.log(logLevel: .error, message: "Invalid stream handle")
359 | callbackQueue.async {
360 | cancelDidFail(SignalRError.invalidOperation(message: "Invalid stream handle."))
| |- warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
361 | }
362 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:376:29: warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
374 | message: "Sending cancellation of server side streaming hub returned error: \(e)")
375 | self.callbackQueue.async {
376 | cancelDidFail(e)
| |- warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
377 | }
378 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:386:17: warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
384 | logLevel: .error, message: "Sending cancellation of server side streaming hub method failed: \(error)")
385 | self.callbackQueue.async {
386 | cancelDidFail(error)
| |- warning: capture of 'cancelDidFail' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
387 | }
388 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:478:13: warning: capture of 'invocationHandler' with non-sendable type 'any ServerInvocationHandler' in a `@Sendable` closure
476 |
477 | callbackQueue.async {
478 | invocationHandler.raiseError(error: error)
| `- warning: capture of 'invocationHandler' with non-sendable type 'any ServerInvocationHandler' in a `@Sendable` closure
479 | }
480 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:11:19: note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
9 | import Foundation
10 |
11 | internal protocol ServerInvocationHandler {
| `- note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
12 | var method: String { get }
13 | var arguments: [Encodable] { get }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:486:17: warning: capture of 'errorHandler' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
484 | logger.log(logLevel: .error, message: "Attempting to send data before connection has been started.")
485 | callbackQueue.async {
486 | errorHandler(
| |- warning: capture of 'errorHandler' with non-sendable type '(any Error) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
487 | SignalRError.invalidOperation(
488 | message: "Attempting to send data before connection has been started."))
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:513:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
511 | logger.log(logLevel: .error, message: "Parsing handshake response failed: \(e)")
512 | callbackQueue.async {
513 | self.delegate?.connectionDidFailToOpen(error: e)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
514 | }
515 | return
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:519:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
517 | if originalHandshakeStatus.isReconnect {
518 | callbackQueue.async {
519 | self.delegate?.connectionDidReconnect()
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
520 | }
521 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:523:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
521 | } else {
522 | callbackQueue.async {
523 | self.delegate?.connectionDidOpen(hubConnection: self)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
524 | }
525 | resetKeepAlive()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:562:17: warning: capture of 'serverInvocationHandler' with non-sendable type '(any ServerInvocationHandler)?' in a `@Sendable` closure
560 | if serverInvocationHandler != nil {
561 | callbackQueue.async {
562 | serverInvocationHandler!.processCompletion(completionMessage: message)
| `- warning: capture of 'serverInvocationHandler' with non-sendable type '(any ServerInvocationHandler)?' in a `@Sendable` closure
563 | }
564 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/ServerInvocationHandler.swift:11:19: note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
9 | import Foundation
10 |
11 | internal protocol ServerInvocationHandler {
| `- note: protocol 'ServerInvocationHandler' does not conform to the 'Sendable' protocol
12 | var method: String { get }
13 | var arguments: [Encodable] { get }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:562:79: warning: capture of 'message' with non-sendable type 'CompletionMessage' in a `@Sendable` closure
560 | if serverInvocationHandler != nil {
561 | callbackQueue.async {
562 | serverInvocationHandler!.processCompletion(completionMessage: message)
| `- warning: capture of 'message' with non-sendable type 'CompletionMessage' in a `@Sendable` closure
563 | }
564 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:164:14: note: class 'CompletionMessage' does not conform to the 'Sendable' protocol
162 | }
163 |
164 | public class CompletionMessage: HubMessage, Codable {
| `- note: class 'CompletionMessage' does not conform to the 'Sendable' protocol
165 | public let type = MessageType.Completion
166 | public let invocationId: String
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:562:17: warning: reference to captured var 'serverInvocationHandler' in concurrently-executing code
560 | if serverInvocationHandler != nil {
561 | callbackQueue.async {
562 | serverInvocationHandler!.processCompletion(completionMessage: message)
| `- warning: reference to captured var 'serverInvocationHandler' in concurrently-executing code
563 | }
564 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:596:25: warning: capture of 'callback' with non-sendable type '((ArgumentExtractor) throws -> Void)?' in a `@Sendable` closure
594 | callbackQueue.async {
595 | do {
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
| |- warning: capture of 'callback' with non-sendable type '((ArgumentExtractor) throws -> Void)?' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
597 | } catch {
598 | self.logger.log(
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:596:78: warning: capture of 'message' with non-sendable type 'ClientInvocationMessage' in a `@Sendable` closure
594 | callbackQueue.async {
595 | do {
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
| `- warning: capture of 'message' with non-sendable type 'ClientInvocationMessage' in a `@Sendable` closure
597 | } catch {
598 | self.logger.log(
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:80:14: note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
78 | }
79 |
80 | public class ClientInvocationMessage: HubMessage, Decodable {
| `- note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
81 | public let type = MessageType.Invocation
82 | public let target: String
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:598:21: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
597 | } catch {
598 | self.logger.log(
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
599 | logLevel: .error,
600 | message: "Invoking client hub method \(message.target) failed due to: \(error)")
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:596:25: warning: reference to captured var 'callback' in concurrently-executing code
594 | callbackQueue.async {
595 | do {
596 | try callback!(ArgumentExtractor(clientInvocationMessage: message))
| `- warning: reference to captured var 'callback' in concurrently-executing code
597 | } catch {
598 | self.logger.log(
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:600:64: warning: implicit capture of 'message' requires that 'ClientInvocationMessage' conforms to `Sendable`; this is an error in the Swift 6 language mode
598 | self.logger.log(
599 | logLevel: .error,
600 | message: "Invoking client hub method \(message.target) failed due to: \(error)")
| `- warning: implicit capture of 'message' requires that 'ClientInvocationMessage' conforms to `Sendable`; this is an error in the Swift 6 language mode
601 | }
602 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:80:14: note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
78 | }
79 |
80 | public class ClientInvocationMessage: HubMessage, Decodable {
| `- note: class 'ClientInvocationMessage' does not conform to the 'Sendable' protocol
81 | public let type = MessageType.Invocation
82 | public let target: String
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:628:13: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
626 | handshakeStatus = .needsHandling(false)
627 | callbackQueue.async {
628 | self.delegate?.connectionDidClose(error: error)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
629 | }
630 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:634:13: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
632 | fileprivate func connectionDidFailToOpen(error: Error) {
633 | callbackQueue.async {
634 | self.delegate?.connectionDidFailToOpen(error: error)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
635 | }
636 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubConnection.swift:641:13: warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
13 | ///
14 | /// - note: You need to maintain the reference to the `HubConnection` instance until the connection is stopped
15 | public class HubConnection {
| `- note: class 'HubConnection' does not conform to the 'Sendable' protocol
16 |
17 | private var invocationId: Int = 0
:
639 | handshakeStatus = .needsHandling(true)
640 | callbackQueue.async {
641 | self.delegate?.connectionWillReconnect(error: error)
| `- warning: capture of 'self' with non-sendable type 'HubConnection' in a `@Sendable` closure
642 | }
643 | }
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:268:16: warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
262 | }
263 |
264 | public class PingMessage: HubMessage, Encodable {
| `- note: class 'PingMessage' does not conform to the 'Sendable' protocol
265 | public let type = MessageType.Ping
266 | private init() {}
267 |
268 | static let instance = PingMessage()
| |- warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'instance' 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
269 | }
270 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
[29/34] Compiling SignalRClient DefaultHttpClient.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:79:16: warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
77 |
78 | private class DefaultHttpClientSessionDelegate: NSObject, URLSessionDelegate {
79 | static var shared = DefaultHttpClientSessionDelegate()
| |- warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'shared' to a 'let' constant to make 'Sendable' shared state immutable
| |- 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
80 |
81 | var authenticationChallengeHandler:
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:78:15: warning: non-final class 'DefaultHttpClientSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
76 | }
77 |
78 | private class DefaultHttpClientSessionDelegate: NSObject, URLSessionDelegate {
| `- warning: non-final class 'DefaultHttpClientSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
79 | static var shared = DefaultHttpClientSessionDelegate()
80 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:81:9: warning: stored property 'authenticationChallengeHandler' of 'Sendable'-conforming class 'DefaultHttpClientSessionDelegate' is mutable; this is an error in the Swift 6 language mode
79 | static var shared = DefaultHttpClientSessionDelegate()
80 |
81 | var authenticationChallengeHandler:
| `- warning: stored property 'authenticationChallengeHandler' of 'Sendable'-conforming class 'DefaultHttpClientSessionDelegate' is mutable; this is an error in the Swift 6 language mode
82 | (
83 | (
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:60:17: warning: capture of 'completionHandler' with non-sendable type '(HttpResponse?, (any Error)?) -> Void' in a `@Sendable` closure
58 | }
59 |
60 | completionHandler(resp, error)
| |- warning: capture of 'completionHandler' with non-sendable type '(HttpResponse?, (any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
61 | }
62 | ).resume()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:18:23: warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
16 | }
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
| |- warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'longPolling' 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
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
[30/34] Compiling SignalRClient DefaultTransportFactory.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:79:16: warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
77 |
78 | private class DefaultHttpClientSessionDelegate: NSObject, URLSessionDelegate {
79 | static var shared = DefaultHttpClientSessionDelegate()
| |- warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'shared' to a 'let' constant to make 'Sendable' shared state immutable
| |- 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
80 |
81 | var authenticationChallengeHandler:
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:78:15: warning: non-final class 'DefaultHttpClientSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
76 | }
77 |
78 | private class DefaultHttpClientSessionDelegate: NSObject, URLSessionDelegate {
| `- warning: non-final class 'DefaultHttpClientSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
79 | static var shared = DefaultHttpClientSessionDelegate()
80 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:81:9: warning: stored property 'authenticationChallengeHandler' of 'Sendable'-conforming class 'DefaultHttpClientSessionDelegate' is mutable; this is an error in the Swift 6 language mode
79 | static var shared = DefaultHttpClientSessionDelegate()
80 |
81 | var authenticationChallengeHandler:
| `- warning: stored property 'authenticationChallengeHandler' of 'Sendable'-conforming class 'DefaultHttpClientSessionDelegate' is mutable; this is an error in the Swift 6 language mode
82 | (
83 | (
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:60:17: warning: capture of 'completionHandler' with non-sendable type '(HttpResponse?, (any Error)?) -> Void' in a `@Sendable` closure
58 | }
59 |
60 | completionHandler(resp, error)
| |- warning: capture of 'completionHandler' with non-sendable type '(HttpResponse?, (any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
61 | }
62 | ).resume()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:18:23: warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
16 | }
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
| |- warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'longPolling' 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
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
[31/34] Compiling SignalRClient HandshakeProtocol.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:79:16: warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
77 |
78 | private class DefaultHttpClientSessionDelegate: NSObject, URLSessionDelegate {
79 | static var shared = DefaultHttpClientSessionDelegate()
| |- warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'shared' to a 'let' constant to make 'Sendable' shared state immutable
| |- 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
80 |
81 | var authenticationChallengeHandler:
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:78:15: warning: non-final class 'DefaultHttpClientSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
76 | }
77 |
78 | private class DefaultHttpClientSessionDelegate: NSObject, URLSessionDelegate {
| `- warning: non-final class 'DefaultHttpClientSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
79 | static var shared = DefaultHttpClientSessionDelegate()
80 |
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:81:9: warning: stored property 'authenticationChallengeHandler' of 'Sendable'-conforming class 'DefaultHttpClientSessionDelegate' is mutable; this is an error in the Swift 6 language mode
79 | static var shared = DefaultHttpClientSessionDelegate()
80 |
81 | var authenticationChallengeHandler:
| `- warning: stored property 'authenticationChallengeHandler' of 'Sendable'-conforming class 'DefaultHttpClientSessionDelegate' is mutable; this is an error in the Swift 6 language mode
82 | (
83 | (
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/DefaultHttpClient.swift:60:17: warning: capture of 'completionHandler' with non-sendable type '(HttpResponse?, (any Error)?) -> Void' in a `@Sendable` closure
58 | }
59 |
60 | completionHandler(resp, error)
| |- warning: capture of 'completionHandler' with non-sendable type '(HttpResponse?, (any Error)?) -> Void' in a `@Sendable` closure
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
61 | }
62 | ).resume()
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:20:23: warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
| |- warning: static property 'webSockets' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'webSockets' 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
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:18:23: warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
16 | }
17 |
18 | public static let longPolling = TransportType(rawValue: 1 << 0)
| |- warning: static property 'longPolling' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'longPolling' 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
19 | static let serverSentEvents = TransportType(rawValue: 1 << 1) // Not supported
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/TransportType.swift:22:23: warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
9 | import Foundation
10 |
11 | public struct TransportType: OptionSet {
| `- note: consider making struct 'TransportType' conform to the 'Sendable' protocol
12 | public let rawValue: Int
13 |
:
20 | public static let webSockets = TransportType(rawValue: 1 << 2)
21 |
22 | public static let all: TransportType = [.longPolling, .webSockets]
| |- warning: static property 'all' is not concurrency-safe because non-'Sendable' type 'TransportType' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'all' 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 |
[32/34] Compiling SignalRClient HubProtocol.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:268:16: warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
262 | }
263 |
264 | public class PingMessage: HubMessage, Encodable {
| `- note: class 'PingMessage' does not conform to the 'Sendable' protocol
265 | public let type = MessageType.Ping
266 | private init() {}
267 |
268 | static let instance = PingMessage()
| |- warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'instance' 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
269 | }
270 |
[33/34] Compiling SignalRClient JSONHubProtocol.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:268:16: warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
262 | }
263 |
264 | public class PingMessage: HubMessage, Encodable {
| `- note: class 'PingMessage' does not conform to the 'Sendable' protocol
265 | public let type = MessageType.Ping
266 | private init() {}
267 |
268 | static let instance = PingMessage()
| |- warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'instance' 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
269 | }
270 |
[34/34] Compiling SignalRClient Logger.swift
/Users/admin/builder/spi-builder-workspace/Sources/SignalRClient/HubProtocol.swift:268:16: warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
262 | }
263 |
264 | public class PingMessage: HubMessage, Encodable {
| `- note: class 'PingMessage' does not conform to the 'Sendable' protocol
265 | public let type = MessageType.Ping
266 | private init() {}
267 |
268 | static let instance = PingMessage()
| |- warning: static property 'instance' is not concurrency-safe because non-'Sendable' type 'PingMessage' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'instance' 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
269 | }
270 |
Build complete! (15.18s)
Build complete.
{
"dependencies" : [
],
"manifest_display_name" : "SignalRClient",
"name" : "SignalRClient",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
],
"products" : [
{
"name" : "SignalRClient",
"targets" : [
"SignalRClient"
],
"type" : {
"library" : [
"automatic"
]
}
}
],
"swift_languages_versions" : [
"4",
"4.2",
"5"
],
"targets" : [
{
"c99name" : "SignalRClientTests",
"module_type" : "SwiftTarget",
"name" : "SignalRClientTests",
"path" : "Tests/SignalRClientTests",
"sources" : [
"ClientStreamWorkerTests.swift",
"Constants.swift",
"Fakes.swift",
"HandshakeProtocolTests.swift",
"HttpConnectionTests.swift",
"HubConnectionExtensionsTests.swift",
"HubConnectionTests.swift",
"HubProtocolFake.swift",
"JSONHubProtocolTests.swift",
"LoggerTests.swift",
"LongPollingTransportTests.swift",
"NegotiationResponseTests.swift",
"ReconnectPolicyTests.swift",
"ReconnectableConnectionTests.swift",
"ServerInvocationHandlerTests.swift",
"TestTransport.swift",
"TestTransportDelegate.swift",
"TestUtils.swift",
"TransportTypeTests.swift",
"WebsocketsTransportTests.swift"
],
"target_dependencies" : [
"SignalRClient"
],
"type" : "test"
},
{
"c99name" : "SignalRClient",
"module_type" : "SwiftTarget",
"name" : "SignalRClient",
"path" : "Sources/SignalRClient",
"product_memberships" : [
"SignalRClient"
],
"sources" : [
"ClientStreamWorker.swift",
"CodableHelpers.swift",
"Connection.swift",
"ConnectionDelegate.swift",
"DefaultHttpClient.swift",
"DefaultTransportFactory.swift",
"HandshakeProtocol.swift",
"HttpClientProtocol.swift",
"HttpConnection.swift",
"HttpConnectionOptions.swift",
"HttpResponse.swift",
"HubConnection.swift",
"HubConnectionBuilder.swift",
"HubConnectionDelegate.swift",
"HubConnectionExtensions.swift",
"HubConnectionOptions.swift",
"HubProtocol.swift",
"JSONHubProtocol.swift",
"Logger.swift",
"LongPollingTransport.swift",
"NegotiationResponse.swift",
"ReconnectPolicy.swift",
"ReconnectableConnection.swift",
"ServerInvocationHandler.swift",
"SignalRError.swift",
"StreamHandle.swift",
"TransferFormat.swift",
"Transport.swift",
"TransportDelegate.swift",
"TransportType.swift",
"WebsocketsTransport.swift"
],
"type" : "library"
}
],
"tools_version" : "5.0"
}
Done.