The Swift Package Index logo.Swift Package Index

Build Information

Successful build of HAKit, reference 0.4.19 (0535d4), with Swift 6.1 for macOS (SPM) on 13 Oct 2026 09:29:36 UTC.

Swift 6 data race errors: 44

Build Command

env DEVELOPER_DIR=/Applications/Xcode-16.3.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete -Xswiftc -enable-upcoming-feature -Xswiftc StrictConcurrency -Xswiftc -enable-upcoming-feature -Xswiftc DisableOutwardActorInference -Xswiftc -enable-upcoming-feature -Xswiftc GlobalActorIsolatedTypesUsability -Xswiftc -enable-upcoming-feature -Xswiftc InferSendableFromCaptures

Build Log

 79 |     public static var platformDiscovered: Self = "platform_discovered"
 80 |     /// `service_registered`
 81 |     public static var serviceRegistered: Self = "service_registered"
    |                       |- warning: static property 'serviceRegistered' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'serviceRegistered' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'serviceRegistered' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 82 |     /// `service_removed`
 83 |     public static var serviceRemoved: Self = "service_removed"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:83:23: warning: static property 'serviceRemoved' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 81 |     public static var serviceRegistered: Self = "service_registered"
 82 |     /// `service_removed`
 83 |     public static var serviceRemoved: Self = "service_removed"
    |                       |- warning: static property 'serviceRemoved' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'serviceRemoved' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'serviceRemoved' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 84 |     /// `shopping_list_updated`
 85 |     public static var shoppingListUpdated: Self = "shopping_list_updated"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:85:23: warning: static property 'shoppingListUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 83 |     public static var serviceRemoved: Self = "service_removed"
 84 |     /// `shopping_list_updated`
 85 |     public static var shoppingListUpdated: Self = "shopping_list_updated"
    |                       |- warning: static property 'shoppingListUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'shoppingListUpdated' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'shoppingListUpdated' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 86 |     /// `state_changed`
 87 |     public static var stateChanged: Self = "state_changed"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:87:23: warning: static property 'stateChanged' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 85 |     public static var shoppingListUpdated: Self = "shopping_list_updated"
 86 |     /// `state_changed`
 87 |     public static var stateChanged: Self = "state_changed"
    |                       |- warning: static property 'stateChanged' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'stateChanged' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'stateChanged' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 88 |     /// `themes_updated`
 89 |     public static var themesUpdated: Self = "themes_updated"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:89:23: warning: static property 'themesUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 87 |     public static var stateChanged: Self = "state_changed"
 88 |     /// `themes_updated`
 89 |     public static var themesUpdated: Self = "themes_updated"
    |                       |- warning: static property 'themesUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'themesUpdated' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'themesUpdated' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 90 |     /// `timer_out_of_sync`
 91 |     public static var timerOutOfSync: Self = "timer_out_of_sync"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:91:23: warning: static property 'timerOutOfSync' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 89 |     public static var themesUpdated: Self = "themes_updated"
 90 |     /// `timer_out_of_sync`
 91 |     public static var timerOutOfSync: Self = "timer_out_of_sync"
    |                       |- warning: static property 'timerOutOfSync' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'timerOutOfSync' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'timerOutOfSync' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 92 | }
 93 |
[92/102] Compiling HAKit Services.swift
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:56:23: warning: static property 'all' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 54 |
 55 |     /// All events
 56 |     public static var all: Self = nil
    |                       |- warning: static property 'all' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'all' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'all' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 57 |
 58 |     // rule of thumb: any event available in `core` is valid for this list
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:61:23: warning: static property 'callService' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 59 |
 60 |     /// `call_service`
 61 |     public static var callService: Self = "call_service"
    |                       |- warning: static property 'callService' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'callService' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'callService' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 62 |     /// `component_loaded`
 63 |     public static var componentLoaded: Self = "component_loaded"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:63:23: warning: static property 'componentLoaded' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 61 |     public static var callService: Self = "call_service"
 62 |     /// `component_loaded`
 63 |     public static var componentLoaded: Self = "component_loaded"
    |                       |- warning: static property 'componentLoaded' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'componentLoaded' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'componentLoaded' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 64 |     /// `core_config_updated`
 65 |     public static var coreConfigUpdated: Self = "core_config_updated"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:65:23: warning: static property 'coreConfigUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 63 |     public static var componentLoaded: Self = "component_loaded"
 64 |     /// `core_config_updated`
 65 |     public static var coreConfigUpdated: Self = "core_config_updated"
    |                       |- warning: static property 'coreConfigUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'coreConfigUpdated' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'coreConfigUpdated' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 66 |     /// `homeassistant_close`
 67 |     public static var homeassistantClose: Self = "homeassistant_close"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:67:23: warning: static property 'homeassistantClose' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 65 |     public static var coreConfigUpdated: Self = "core_config_updated"
 66 |     /// `homeassistant_close`
 67 |     public static var homeassistantClose: Self = "homeassistant_close"
    |                       |- warning: static property 'homeassistantClose' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'homeassistantClose' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'homeassistantClose' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 68 |     /// `homeassistant_final_write`
 69 |     public static var homeassistantFinalWrite: Self = "homeassistant_final_write"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:69:23: warning: static property 'homeassistantFinalWrite' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 67 |     public static var homeassistantClose: Self = "homeassistant_close"
 68 |     /// `homeassistant_final_write`
 69 |     public static var homeassistantFinalWrite: Self = "homeassistant_final_write"
    |                       |- warning: static property 'homeassistantFinalWrite' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'homeassistantFinalWrite' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'homeassistantFinalWrite' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 70 |     /// `homeassistant_start`
 71 |     public static var homeassistantStart: Self = "homeassistant_start"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:71:23: warning: static property 'homeassistantStart' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 69 |     public static var homeassistantFinalWrite: Self = "homeassistant_final_write"
 70 |     /// `homeassistant_start`
 71 |     public static var homeassistantStart: Self = "homeassistant_start"
    |                       |- warning: static property 'homeassistantStart' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'homeassistantStart' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'homeassistantStart' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 72 |     /// `homeassistant_started`
 73 |     public static var homeassistantStarted: Self = "homeassistant_started"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:73:23: warning: static property 'homeassistantStarted' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 71 |     public static var homeassistantStart: Self = "homeassistant_start"
 72 |     /// `homeassistant_started`
 73 |     public static var homeassistantStarted: Self = "homeassistant_started"
    |                       |- warning: static property 'homeassistantStarted' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'homeassistantStarted' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'homeassistantStarted' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 74 |     /// `homeassistant_stop`
 75 |     public static var homeassistantStop: Self = "homeassistant_stop"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:75:23: warning: static property 'homeassistantStop' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 73 |     public static var homeassistantStarted: Self = "homeassistant_started"
 74 |     /// `homeassistant_stop`
 75 |     public static var homeassistantStop: Self = "homeassistant_stop"
    |                       |- warning: static property 'homeassistantStop' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'homeassistantStop' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'homeassistantStop' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 76 |     /// `logbook_entry`
 77 |     public static var logbookEntry: Self = "logbook_entry"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:77:23: warning: static property 'logbookEntry' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 75 |     public static var homeassistantStop: Self = "homeassistant_stop"
 76 |     /// `logbook_entry`
 77 |     public static var logbookEntry: Self = "logbook_entry"
    |                       |- warning: static property 'logbookEntry' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'logbookEntry' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'logbookEntry' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 78 |     /// `platform_discovered`
 79 |     public static var platformDiscovered: Self = "platform_discovered"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:79:23: warning: static property 'platformDiscovered' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 77 |     public static var logbookEntry: Self = "logbook_entry"
 78 |     /// `platform_discovered`
 79 |     public static var platformDiscovered: Self = "platform_discovered"
    |                       |- warning: static property 'platformDiscovered' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'platformDiscovered' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'platformDiscovered' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 80 |     /// `service_registered`
 81 |     public static var serviceRegistered: Self = "service_registered"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:81:23: warning: static property 'serviceRegistered' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 79 |     public static var platformDiscovered: Self = "platform_discovered"
 80 |     /// `service_registered`
 81 |     public static var serviceRegistered: Self = "service_registered"
    |                       |- warning: static property 'serviceRegistered' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'serviceRegistered' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'serviceRegistered' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 82 |     /// `service_removed`
 83 |     public static var serviceRemoved: Self = "service_removed"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:83:23: warning: static property 'serviceRemoved' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 81 |     public static var serviceRegistered: Self = "service_registered"
 82 |     /// `service_removed`
 83 |     public static var serviceRemoved: Self = "service_removed"
    |                       |- warning: static property 'serviceRemoved' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'serviceRemoved' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'serviceRemoved' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 84 |     /// `shopping_list_updated`
 85 |     public static var shoppingListUpdated: Self = "shopping_list_updated"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:85:23: warning: static property 'shoppingListUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 83 |     public static var serviceRemoved: Self = "service_removed"
 84 |     /// `shopping_list_updated`
 85 |     public static var shoppingListUpdated: Self = "shopping_list_updated"
    |                       |- warning: static property 'shoppingListUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'shoppingListUpdated' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'shoppingListUpdated' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 86 |     /// `state_changed`
 87 |     public static var stateChanged: Self = "state_changed"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:87:23: warning: static property 'stateChanged' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 85 |     public static var shoppingListUpdated: Self = "shopping_list_updated"
 86 |     /// `state_changed`
 87 |     public static var stateChanged: Self = "state_changed"
    |                       |- warning: static property 'stateChanged' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'stateChanged' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'stateChanged' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 88 |     /// `themes_updated`
 89 |     public static var themesUpdated: Self = "themes_updated"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:89:23: warning: static property 'themesUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 87 |     public static var stateChanged: Self = "state_changed"
 88 |     /// `themes_updated`
 89 |     public static var themesUpdated: Self = "themes_updated"
    |                       |- warning: static property 'themesUpdated' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'themesUpdated' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'themesUpdated' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 90 |     /// `timer_out_of_sync`
 91 |     public static var timerOutOfSync: Self = "timer_out_of_sync"
/Users/admin/builder/spi-builder-workspace/Source/Convenience/Event.swift:91:23: warning: static property 'timerOutOfSync' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 89 |     public static var themesUpdated: Self = "themes_updated"
 90 |     /// `timer_out_of_sync`
 91 |     public static var timerOutOfSync: Self = "timer_out_of_sync"
    |                       |- warning: static property 'timerOutOfSync' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                       |- note: convert 'timerOutOfSync' to a 'let' constant to make 'Sendable' shared state immutable
    |                       |- note: add '@MainActor' to make static property 'timerOutOfSync' part of global actor 'MainActor'
    |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 92 | }
 93 |
[93/102] Compiling HAKit States.swift
/Users/admin/builder/spi-builder-workspace/Source/Data/HADecodeTransformable.swift:66:24: warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
 64 | extension Date: HADecodeTransformable {
 65 |     /// Date formatters
 66 |     private static let formatters: [ISO8601DateFormatter] = [
    |                        |- warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: add '@MainActor' to make static property 'formatters' part of global actor 'MainActor'
    |                        `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 67 |         {
 68 |             let formatter = ISO8601DateFormatter()
Swift.Array:1:23: note: generic struct 'Array' does not conform to the 'Sendable' protocol
1 | @frozen public struct Array<Element> : _DestructorSafeContainer {
  |                       `- note: generic struct 'Array' does not conform to the 'Sendable' protocol
2 | }
[94/102] Compiling HAKit HACompressedEntity.swift
/Users/admin/builder/spi-builder-workspace/Source/Data/HADecodeTransformable.swift:66:24: warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
 64 | extension Date: HADecodeTransformable {
 65 |     /// Date formatters
 66 |     private static let formatters: [ISO8601DateFormatter] = [
    |                        |- warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: add '@MainActor' to make static property 'formatters' part of global actor 'MainActor'
    |                        `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 67 |         {
 68 |             let formatter = ISO8601DateFormatter()
Swift.Array:1:23: note: generic struct 'Array' does not conform to the 'Sendable' protocol
1 | @frozen public struct Array<Element> : _DestructorSafeContainer {
  |                       `- note: generic struct 'Array' does not conform to the 'Sendable' protocol
2 | }
[95/102] Compiling HAKit HAData.swift
/Users/admin/builder/spi-builder-workspace/Source/Data/HADecodeTransformable.swift:66:24: warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
 64 | extension Date: HADecodeTransformable {
 65 |     /// Date formatters
 66 |     private static let formatters: [ISO8601DateFormatter] = [
    |                        |- warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: add '@MainActor' to make static property 'formatters' part of global actor 'MainActor'
    |                        `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 67 |         {
 68 |             let formatter = ISO8601DateFormatter()
Swift.Array:1:23: note: generic struct 'Array' does not conform to the 'Sendable' protocol
1 | @frozen public struct Array<Element> : _DestructorSafeContainer {
  |                       `- note: generic struct 'Array' does not conform to the 'Sendable' protocol
2 | }
[96/102] Compiling HAKit HADataDecodable.swift
/Users/admin/builder/spi-builder-workspace/Source/Data/HADecodeTransformable.swift:66:24: warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
 64 | extension Date: HADecodeTransformable {
 65 |     /// Date formatters
 66 |     private static let formatters: [ISO8601DateFormatter] = [
    |                        |- warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: add '@MainActor' to make static property 'formatters' part of global actor 'MainActor'
    |                        `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 67 |         {
 68 |             let formatter = ISO8601DateFormatter()
Swift.Array:1:23: note: generic struct 'Array' does not conform to the 'Sendable' protocol
1 | @frozen public struct Array<Element> : _DestructorSafeContainer {
  |                       `- note: generic struct 'Array' does not conform to the 'Sendable' protocol
2 | }
[97/102] Compiling HAKit HADecodeTransformable.swift
/Users/admin/builder/spi-builder-workspace/Source/Data/HADecodeTransformable.swift:66:24: warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
 64 | extension Date: HADecodeTransformable {
 65 |     /// Date formatters
 66 |     private static let formatters: [ISO8601DateFormatter] = [
    |                        |- warning: static property 'formatters' is not concurrency-safe because non-'Sendable' type '[ISO8601DateFormatter]' may have shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: add '@MainActor' to make static property 'formatters' part of global actor 'MainActor'
    |                        `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 67 |         {
 68 |             let formatter = ISO8601DateFormatter()
Swift.Array:1:23: note: generic struct 'Array' does not conform to the 'Sendable' protocol
1 | @frozen public struct Array<Element> : _DestructorSafeContainer {
  |                       `- note: generic struct 'Array' does not conform to the 'Sendable' protocol
2 | }
[98/102] Compiling HAKit HAURLSessionDelegate.swift
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:48:14: warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
46 | /// let connection = HAKit.connection(configuration: config, urlSession: session)
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
   |              `- warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
49 |     private let certificateProvider: HACertificateProvider
50 |
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:49:17: warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
 2 |
 3 | /// Protocol for providing certificate authentication for HAKit REST API calls
 4 | public protocol HACertificateProvider {
   |                 `- note: protocol 'HACertificateProvider' does not conform to the 'Sendable' protocol
 5 |     /// Called when the server requests a client certificate (mTLS)
 6 |     /// - Parameters:
   :
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
49 |     private let certificateProvider: HACertificateProvider
   |                 `- warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
50 |
51 |     /// Initialize with a certificate provider
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:69: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                                                                     `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:6:16: note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:52:31: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
   |                               `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
53 |                 }
54 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:51:50: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
   |                                                  `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
52 |                     }, event: data)
53 |                 }
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:21: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                     `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:37: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:42: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                                          `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:13: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |             `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:57: warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |                                                         `- warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/HAConnection.swift:14:13: note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 12 |
 13 | /// State of the connection
 14 | public enum HAConnectionState: Equatable {
    |             `- note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 15 |     /// Notification fired when state transitions occur
 16 |     ///
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:139:47: warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
133 |     }
134 |
135 |     func performConnectionChange(_ block: @escaping () -> Void) {
    |                                    `- note: parameter 'block' is implicitly non-sendable
136 |         if Thread.isMainThread {
137 |             block()
138 |         } else {
139 |             DispatchQueue.main.async(execute: block)
    |                                               `- warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
140 |         }
141 |     }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:224:53: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
222 |         send(request.request) { [workQueue, callbackQueue] result in
223 |             workQueue.async {
224 |                 let converted: Result<T, HAError> = result.flatMap { data in
    |                                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
225 |                     do {
226 |                         let updated = try T(data: data)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:32: warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
216 |
217 |     @discardableResult
218 |     func send<T>(
    |               `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
219 |         _ request: HATypedRequest<T>,
220 |         completion: @escaping (Result<T, HAError>) -> Void
    :
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                                `- warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:273:49: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
271 |                 workQueue.async {
272 |                     do {
273 |                         let value = try T(data: data)
    |                                                 `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
274 |                         callbackQueue.async {
275 |                             handler(token, value)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:44: warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
258 |     }
259 |
260 |     private func commonSubscribe<T>(
    |                                  `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
261 |         to request: HATypedSubscription<T>,
262 |         allowConnecting: Bool = true,
    :
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                            `- warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:337:30: warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
335 |     ) {
336 |         workQueue.async { [connection] in
337 |             var dictionary = request.data
    |                              `- warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
338 |             if let identifier = identifier {
339 |                 dictionary["id"] = identifier.rawValue
/Users/admin/builder/spi-builder-workspace/Source/Requests/HARequest.swift:4:15: note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 2 |
 3 | /// A request, with data, to be issued
 4 | public struct HARequest {
   |               `- note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 5 |     /// Create a request
 6 |     /// - Precondition: data is a JSON-encodable value. From `JSONSerialization` documentation:
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:351:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
349 |             }
350 |
351 |             connection?.write(string: string)
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
352 |         }
353 |     }
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:2:1: warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  1 | import Foundation
  2 | import Starscream
    | `- warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  3 |
  4 | // NOTE: see HAConnection.swift for how to access these types
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:380:25: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
378 |                 let task = urlSession.dataTask(with: httpRequest) { [self] data, response, error in
379 |                     if let response = response {
380 |                         responseController.didReceive(
    |                         `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
381 |                             for: identifier,
382 |                             // This badly-typed API will always return HTTPURLResponses to http/https endpoints.
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:56: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                                        `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:37: warning: reference to captured var 'audioData' in concurrently-executing code
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                     `- warning: reference to captured var 'audioData' in concurrently-executing code
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:420:25: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
418 |                 if let identifier, let request = self.requestController.single(for: identifier) {
419 |                     callbackQueue.async {
420 |                         request.resolve(.success(.empty))
    |                         `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
421 |                     }
422 |                     requestController.clear(invocation: request)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:17: warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                 |- warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'handler' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:25: warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                         |- warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
    |                         `- note: task-isolated 'result' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
[99/102] Compiling HAKit HACancellableImpl.swift
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:48:14: warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
46 | /// let connection = HAKit.connection(configuration: config, urlSession: session)
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
   |              `- warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
49 |     private let certificateProvider: HACertificateProvider
50 |
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:49:17: warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
 2 |
 3 | /// Protocol for providing certificate authentication for HAKit REST API calls
 4 | public protocol HACertificateProvider {
   |                 `- note: protocol 'HACertificateProvider' does not conform to the 'Sendable' protocol
 5 |     /// Called when the server requests a client certificate (mTLS)
 6 |     /// - Parameters:
   :
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
49 |     private let certificateProvider: HACertificateProvider
   |                 `- warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
50 |
51 |     /// Initialize with a certificate provider
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:69: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                                                                     `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:6:16: note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:52:31: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
   |                               `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
53 |                 }
54 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:51:50: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
   |                                                  `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
52 |                     }, event: data)
53 |                 }
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:21: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                     `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:37: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:42: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                                          `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:13: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |             `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:57: warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |                                                         `- warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/HAConnection.swift:14:13: note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 12 |
 13 | /// State of the connection
 14 | public enum HAConnectionState: Equatable {
    |             `- note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 15 |     /// Notification fired when state transitions occur
 16 |     ///
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:139:47: warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
133 |     }
134 |
135 |     func performConnectionChange(_ block: @escaping () -> Void) {
    |                                    `- note: parameter 'block' is implicitly non-sendable
136 |         if Thread.isMainThread {
137 |             block()
138 |         } else {
139 |             DispatchQueue.main.async(execute: block)
    |                                               `- warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
140 |         }
141 |     }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:224:53: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
222 |         send(request.request) { [workQueue, callbackQueue] result in
223 |             workQueue.async {
224 |                 let converted: Result<T, HAError> = result.flatMap { data in
    |                                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
225 |                     do {
226 |                         let updated = try T(data: data)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:32: warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
216 |
217 |     @discardableResult
218 |     func send<T>(
    |               `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
219 |         _ request: HATypedRequest<T>,
220 |         completion: @escaping (Result<T, HAError>) -> Void
    :
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                                `- warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:273:49: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
271 |                 workQueue.async {
272 |                     do {
273 |                         let value = try T(data: data)
    |                                                 `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
274 |                         callbackQueue.async {
275 |                             handler(token, value)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:44: warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
258 |     }
259 |
260 |     private func commonSubscribe<T>(
    |                                  `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
261 |         to request: HATypedSubscription<T>,
262 |         allowConnecting: Bool = true,
    :
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                            `- warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:337:30: warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
335 |     ) {
336 |         workQueue.async { [connection] in
337 |             var dictionary = request.data
    |                              `- warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
338 |             if let identifier = identifier {
339 |                 dictionary["id"] = identifier.rawValue
/Users/admin/builder/spi-builder-workspace/Source/Requests/HARequest.swift:4:15: note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 2 |
 3 | /// A request, with data, to be issued
 4 | public struct HARequest {
   |               `- note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 5 |     /// Create a request
 6 |     /// - Precondition: data is a JSON-encodable value. From `JSONSerialization` documentation:
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:351:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
349 |             }
350 |
351 |             connection?.write(string: string)
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
352 |         }
353 |     }
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:2:1: warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  1 | import Foundation
  2 | import Starscream
    | `- warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  3 |
  4 | // NOTE: see HAConnection.swift for how to access these types
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:380:25: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
378 |                 let task = urlSession.dataTask(with: httpRequest) { [self] data, response, error in
379 |                     if let response = response {
380 |                         responseController.didReceive(
    |                         `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
381 |                             for: identifier,
382 |                             // This badly-typed API will always return HTTPURLResponses to http/https endpoints.
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:56: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                                        `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:37: warning: reference to captured var 'audioData' in concurrently-executing code
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                     `- warning: reference to captured var 'audioData' in concurrently-executing code
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:420:25: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
418 |                 if let identifier, let request = self.requestController.single(for: identifier) {
419 |                     callbackQueue.async {
420 |                         request.resolve(.success(.empty))
    |                         `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
421 |                     }
422 |                     requestController.clear(invocation: request)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:17: warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                 |- warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'handler' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:25: warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                         |- warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
    |                         `- note: task-isolated 'result' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
[100/102] Compiling HAKit HAConnectionImpl+Requests.swift
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:48:14: warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
46 | /// let connection = HAKit.connection(configuration: config, urlSession: session)
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
   |              `- warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
49 |     private let certificateProvider: HACertificateProvider
50 |
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:49:17: warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
 2 |
 3 | /// Protocol for providing certificate authentication for HAKit REST API calls
 4 | public protocol HACertificateProvider {
   |                 `- note: protocol 'HACertificateProvider' does not conform to the 'Sendable' protocol
 5 |     /// Called when the server requests a client certificate (mTLS)
 6 |     /// - Parameters:
   :
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
49 |     private let certificateProvider: HACertificateProvider
   |                 `- warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
50 |
51 |     /// Initialize with a certificate provider
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:69: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                                                                     `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:6:16: note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:52:31: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
   |                               `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
53 |                 }
54 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:51:50: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
   |                                                  `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
52 |                     }, event: data)
53 |                 }
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:21: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                     `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:37: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:42: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                                          `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:13: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |             `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:57: warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |                                                         `- warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/HAConnection.swift:14:13: note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 12 |
 13 | /// State of the connection
 14 | public enum HAConnectionState: Equatable {
    |             `- note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 15 |     /// Notification fired when state transitions occur
 16 |     ///
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:139:47: warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
133 |     }
134 |
135 |     func performConnectionChange(_ block: @escaping () -> Void) {
    |                                    `- note: parameter 'block' is implicitly non-sendable
136 |         if Thread.isMainThread {
137 |             block()
138 |         } else {
139 |             DispatchQueue.main.async(execute: block)
    |                                               `- warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
140 |         }
141 |     }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:224:53: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
222 |         send(request.request) { [workQueue, callbackQueue] result in
223 |             workQueue.async {
224 |                 let converted: Result<T, HAError> = result.flatMap { data in
    |                                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
225 |                     do {
226 |                         let updated = try T(data: data)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:32: warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
216 |
217 |     @discardableResult
218 |     func send<T>(
    |               `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
219 |         _ request: HATypedRequest<T>,
220 |         completion: @escaping (Result<T, HAError>) -> Void
    :
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                                `- warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:273:49: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
271 |                 workQueue.async {
272 |                     do {
273 |                         let value = try T(data: data)
    |                                                 `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
274 |                         callbackQueue.async {
275 |                             handler(token, value)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:44: warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
258 |     }
259 |
260 |     private func commonSubscribe<T>(
    |                                  `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
261 |         to request: HATypedSubscription<T>,
262 |         allowConnecting: Bool = true,
    :
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                            `- warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:337:30: warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
335 |     ) {
336 |         workQueue.async { [connection] in
337 |             var dictionary = request.data
    |                              `- warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
338 |             if let identifier = identifier {
339 |                 dictionary["id"] = identifier.rawValue
/Users/admin/builder/spi-builder-workspace/Source/Requests/HARequest.swift:4:15: note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 2 |
 3 | /// A request, with data, to be issued
 4 | public struct HARequest {
   |               `- note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 5 |     /// Create a request
 6 |     /// - Precondition: data is a JSON-encodable value. From `JSONSerialization` documentation:
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:351:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
349 |             }
350 |
351 |             connection?.write(string: string)
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
352 |         }
353 |     }
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:2:1: warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  1 | import Foundation
  2 | import Starscream
    | `- warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  3 |
  4 | // NOTE: see HAConnection.swift for how to access these types
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:380:25: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
378 |                 let task = urlSession.dataTask(with: httpRequest) { [self] data, response, error in
379 |                     if let response = response {
380 |                         responseController.didReceive(
    |                         `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
381 |                             for: identifier,
382 |                             // This badly-typed API will always return HTTPURLResponses to http/https endpoints.
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:56: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                                        `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:37: warning: reference to captured var 'audioData' in concurrently-executing code
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                     `- warning: reference to captured var 'audioData' in concurrently-executing code
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:420:25: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
418 |                 if let identifier, let request = self.requestController.single(for: identifier) {
419 |                     callbackQueue.async {
420 |                         request.resolve(.success(.empty))
    |                         `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
421 |                     }
422 |                     requestController.clear(invocation: request)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:17: warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                 |- warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'handler' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:25: warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                         |- warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
    |                         `- note: task-isolated 'result' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
[101/102] Compiling HAKit HAConnectionImpl+Responses.swift
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:48:14: warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
46 | /// let connection = HAKit.connection(configuration: config, urlSession: session)
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
   |              `- warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
49 |     private let certificateProvider: HACertificateProvider
50 |
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:49:17: warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
 2 |
 3 | /// Protocol for providing certificate authentication for HAKit REST API calls
 4 | public protocol HACertificateProvider {
   |                 `- note: protocol 'HACertificateProvider' does not conform to the 'Sendable' protocol
 5 |     /// Called when the server requests a client certificate (mTLS)
 6 |     /// - Parameters:
   :
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
49 |     private let certificateProvider: HACertificateProvider
   |                 `- warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
50 |
51 |     /// Initialize with a certificate provider
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:69: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                                                                     `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:6:16: note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:52:31: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
   |                               `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
53 |                 }
54 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:51:50: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
   |                                                  `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
52 |                     }, event: data)
53 |                 }
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:21: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                     `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:37: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:42: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                                          `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:13: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |             `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:57: warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |                                                         `- warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/HAConnection.swift:14:13: note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 12 |
 13 | /// State of the connection
 14 | public enum HAConnectionState: Equatable {
    |             `- note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 15 |     /// Notification fired when state transitions occur
 16 |     ///
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:139:47: warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
133 |     }
134 |
135 |     func performConnectionChange(_ block: @escaping () -> Void) {
    |                                    `- note: parameter 'block' is implicitly non-sendable
136 |         if Thread.isMainThread {
137 |             block()
138 |         } else {
139 |             DispatchQueue.main.async(execute: block)
    |                                               `- warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
140 |         }
141 |     }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:224:53: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
222 |         send(request.request) { [workQueue, callbackQueue] result in
223 |             workQueue.async {
224 |                 let converted: Result<T, HAError> = result.flatMap { data in
    |                                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
225 |                     do {
226 |                         let updated = try T(data: data)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:32: warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
216 |
217 |     @discardableResult
218 |     func send<T>(
    |               `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
219 |         _ request: HATypedRequest<T>,
220 |         completion: @escaping (Result<T, HAError>) -> Void
    :
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                                `- warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:273:49: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
271 |                 workQueue.async {
272 |                     do {
273 |                         let value = try T(data: data)
    |                                                 `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
274 |                         callbackQueue.async {
275 |                             handler(token, value)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:44: warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
258 |     }
259 |
260 |     private func commonSubscribe<T>(
    |                                  `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
261 |         to request: HATypedSubscription<T>,
262 |         allowConnecting: Bool = true,
    :
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                            `- warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:337:30: warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
335 |     ) {
336 |         workQueue.async { [connection] in
337 |             var dictionary = request.data
    |                              `- warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
338 |             if let identifier = identifier {
339 |                 dictionary["id"] = identifier.rawValue
/Users/admin/builder/spi-builder-workspace/Source/Requests/HARequest.swift:4:15: note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 2 |
 3 | /// A request, with data, to be issued
 4 | public struct HARequest {
   |               `- note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 5 |     /// Create a request
 6 |     /// - Precondition: data is a JSON-encodable value. From `JSONSerialization` documentation:
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:351:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
349 |             }
350 |
351 |             connection?.write(string: string)
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
352 |         }
353 |     }
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:2:1: warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  1 | import Foundation
  2 | import Starscream
    | `- warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  3 |
  4 | // NOTE: see HAConnection.swift for how to access these types
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:380:25: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
378 |                 let task = urlSession.dataTask(with: httpRequest) { [self] data, response, error in
379 |                     if let response = response {
380 |                         responseController.didReceive(
    |                         `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
381 |                             for: identifier,
382 |                             // This badly-typed API will always return HTTPURLResponses to http/https endpoints.
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:56: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                                        `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:37: warning: reference to captured var 'audioData' in concurrently-executing code
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                     `- warning: reference to captured var 'audioData' in concurrently-executing code
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:420:25: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
418 |                 if let identifier, let request = self.requestController.single(for: identifier) {
419 |                     callbackQueue.async {
420 |                         request.resolve(.success(.empty))
    |                         `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
421 |                     }
422 |                     requestController.clear(invocation: request)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:17: warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                 |- warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'handler' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:25: warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                         |- warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
    |                         `- note: task-isolated 'result' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
[102/102] Compiling HAKit HAConnectionImpl.swift
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:48:14: warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
46 | /// let connection = HAKit.connection(configuration: config, urlSession: session)
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
   |              `- warning: non-final class 'HAURLSessionDelegate' cannot conform to 'Sendable'; use '@unchecked Sendable'; this is an error in the Swift 6 language mode
49 |     private let certificateProvider: HACertificateProvider
50 |
/Users/admin/builder/spi-builder-workspace/Source/HAURLSessionDelegate.swift:49:17: warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
 2 |
 3 | /// Protocol for providing certificate authentication for HAKit REST API calls
 4 | public protocol HACertificateProvider {
   |                 `- note: protocol 'HACertificateProvider' does not conform to the 'Sendable' protocol
 5 |     /// Called when the server requests a client certificate (mTLS)
 6 |     /// - Parameters:
   :
47 | /// ```
48 | public class HAURLSessionDelegate: NSObject, URLSessionDelegate {
49 |     private let certificateProvider: HACertificateProvider
   |                 `- warning: stored property 'certificateProvider' of 'Sendable'-conforming class 'HAURLSessionDelegate' has non-sendable type 'any HACertificateProvider'; this is an error in the Swift 6 language mode
50 |
51 |     /// Initialize with a certificate provider
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:50:69: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
48 |             if let subscription = requestController.subscription(for: identifier) {
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
   |                                                                     `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:6:16: note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:52:31: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
52 |                     }, event: data)
   |                               `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
53 |                 }
54 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:51:50: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
49 |                 callbackQueue.async { [self] in
50 |                     subscription.invoke(token: HACancellableImpl { [requestController] in
51 |                         requestController.cancel(subscription)
   |                                                  `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in an isolated closure; this is an error in the Swift 6 language mode
52 |                     }, event: data)
53 |                 }
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:21: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                     `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:60:37: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
58 |             if let request = requestController.single(for: identifier) {
59 |                 callbackQueue.async {
60 |                     request.resolve(result)
   |                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
61 |                 }
62 |
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:21: warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                     `- warning: capture of 'subscription' with non-sendable type 'HARequestInvocationSubscription' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSubscription.swift:1:16: note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSubscription: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSubscription' does not conform to the 'Sendable' protocol
 2 |     private var handler: HAResetLock<HAConnection.SubscriptionHandler>
 3 |     private var initiated: HAResetLock<HAConnection.SubscriptionInitiatedHandler>
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl+Responses.swift:66:42: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
64 |             } else if let subscription = requestController.subscription(for: identifier) {
65 |                 callbackQueue.async {
66 |                     subscription.resolve(result)
   |                                          `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
67 |                 }
68 |             } else {
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:13: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |             `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:34:57: warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 32 |     internal func notifyState() {
 33 |         callbackQueue.async { [self, state] in
 34 |             delegate?.connection(self, didTransitionTo: state)
    |                                                         `- warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 35 |             NotificationCenter.default.post(
 36 |                 name: HAConnectionState.didTransitionToStateNotification,
/Users/admin/builder/spi-builder-workspace/Source/HAConnection.swift:14:13: note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 12 |
 13 | /// State of the connection
 14 | public enum HAConnectionState: Equatable {
    |             `- note: consider making enum 'HAConnectionState' conform to the 'Sendable' protocol
 15 |     /// Notification fired when state transitions occur
 16 |     ///
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:139:47: warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
133 |     }
134 |
135 |     func performConnectionChange(_ block: @escaping () -> Void) {
    |                                    `- note: parameter 'block' is implicitly non-sendable
136 |         if Thread.isMainThread {
137 |             block()
138 |         } else {
139 |             DispatchQueue.main.async(execute: block)
    |                                               `- warning: passing non-sendable parameter 'block' to function expecting a @Sendable closure
140 |         }
141 |     }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:224:53: warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
222 |         send(request.request) { [workQueue, callbackQueue] result in
223 |             workQueue.async {
224 |                 let converted: Result<T, HAError> = result.flatMap { data in
    |                                                     `- warning: capture of 'result' with non-sendable type 'Result<HAData, HAError>' in a '@Sendable' closure
225 |                     do {
226 |                         let updated = try T(data: data)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:21: warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<T, HAError>) -> Void' in a '@Sendable' closure
    |                     `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:234:32: warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
216 |
217 |     @discardableResult
218 |     func send<T>(
    |               `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
219 |         _ request: HATypedRequest<T>,
220 |         completion: @escaping (Result<T, HAError>) -> Void
    :
232 |
233 |                 callbackQueue.async {
234 |                     completion(converted)
    |                                `- warning: capture of 'converted' with non-sendable type 'Result<T, HAError>' in a '@Sendable' closure
235 |                 }
236 |             }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:273:49: warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
271 |                 workQueue.async {
272 |                     do {
273 |                         let value = try T(data: data)
    |                                                 `- warning: capture of 'data' with non-sendable type 'HAData' in a '@Sendable' closure
274 |                         callbackQueue.async {
275 |                             handler(token, value)
/Users/admin/builder/spi-builder-workspace/Source/Data/HAData.swift:6:13: note: consider making enum 'HAData' conform to the 'Sendable' protocol
 4 | ///
 5 | /// The root-level information in either the `result` for individual requests or `event` for subscriptions.
 6 | public enum HAData: Equatable {
   |             `- note: consider making enum 'HAData' conform to the 'Sendable' protocol
 7 |     /// A dictionary response.
 8 |     /// - SeeAlso: `get(_:)`and associated methods
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:29: warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                             |- warning: capture of 'handler' with non-sendable type '(any HACancellable, T) -> Void' in a '@Sendable' closure
    |                             `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:37: warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                     `- warning: capture of 'token' with non-sendable type 'any HACancellable' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/HARequestToken.swift:4:17: note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
2 | ///
3 | /// You do not need to strongly retain this value. Requests are only cancelled explicitly.
4 | public protocol HACancellable {
  |                 `- note: protocol 'HACancellable' does not conform to the 'Sendable' protocol
5 |     /// Cancel the request or subscription represented by this.
6 |     func cancel()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:275:44: warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
258 |     }
259 |
260 |     private func commonSubscribe<T>(
    |                                  `- note: consider making generic parameter 'T' conform to the 'Sendable' protocol
261 |         to request: HATypedSubscription<T>,
262 |         allowConnecting: Bool = true,
    :
273 |                         let value = try T(data: data)
274 |                         callbackQueue.async {
275 |                             handler(token, value)
    |                                            `- warning: capture of 'value' with non-sendable type 'T' in a '@Sendable' closure
276 |                         }
277 |                     } catch {
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:337:30: warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
335 |     ) {
336 |         workQueue.async { [connection] in
337 |             var dictionary = request.data
    |                              `- warning: capture of 'request' with non-sendable type 'HARequest' in a '@Sendable' closure
338 |             if let identifier = identifier {
339 |                 dictionary["id"] = identifier.rawValue
/Users/admin/builder/spi-builder-workspace/Source/Requests/HARequest.swift:4:15: note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 2 |
 3 | /// A request, with data, to be issued
 4 | public struct HARequest {
   |               `- note: consider making struct 'HARequest' conform to the 'Sendable' protocol
 5 |     /// Create a request
 6 |     /// - Precondition: data is a JSON-encodable value. From `JSONSerialization` documentation:
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:351:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
349 |             }
350 |
351 |             connection?.write(string: string)
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
352 |         }
353 |     }
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:2:1: warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  1 | import Foundation
  2 | import Starscream
    | `- warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'Starscream'
  3 |
  4 | // NOTE: see HAConnection.swift for how to access these types
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:380:25: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
378 |                 let task = urlSession.dataTask(with: httpRequest) { [self] data, response, error in
379 |                     if let response = response {
380 |                         responseController.didReceive(
    |                         `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
381 |                             for: identifier,
382 |                             // This badly-typed API will always return HTTPURLResponses to http/https endpoints.
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:13: warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |             `- warning: capture of 'connection' with non-sendable type 'WebSocket?' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Starscream/WebSocket.swift:95:12: note: class 'WebSocket' does not conform to the 'Sendable' protocol
 93 | }
 94 |
 95 | open class WebSocket: WebSocketClient, EngineDelegate {
    |            `- note: class 'WebSocket' does not conform to the 'Sendable' protocol
 96 |     private let engine: Engine
 97 |     public weak var delegate: WebSocketDelegate?
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:56: warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
  4 | // NOTE: see HAConnection.swift for how to access these types
  5 |
  6 | internal class HAConnectionImpl: HAConnection {
    |                `- note: class 'HAConnectionImpl' does not conform to the 'Sendable' protocol
  7 |     weak var delegate: HAConnectionDelegate?
  8 |     var configuration: HAConnectionConfiguration
    :
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                                        `- warning: capture of 'self' with non-sendable type 'HAConnectionImpl' in a '@Sendable' closure
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:415:37: warning: reference to captured var 'audioData' in concurrently-executing code
413 |         audioData.insert(sttBinaryHandlerId, at: 0)
414 |         workQueue.async { [connection] in
415 |             connection?.write(data: audioData) { [weak self] in
    |                                     `- warning: reference to captured var 'audioData' in concurrently-executing code
416 |                 guard let self else { return }
417 |                 self.responseController.didWrite()
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:420:25: warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
418 |                 if let identifier, let request = self.requestController.single(for: identifier) {
419 |                     callbackQueue.async {
420 |                         request.resolve(.success(.empty))
    |                         `- warning: capture of 'request' with non-sendable type 'HARequestInvocationSingle' in a '@Sendable' closure
421 |                     }
422 |                     requestController.clear(invocation: request)
/Users/admin/builder/spi-builder-workspace/Source/Internal/RequestController/HARequestInvocationSingle.swift:1:16: note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 1 | internal class HARequestInvocationSingle: HARequestInvocation {
   |                `- note: class 'HARequestInvocationSingle' does not conform to the 'Sendable' protocol
 2 |     private var completion: HAResetLock<HAConnection.RequestCompletion>
 3 |
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:17: warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                 |- warning: sending 'handler' risks causing data races; this is an error in the Swift 6 language mode
    |                 `- note: task-isolated 'handler' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
/Users/admin/builder/spi-builder-workspace/Source/Internal/HAConnectionImpl.swift:462:25: warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
460 |         send(.init(type: .ping, data: [:])) { result in
461 |             DispatchQueue.main.async {
462 |                 handler(result.map { _ in () }.mapError { $0 })
    |                         |- warning: sending 'result' risks causing data races; this is an error in the Swift 6 language mode
    |                         `- note: task-isolated 'result' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
463 |             }
464 |         }
[103/107] Compiling HAKit_PromiseKit HAConnection+PromiseKit.swift
[104/107] Compiling HAKit_PromiseKit HACache+PromiseKit.swift
[105/107] Emitting module HAKit_PromiseKit
[106/107] Compiling HAKit_Mocks HAConnection+Mock.swift
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:9:16: warning: static property 'fake' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
  7 |     /// A basic, fake configuration that is always successful.
  8 |     /// This is available to be modified at will; nothing depends on the values provided.
  9 |     static var fake = HAConnectionConfiguration(
    |                |- warning: static property 'fake' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                |- note: convert 'fake' to a 'let' constant to make 'Sendable' shared state immutable
    |                |- note: add '@MainActor' to make static property 'fake' part of global actor 'MainActor'
    |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 10 |         connectionInfo: { () -> HAConnectionInfo? in
 11 |             try? .init(url: URL(string: "http://127.0.0.1:8123")!)
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:94:17: warning: capture of 'self' with non-sendable type 'HAMockConnection' in a '@Sendable' closure
 42 | ///
 43 | /// Provides basic scaffolding to test usage of the library.
 44 | public class HAMockConnection: HAConnection {
    |              `- note: class 'HAMockConnection' does not conform to the 'Sendable' protocol
 45 |     // MARK: - Mock Handling
 46 |
    :
 92 |             // matching async behavior of HAConnectionImpl
 93 |             callbackQueue.async { [self, state] in
 94 |                 delegate?.connection(self, didTransitionTo: state)
    |                 `- warning: capture of 'self' with non-sendable type 'HAMockConnection' in a '@Sendable' closure
 95 |                 NotificationCenter.default.post(name: HAConnectionState.didTransitionToStateNotification, object: self)
 96 |             }
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:94:61: warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 92 |             // matching async behavior of HAConnectionImpl
 93 |             callbackQueue.async { [self, state] in
 94 |                 delegate?.connection(self, didTransitionTo: state)
    |                                                             `- warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 95 |                 NotificationCenter.default.post(name: HAConnectionState.didTransitionToStateNotification, object: self)
 96 |             }
/Users/admin/builder/spi-builder-workspace/Source/HAConnection.swift:14:13: note: enum 'HAConnectionState' does not conform to the 'Sendable' protocol
 12 |
 13 | /// State of the connection
 14 | public enum HAConnectionState: Equatable {
    |             `- note: enum 'HAConnectionState' does not conform to the 'Sendable' protocol
 15 |     /// Notification fired when state transitions occur
 16 |     ///
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:3:1: warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'HAKit'
  1 | import Foundation
  2 | #if SWIFT_PACKAGE
  3 | import HAKit
    | `- warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'HAKit'
  4 | #endif
  5 |
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:222:38: warning: converting non-sendable function value to '@Sendable @convention(block) () -> Void' may introduce data races
220 |         }
221 |
222 |         callbackQueue.async(execute: stop)
    |                                      `- warning: converting non-sendable function value to '@Sendable @convention(block) () -> Void' may introduce data races
223 |         DispatchQueue.main.asyncAfter(deadline: .now() + .seconds(5), execute: stop)
224 |
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:223:80: warning: converting non-sendable function value to '@MainActor @Sendable @convention(block) () -> Void' may introduce data races
221 |
222 |         callbackQueue.async(execute: stop)
223 |         DispatchQueue.main.asyncAfter(deadline: .now() + .seconds(5), execute: stop)
    |                                                                                `- warning: converting non-sendable function value to '@MainActor @Sendable @convention(block) () -> Void' may introduce data races
224 |
225 |         while hasCalled == 0 {
[107/107] Emitting module HAKit_Mocks
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:9:16: warning: static property 'fake' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
  7 |     /// A basic, fake configuration that is always successful.
  8 |     /// This is available to be modified at will; nothing depends on the values provided.
  9 |     static var fake = HAConnectionConfiguration(
    |                |- warning: static property 'fake' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                |- note: convert 'fake' to a 'let' constant to make 'Sendable' shared state immutable
    |                |- note: add '@MainActor' to make static property 'fake' part of global actor 'MainActor'
    |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
 10 |         connectionInfo: { () -> HAConnectionInfo? in
 11 |             try? .init(url: URL(string: "http://127.0.0.1:8123")!)
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:94:17: warning: capture of 'self' with non-sendable type 'HAMockConnection' in a '@Sendable' closure
 42 | ///
 43 | /// Provides basic scaffolding to test usage of the library.
 44 | public class HAMockConnection: HAConnection {
    |              `- note: class 'HAMockConnection' does not conform to the 'Sendable' protocol
 45 |     // MARK: - Mock Handling
 46 |
    :
 92 |             // matching async behavior of HAConnectionImpl
 93 |             callbackQueue.async { [self, state] in
 94 |                 delegate?.connection(self, didTransitionTo: state)
    |                 `- warning: capture of 'self' with non-sendable type 'HAMockConnection' in a '@Sendable' closure
 95 |                 NotificationCenter.default.post(name: HAConnectionState.didTransitionToStateNotification, object: self)
 96 |             }
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:94:61: warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 92 |             // matching async behavior of HAConnectionImpl
 93 |             callbackQueue.async { [self, state] in
 94 |                 delegate?.connection(self, didTransitionTo: state)
    |                                                             `- warning: capture of 'state' with non-sendable type 'HAConnectionState' in a '@Sendable' closure
 95 |                 NotificationCenter.default.post(name: HAConnectionState.didTransitionToStateNotification, object: self)
 96 |             }
/Users/admin/builder/spi-builder-workspace/Source/HAConnection.swift:14:13: note: enum 'HAConnectionState' does not conform to the 'Sendable' protocol
 12 |
 13 | /// State of the connection
 14 | public enum HAConnectionState: Equatable {
    |             `- note: enum 'HAConnectionState' does not conform to the 'Sendable' protocol
 15 |     /// Notification fired when state transitions occur
 16 |     ///
/Users/admin/builder/spi-builder-workspace/Extensions/Mocks/HAConnection+Mock.swift:3:1: warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'HAKit'
  1 | import Foundation
  2 | #if SWIFT_PACKAGE
  3 | import HAKit
    | `- warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'HAKit'
  4 | #endif
  5 |
Build complete! (31.62s)
Fetching https://github.com/bgoncal/Starscream
Fetching https://github.com/mxcl/PromiseKit
[1/3290] Fetching starscream
[725/20534] Fetching starscream, promisekit
Fetched https://github.com/bgoncal/Starscream from cache (2.67s)
Fetched https://github.com/mxcl/PromiseKit from cache (2.67s)
Computing version for https://github.com/bgoncal/Starscream
Computed https://github.com/bgoncal/Starscream at 4.0.10 (3.26s)
Computing version for https://github.com/mxcl/PromiseKit
Computed https://github.com/mxcl/PromiseKit at 8.2.0 (0.60s)
Creating working copy for https://github.com/bgoncal/Starscream
Working copy of https://github.com/bgoncal/Starscream resolved at 4.0.10
Creating working copy for https://github.com/mxcl/PromiseKit
Working copy of https://github.com/mxcl/PromiseKit resolved at 8.2.0
warning: 'starscream': found 1 file(s) which are unhandled; explicitly declare them as resources or exclude from the target
    /Users/admin/builder/spi-builder-workspace/.build/checkouts/Starscream/Sources/Info.plist
Build complete.
{
  "dependencies" : [
    {
      "identity" : "starscream",
      "requirement" : {
        "range" : [
          {
            "lower_bound" : "4.0.10",
            "upper_bound" : "5.0.0"
          }
        ]
      },
      "type" : "sourceControl",
      "url" : "https://github.com/bgoncal/Starscream"
    },
    {
      "identity" : "promisekit",
      "requirement" : {
        "range" : [
          {
            "lower_bound" : "8.1.1",
            "upper_bound" : "9.0.0"
          }
        ]
      },
      "type" : "sourceControl",
      "url" : "https://github.com/mxcl/PromiseKit"
    }
  ],
  "manifest_display_name" : "HAKit",
  "name" : "HAKit",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
    {
      "name" : "ios",
      "version" : "13.0"
    },
    {
      "name" : "macos",
      "version" : "10.15"
    },
    {
      "name" : "tvos",
      "version" : "13.0"
    },
    {
      "name" : "watchos",
      "version" : "6.0"
    }
  ],
  "products" : [
    {
      "name" : "HAKit",
      "targets" : [
        "HAKit"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    },
    {
      "name" : "HAKit+PromiseKit",
      "targets" : [
        "HAKit+PromiseKit"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    },
    {
      "name" : "HAKit+Mocks",
      "targets" : [
        "HAKit+Mocks"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "Tests",
      "module_type" : "SwiftTarget",
      "name" : "Tests",
      "path" : "Tests",
      "sources" : [
        "CurrentUser.test.swift",
        "Event.test.swift",
        "FakeEngine.swift",
        "HACache.test.swift",
        "HACacheKeyStates.test.swift",
        "HACachePopulateInfo.test.swift",
        "HACacheSubscribeInfo.test.swift",
        "HACachedStates.test.swift",
        "HACachedUser.test.swift",
        "HACachesContainer.test.swift",
        "HACancellableImpl.test.swift",
        "HAConnectionConfiguration.test.swift",
        "HAConnectionImpl.test.swift",
        "HAConnectionInfo.test.swift",
        "HAData.test.swift",
        "HADataDecodable.test.swift",
        "HAEntity+CompressedEntity.test.swift",
        "HAEntity.test.swift",
        "HAError.test.swift",
        "HAKit.test.swift",
        "HAReconnectManager.test.swift",
        "HARequestController.test.swift",
        "HARequestInvocation.test.swift",
        "HARequestInvocationSingle.test.swift",
        "HARequestInvocationSubscription.test.swift",
        "HAResetLock.test.swift",
        "HAResponseController.test.swift",
        "HAResponseVoid.test.swift",
        "HAURLSessionDelegate.test.swift",
        "HAURLSessionWebSocketEngine.test.swift",
        "HAWebSocketResponse.test.swift",
        "HAWebSocketResponseFixture.swift",
        "RenderTemplate.test.swift",
        "Services.test.swift",
        "States.test.swift",
        "StubbingURLProtocol.swift",
        "TestAdditions.swift"
      ],
      "target_dependencies" : [
        "HAKit",
        "HAKit+PromiseKit",
        "HAKit+Mocks"
      ],
      "type" : "test"
    },
    {
      "c99name" : "HAKit_PromiseKit",
      "module_type" : "SwiftTarget",
      "name" : "HAKit+PromiseKit",
      "path" : "Extensions/PromiseKit",
      "product_dependencies" : [
        "PromiseKit"
      ],
      "product_memberships" : [
        "HAKit+PromiseKit"
      ],
      "sources" : [
        "HACache+PromiseKit.swift",
        "HAConnection+PromiseKit.swift"
      ],
      "target_dependencies" : [
        "HAKit"
      ],
      "type" : "library"
    },
    {
      "c99name" : "HAKit_Mocks",
      "module_type" : "SwiftTarget",
      "name" : "HAKit+Mocks",
      "path" : "Extensions/Mocks",
      "product_memberships" : [
        "HAKit+Mocks"
      ],
      "sources" : [
        "HAConnection+Mock.swift"
      ],
      "target_dependencies" : [
        "HAKit"
      ],
      "type" : "library"
    },
    {
      "c99name" : "HAKit",
      "module_type" : "SwiftTarget",
      "name" : "HAKit",
      "path" : "Source",
      "product_dependencies" : [
        "Starscream"
      ],
      "product_memberships" : [
        "HAKit",
        "HAKit+PromiseKit",
        "HAKit+Mocks"
      ],
      "sources" : [
        "Caches/HACache.swift",
        "Caches/HACacheKeyStates.swift",
        "Caches/HACachePopulateInfo.swift",
        "Caches/HACacheSubscribeInfo.swift",
        "Caches/HACacheTransformInfo.swift",
        "Caches/HACachedStates.swift",
        "Caches/HACachedUser.swift",
        "Caches/HACachesContainer.swift",
        "Convenience/CurrentUser.swift",
        "Convenience/Event.swift",
        "Convenience/RenderTemplate.swift",
        "Convenience/Services.swift",
        "Convenience/States.swift",
        "Data/HACompressedEntity.swift",
        "Data/HAData.swift",
        "Data/HADataDecodable.swift",
        "Data/HADecodeTransformable.swift",
        "Data/HAEntity+CompressedEntity.swift",
        "Data/HAEntity.swift",
        "Data/HAService.swift",
        "HAConnection.swift",
        "HAConnectionConfiguration.swift",
        "HAConnectionInfo.swift",
        "HAError.swift",
        "HAGlobal.swift",
        "HAKit.swift",
        "HARequestToken.swift",
        "HAURLSessionDelegate.swift",
        "Internal/HACancellableImpl.swift",
        "Internal/HAConnectionImpl+Requests.swift",
        "Internal/HAConnectionImpl+Responses.swift",
        "Internal/HAConnectionImpl.swift",
        "Internal/HAProtected.swift",
        "Internal/HAReconnectManager.swift",
        "Internal/HAResetLock.swift",
        "Internal/HASchedulingTimer.swift",
        "Internal/HAStarscreamCertificatePinningImpl.swift",
        "Internal/HAURLSessionWebSocketEngine.swift",
        "Internal/RequestController/HARequestController.swift",
        "Internal/RequestController/HARequestIdentifier.swift",
        "Internal/RequestController/HARequestInvocation.swift",
        "Internal/RequestController/HARequestInvocationSingle.swift",
        "Internal/RequestController/HARequestInvocationSubscription.swift",
        "Internal/ResponseController/HAResponseController.swift",
        "Internal/ResponseController/HAWebSocketResponse.swift",
        "Requests/HAHTTPMethod.swift",
        "Requests/HARequest.swift",
        "Requests/HARequestType.swift",
        "Requests/HAResponseVoid.swift",
        "Requests/HASttData.swift",
        "Requests/HATypedRequest.swift",
        "Requests/HATypedSubscription.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.3"
}
Done.