The Swift Package Index logo.Swift Package Index

Build Information

Failed to build HealthSnapKit, reference main (6e7adf), with Swift 6.3 for macOS (SPM) on 10 Apr 2026 21:14:02 UTC.

Build Command

env DEVELOPER_DIR=/Applications/Xcode-26.4.0.app xcrun swift build --arch arm64

Build Log

 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
39 |     }
40 |
41 |     static func statistics(
   |                 `- note: add '@available' attribute to enclosing static method
42 |         store: HKHealthStore,
43 |         quantityType: HKQuantityType,
44 |         predicate: NSPredicate,
45 |         options: HKStatisticsOptions
   |                  `- error: 'HKStatisticsOptions' is only available in macOS 13.0 or newer
46 |     ) async throws -> HKStatistics? {
47 |         try await withCheckedThrowingContinuation { continuation in
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:46:23: error: 'HKStatistics' is only available in macOS 13.0 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
39 |     }
40 |
41 |     static func statistics(
   |                 `- note: add '@available' attribute to enclosing static method
42 |         store: HKHealthStore,
43 |         quantityType: HKQuantityType,
44 |         predicate: NSPredicate,
45 |         options: HKStatisticsOptions
46 |     ) async throws -> HKStatistics? {
   |                       `- error: 'HKStatistics' is only available in macOS 13.0 or newer
47 |         try await withCheckedThrowingContinuation { continuation in
48 |             let query = HKStatisticsQuery(quantityType: quantityType, quantitySamplePredicate: predicate, options: options) { _, stats, error in
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:64:16: error: 'HKHealthStore' is only available in macOS 13.0 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
61 |     }
62 |
63 |     static func samples(
   |                 `- note: add '@available' attribute to enclosing static method
64 |         store: HKHealthStore,
   |                `- error: 'HKHealthStore' is only available in macOS 13.0 or newer
65 |         sampleType: HKSampleType,
66 |         predicate: NSPredicate,
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:65:21: error: 'HKSampleType' is only available in macOS 13.0 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
61 |     }
62 |
63 |     static func samples(
   |                 `- note: add '@available' attribute to enclosing static method
64 |         store: HKHealthStore,
65 |         sampleType: HKSampleType,
   |                     `- error: 'HKSampleType' is only available in macOS 13.0 or newer
66 |         predicate: NSPredicate,
67 |         limit: Int,
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:69:24: error: 'HKSample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
61 |     }
62 |
63 |     static func samples(
   |                 `- note: add '@available' attribute to enclosing static method
64 |         store: HKHealthStore,
65 |         sampleType: HKSampleType,
   :
67 |         limit: Int,
68 |         sortDescriptors: [NSSortDescriptor]
69 |     ) async throws -> [HKSample] {
   |                        `- error: 'HKSample' is only available in macOS 13.0 or newer
70 |         try await withCheckedThrowingContinuation { continuation in
71 |             let query = HKSampleQuery(
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:14:19: error: 'withCheckedThrowingContinuation(isolation:function:_:)' is only available in macOS 10.15 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
   |                 `- note: add '@available' attribute to enclosing static method
 7 |         store: HKHealthStore,
 8 |         quantityType: HKQuantityType,
   :
12 |         intervalComponents: DateComponents
13 |     ) async throws -> HKStatisticsCollection {
14 |         try await withCheckedThrowingContinuation { continuation in
   |                   |- error: 'withCheckedThrowingContinuation(isolation:function:_:)' is only available in macOS 10.15 or newer
   |                   `- note: add 'if #available' version check
15 |             let query = HKStatisticsCollectionQuery(
16 |                 quantityType: quantityType,
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:24:24: error: 'HKError' is only available in macOS 13.0 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
   |                 `- note: add '@available' attribute to enclosing static method
 7 |         store: HKHealthStore,
 8 |         quantityType: HKQuantityType,
   :
22 |             query.initialResultsHandler = { _, collection, error in
23 |                 if let error {
24 |                     if HKError.isNoMatchingSamples(error) {
   |                        |- error: 'HKError' is only available in macOS 13.0 or newer
   |                        `- note: add 'if #available' version check
25 |                         continuation.resume(throwing: HealthSnapError.noData)
26 |                     } else {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:14:52: error: 'isolation()' is only available in macOS 10.15 or newer
`- /Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:14:51: note: expanded code originates here
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
   |                 `- note: add '@available' attribute to enclosing static method
 7 |         store: HKHealthStore,
 8 |         quantityType: HKQuantityType,
   :
12 |         intervalComponents: DateComponents
13 |     ) async throws -> HKStatisticsCollection {
14 |         try await withCheckedThrowingContinuation { continuation in
   +--- /Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift
   |12 |
   |13 |
   |14 |                                                   #isolation
   |   |                                                    `- error: 'isolation()' is only available in macOS 10.15 or newer
   +-------------------------------------------------------------------------------------------------
15 |             let query = HKStatisticsCollectionQuery(
16 |                 quantityType: quantityType,
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:47:19: error: 'withCheckedThrowingContinuation(isolation:function:_:)' is only available in macOS 10.15 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
39 |     }
40 |
41 |     static func statistics(
   |                 `- note: add '@available' attribute to enclosing static method
42 |         store: HKHealthStore,
43 |         quantityType: HKQuantityType,
   :
45 |         options: HKStatisticsOptions
46 |     ) async throws -> HKStatistics? {
47 |         try await withCheckedThrowingContinuation { continuation in
   |                   |- error: 'withCheckedThrowingContinuation(isolation:function:_:)' is only available in macOS 10.15 or newer
   |                   `- note: add 'if #available' version check
48 |             let query = HKStatisticsQuery(quantityType: quantityType, quantitySamplePredicate: predicate, options: options) { _, stats, error in
49 |                 if let error {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:50:24: error: 'HKError' is only available in macOS 13.0 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
39 |     }
40 |
41 |     static func statistics(
   |                 `- note: add '@available' attribute to enclosing static method
42 |         store: HKHealthStore,
43 |         quantityType: HKQuantityType,
   :
48 |             let query = HKStatisticsQuery(quantityType: quantityType, quantitySamplePredicate: predicate, options: options) { _, stats, error in
49 |                 if let error {
50 |                     if HKError.isNoMatchingSamples(error) {
   |                        |- error: 'HKError' is only available in macOS 13.0 or newer
   |                        `- note: add 'if #available' version check
51 |                         continuation.resume(returning: nil)
52 |                     } else {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:47:52: error: 'isolation()' is only available in macOS 10.15 or newer
`- /Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:47:51: note: expanded code originates here
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
39 |     }
40 |
41 |     static func statistics(
   |                 `- note: add '@available' attribute to enclosing static method
42 |         store: HKHealthStore,
43 |         quantityType: HKQuantityType,
   :
45 |         options: HKStatisticsOptions
46 |     ) async throws -> HKStatistics? {
47 |         try await withCheckedThrowingContinuation { continuation in
   +--- /Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift
   |45 |
   |46 |
   |47 |                                                   #isolation
   |   |                                                    `- error: 'isolation()' is only available in macOS 10.15 or newer
   +-------------------------------------------------------------------------------------------------
48 |             let query = HKStatisticsQuery(quantityType: quantityType, quantitySamplePredicate: predicate, options: options) { _, stats, error in
49 |                 if let error {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:70:19: error: 'withCheckedThrowingContinuation(isolation:function:_:)' is only available in macOS 10.15 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
61 |     }
62 |
63 |     static func samples(
   |                 `- note: add '@available' attribute to enclosing static method
64 |         store: HKHealthStore,
65 |         sampleType: HKSampleType,
   :
68 |         sortDescriptors: [NSSortDescriptor]
69 |     ) async throws -> [HKSample] {
70 |         try await withCheckedThrowingContinuation { continuation in
   |                   |- error: 'withCheckedThrowingContinuation(isolation:function:_:)' is only available in macOS 10.15 or newer
   |                   `- note: add 'if #available' version check
71 |             let query = HKSampleQuery(
72 |                 sampleType: sampleType,
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:78:24: error: 'HKError' is only available in macOS 13.0 or newer
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
61 |     }
62 |
63 |     static func samples(
   |                 `- note: add '@available' attribute to enclosing static method
64 |         store: HKHealthStore,
65 |         sampleType: HKSampleType,
   :
76 |             ) { _, samples, error in
77 |                 if let error {
78 |                     if HKError.isNoMatchingSamples(error) {
   |                        |- error: 'HKError' is only available in macOS 13.0 or newer
   |                        `- note: add 'if #available' version check
79 |                         continuation.resume(returning: [])
80 |                     } else {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:70:52: error: 'isolation()' is only available in macOS 10.15 or newer
`- /Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift:70:51: note: expanded code originates here
 3 |
 4 | /// Async wrappers around completion-handler-based HealthKit queries (used by ``LiveHealthStore``).
 5 | enum HKQueryAsync {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func statisticsCollection(
 7 |         store: HKHealthStore,
   :
61 |     }
62 |
63 |     static func samples(
   |                 `- note: add '@available' attribute to enclosing static method
64 |         store: HKHealthStore,
65 |         sampleType: HKSampleType,
   :
68 |         sortDescriptors: [NSSortDescriptor]
69 |     ) async throws -> [HKSample] {
70 |         try await withCheckedThrowingContinuation { continuation in
   +--- /Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/HKQueryAsync.swift
   |68 |
   |69 |
   |70 |                                                   #isolation
   |   |                                                    `- error: 'isolation()' is only available in macOS 10.15 or newer
   +-------------------------------------------------------------------------------------------------
71 |             let query = HKSampleQuery(
72 |                 sampleType: sampleType,
[14/20] Compiling HealthSnapKit SleepSnapshot.swift
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:102:111: error: 'HKStatistics' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
100 |     }
101 |
102 |     private func statistics(for identifier: HKQuantityTypeIdentifier, predicate: NSPredicate) async throws -> HKStatistics? {
    |                  |                                                                                            `- error: 'HKStatistics' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
103 |         guard let type = HKQuantityType.quantityType(forIdentifier: identifier) else {
104 |             throw HealthSnapError.noData
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:113:39: error: 'HKStatistics' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
111 |     }
112 |
113 |     private func sum(from statistics: HKStatistics?, type identifier: HKQuantityTypeIdentifier, unit: HKUnit) async throws -> Double {
    |                  |                    `- error: 'HKStatistics' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
114 |         guard let statistics, let _ = HKQuantityType.quantityType(forIdentifier: identifier) else {
115 |             return 0
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:113:103: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
111 |     }
112 |
113 |     private func sum(from statistics: HKStatistics?, type identifier: HKQuantityTypeIdentifier, unit: HKUnit) async throws -> Double {
    |                  |                                                                                    `- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
114 |         guard let statistics, let _ = HKQuantityType.quantityType(forIdentifier: identifier) else {
115 |             return 0
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:123:76: error: 'HKCategorySample' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  |                                                         `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
125 |             return []
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:136:44: error: 'HKCategorySample' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
134 |     }
135 |
136 |     private func countStoodHours(samples: [HKCategorySample]) -> Int {
    |                  |                         `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
137 |         samples.filter { sample in
138 |             sample.value == HKCategoryValueAppleStandHour.stood.rawValue
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:58:25: error: 'HKQuery' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
 56 |             throw HealthSnapError.noData
 57 |         }
 58 |         let predicate = HKQuery.predicateForSamples(withStart: interval.start, end: interval.endExclusive, options: [])
    |                         |- error: 'HKQuery' is only available in macOS 13.0 or newer
    |                         `- note: add 'if #available' version check
 59 |
 60 |         var sawData = false
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:62:53: error: 'stepCount' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 60 |         var sawData = false
 61 |
 62 |         let stepsStats = try await statistics(for: .stepCount, predicate: predicate)
    |                                                     |- error: 'stepCount' is only available in macOS 13.0 or newer
    |                                                     `- note: add 'if #available' version check
 63 |         if stepsStats != nil { sawData = true }
 64 |         let steps = Int((try await sum(from: stepsStats, type: .stepCount, unit: HKUnit.count())).rounded())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:64:65: error: 'stepCount' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 62 |         let stepsStats = try await statistics(for: .stepCount, predicate: predicate)
 63 |         if stepsStats != nil { sawData = true }
 64 |         let steps = Int((try await sum(from: stepsStats, type: .stepCount, unit: HKUnit.count())).rounded())
    |                                                                 |- error: 'stepCount' is only available in macOS 13.0 or newer
    |                                                                 `- note: add 'if #available' version check
 65 |
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:64:82: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 62 |         let stepsStats = try await statistics(for: .stepCount, predicate: predicate)
 63 |         if stepsStats != nil { sawData = true }
 64 |         let steps = Int((try await sum(from: stepsStats, type: .stepCount, unit: HKUnit.count())).rounded())
    |                                                                                  |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                  `- note: add 'if #available' version check
 65 |
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:66:54: error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 64 |         let steps = Int((try await sum(from: stepsStats, type: .stepCount, unit: HKUnit.count())).rounded())
 65 |
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
    |                                                      |- error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
    |                                                      `- note: add 'if #available' version check
 67 |         if activeStats != nil { sawData = true }
 68 |         let active = try await sum(from: activeStats, type: .activeEnergyBurned, unit: HKUnit.kilocalorie())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:68:62: error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
 67 |         if activeStats != nil { sawData = true }
 68 |         let active = try await sum(from: activeStats, type: .activeEnergyBurned, unit: HKUnit.kilocalorie())
    |                                                              |- error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
    |                                                              `- note: add 'if #available' version check
 69 |
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:68:88: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
 67 |         if activeStats != nil { sawData = true }
 68 |         let active = try await sum(from: activeStats, type: .activeEnergyBurned, unit: HKUnit.kilocalorie())
    |                                                                                        |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                        `- note: add 'if #available' version check
 69 |
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:70:53: error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 68 |         let active = try await sum(from: activeStats, type: .activeEnergyBurned, unit: HKUnit.kilocalorie())
 69 |
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
    |                                                     |- error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
    |                                                     `- note: add 'if #available' version check
 71 |         if basalStats != nil { sawData = true }
 72 |         let basal = try await sum(from: basalStats, type: .basalEnergyBurned, unit: HKUnit.kilocalorie())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:72:60: error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
 71 |         if basalStats != nil { sawData = true }
 72 |         let basal = try await sum(from: basalStats, type: .basalEnergyBurned, unit: HKUnit.kilocalorie())
    |                                                            |- error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
    |                                                            `- note: add 'if #available' version check
 73 |
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:72:85: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
 71 |         if basalStats != nil { sawData = true }
 72 |         let basal = try await sum(from: basalStats, type: .basalEnergyBurned, unit: HKUnit.kilocalorie())
    |                                                                                     |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                     `- note: add 'if #available' version check
 73 |
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:74:56: error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 72 |         let basal = try await sum(from: basalStats, type: .basalEnergyBurned, unit: HKUnit.kilocalorie())
 73 |
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
    |                                                        |- error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
    |                                                        `- note: add 'if #available' version check
 75 |         if distanceStats != nil { sawData = true }
 76 |         let distance = try await sum(from: distanceStats, type: .distanceWalkingRunning, unit: HKUnit.meter())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:76:66: error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
 75 |         if distanceStats != nil { sawData = true }
 76 |         let distance = try await sum(from: distanceStats, type: .distanceWalkingRunning, unit: HKUnit.meter())
    |                                                                  |- error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
    |                                                                  `- note: add 'if #available' version check
 77 |
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:76:96: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
 75 |         if distanceStats != nil { sawData = true }
 76 |         let distance = try await sum(from: distanceStats, type: .distanceWalkingRunning, unit: HKUnit.meter())
    |                                                                                                |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                                `- note: add 'if #available' version check
 77 |
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:78:56: error: 'appleExerciseTime' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 76 |         let distance = try await sum(from: distanceStats, type: .distanceWalkingRunning, unit: HKUnit.meter())
 77 |
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
    |                                                        |- error: 'appleExerciseTime' is only available in macOS 13.0 or newer
    |                                                        `- note: add 'if #available' version check
 79 |         if exerciseStats != nil { sawData = true }
 80 |         let exerciseMinutes = Int((try await sum(from: exerciseStats, type: .appleExerciseTime, unit: HKUnit.minute())).rounded())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:80:78: error: 'appleExerciseTime' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
 79 |         if exerciseStats != nil { sawData = true }
 80 |         let exerciseMinutes = Int((try await sum(from: exerciseStats, type: .appleExerciseTime, unit: HKUnit.minute())).rounded())
    |                                                                              |- error: 'appleExerciseTime' is only available in macOS 13.0 or newer
    |                                                                              `- note: add 'if #available' version check
 81 |
 82 |         let standSamples = try await standHourSamples(predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:80:103: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
 79 |         if exerciseStats != nil { sawData = true }
 80 |         let exerciseMinutes = Int((try await sum(from: exerciseStats, type: .appleExerciseTime, unit: HKUnit.minute())).rounded())
    |                                                                                                       |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                                       `- note: add 'if #available' version check
 81 |
 82 |         let standSamples = try await standHourSamples(predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:103:26: error: 'HKQuantityType' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
100 |     }
101 |
102 |     private func statistics(for identifier: HKQuantityTypeIdentifier, predicate: NSPredicate) async throws -> HKStatistics? {
    |                  `- note: add '@available' attribute to enclosing instance method
103 |         guard let type = HKQuantityType.quantityType(forIdentifier: identifier) else {
    |                          |- error: 'HKQuantityType' is only available in macOS 13.0 or newer
    |                          `- note: add 'if #available' version check
104 |             throw HealthSnapError.noData
105 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:114:39: error: 'HKQuantityType' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
111 |     }
112 |
113 |     private func sum(from statistics: HKStatistics?, type identifier: HKQuantityTypeIdentifier, unit: HKUnit) async throws -> Double {
    |                  `- note: add '@available' attribute to enclosing instance method
114 |         guard let statistics, let _ = HKQuantityType.quantityType(forIdentifier: identifier) else {
    |                                       |- error: 'HKQuantityType' is only available in macOS 13.0 or newer
    |                                       `- note: add 'if #available' version check
115 |             return 0
116 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:124:31: error: 'HKObjectType' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
    |                               |- error: 'HKObjectType' is only available in macOS 13.0 or newer
    |                               `- note: add 'if #available' version check
125 |             return []
126 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:124:73: error: 'appleStandHour' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
    |                                                                         |- error: 'appleStandHour' is only available in macOS 13.0 or newer
    |                                                                         `- note: add 'if #available' version check
125 |             return []
126 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:131:53: error: 'HKSampleSortIdentifierStartDate' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
125 |             return []
    :
129 |             predicate: predicate,
130 |             limit: HKObjectQueryNoLimit,
131 |             sortDescriptors: [NSSortDescriptor(key: HKSampleSortIdentifierStartDate, ascending: true)]
    |                                                     |- error: 'HKSampleSortIdentifierStartDate' is only available in macOS 13.0 or newer
    |                                                     `- note: add 'if #available' version check
132 |         )
133 |         return raw.compactMap { $0 as? HKCategorySample }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:133:40: error: 'HKCategorySample' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
125 |             return []
    :
131 |             sortDescriptors: [NSSortDescriptor(key: HKSampleSortIdentifierStartDate, ascending: true)]
132 |         )
133 |         return raw.compactMap { $0 as? HKCategorySample }
    |                                        |- error: 'HKCategorySample' is only available in macOS 13.0 or newer
    |                                        `- note: add 'if #available' version check
134 |     }
135 |
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:138:29: error: 'HKCategoryValueAppleStandHour' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
134 |     }
135 |
136 |     private func countStoodHours(samples: [HKCategorySample]) -> Int {
    |                  `- note: add '@available' attribute to enclosing instance method
137 |         samples.filter { sample in
138 |             sample.value == HKCategoryValueAppleStandHour.stood.rawValue
    |                             |- error: 'HKCategoryValueAppleStandHour' is only available in macOS 13.0 or newer
    |                             `- note: add 'if #available' version check
139 |         }.count
140 |     }
[15/20] Compiling HealthSnapKit ActivityProvider.swift
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:102:111: error: 'HKStatistics' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
100 |     }
101 |
102 |     private func statistics(for identifier: HKQuantityTypeIdentifier, predicate: NSPredicate) async throws -> HKStatistics? {
    |                  |                                                                                            `- error: 'HKStatistics' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
103 |         guard let type = HKQuantityType.quantityType(forIdentifier: identifier) else {
104 |             throw HealthSnapError.noData
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:113:39: error: 'HKStatistics' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
111 |     }
112 |
113 |     private func sum(from statistics: HKStatistics?, type identifier: HKQuantityTypeIdentifier, unit: HKUnit) async throws -> Double {
    |                  |                    `- error: 'HKStatistics' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
114 |         guard let statistics, let _ = HKQuantityType.quantityType(forIdentifier: identifier) else {
115 |             return 0
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:113:103: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
111 |     }
112 |
113 |     private func sum(from statistics: HKStatistics?, type identifier: HKQuantityTypeIdentifier, unit: HKUnit) async throws -> Double {
    |                  |                                                                                    `- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
114 |         guard let statistics, let _ = HKQuantityType.quantityType(forIdentifier: identifier) else {
115 |             return 0
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:123:76: error: 'HKCategorySample' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  |                                                         `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
125 |             return []
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:136:44: error: 'HKCategorySample' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
134 |     }
135 |
136 |     private func countStoodHours(samples: [HKCategorySample]) -> Int {
    |                  |                         `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
    |                  `- note: add '@available' attribute to enclosing instance method
137 |         samples.filter { sample in
138 |             sample.value == HKCategoryValueAppleStandHour.stood.rawValue
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:58:25: error: 'HKQuery' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
 56 |             throw HealthSnapError.noData
 57 |         }
 58 |         let predicate = HKQuery.predicateForSamples(withStart: interval.start, end: interval.endExclusive, options: [])
    |                         |- error: 'HKQuery' is only available in macOS 13.0 or newer
    |                         `- note: add 'if #available' version check
 59 |
 60 |         var sawData = false
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:62:53: error: 'stepCount' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 60 |         var sawData = false
 61 |
 62 |         let stepsStats = try await statistics(for: .stepCount, predicate: predicate)
    |                                                     |- error: 'stepCount' is only available in macOS 13.0 or newer
    |                                                     `- note: add 'if #available' version check
 63 |         if stepsStats != nil { sawData = true }
 64 |         let steps = Int((try await sum(from: stepsStats, type: .stepCount, unit: HKUnit.count())).rounded())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:64:65: error: 'stepCount' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 62 |         let stepsStats = try await statistics(for: .stepCount, predicate: predicate)
 63 |         if stepsStats != nil { sawData = true }
 64 |         let steps = Int((try await sum(from: stepsStats, type: .stepCount, unit: HKUnit.count())).rounded())
    |                                                                 |- error: 'stepCount' is only available in macOS 13.0 or newer
    |                                                                 `- note: add 'if #available' version check
 65 |
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:64:82: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 62 |         let stepsStats = try await statistics(for: .stepCount, predicate: predicate)
 63 |         if stepsStats != nil { sawData = true }
 64 |         let steps = Int((try await sum(from: stepsStats, type: .stepCount, unit: HKUnit.count())).rounded())
    |                                                                                  |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                  `- note: add 'if #available' version check
 65 |
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:66:54: error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 64 |         let steps = Int((try await sum(from: stepsStats, type: .stepCount, unit: HKUnit.count())).rounded())
 65 |
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
    |                                                      |- error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
    |                                                      `- note: add 'if #available' version check
 67 |         if activeStats != nil { sawData = true }
 68 |         let active = try await sum(from: activeStats, type: .activeEnergyBurned, unit: HKUnit.kilocalorie())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:68:62: error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
 67 |         if activeStats != nil { sawData = true }
 68 |         let active = try await sum(from: activeStats, type: .activeEnergyBurned, unit: HKUnit.kilocalorie())
    |                                                              |- error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
    |                                                              `- note: add 'if #available' version check
 69 |
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:68:88: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 66 |         let activeStats = try await statistics(for: .activeEnergyBurned, predicate: predicate)
 67 |         if activeStats != nil { sawData = true }
 68 |         let active = try await sum(from: activeStats, type: .activeEnergyBurned, unit: HKUnit.kilocalorie())
    |                                                                                        |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                        `- note: add 'if #available' version check
 69 |
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:70:53: error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 68 |         let active = try await sum(from: activeStats, type: .activeEnergyBurned, unit: HKUnit.kilocalorie())
 69 |
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
    |                                                     |- error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
    |                                                     `- note: add 'if #available' version check
 71 |         if basalStats != nil { sawData = true }
 72 |         let basal = try await sum(from: basalStats, type: .basalEnergyBurned, unit: HKUnit.kilocalorie())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:72:60: error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
 71 |         if basalStats != nil { sawData = true }
 72 |         let basal = try await sum(from: basalStats, type: .basalEnergyBurned, unit: HKUnit.kilocalorie())
    |                                                            |- error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
    |                                                            `- note: add 'if #available' version check
 73 |
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:72:85: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 70 |         let basalStats = try await statistics(for: .basalEnergyBurned, predicate: predicate)
 71 |         if basalStats != nil { sawData = true }
 72 |         let basal = try await sum(from: basalStats, type: .basalEnergyBurned, unit: HKUnit.kilocalorie())
    |                                                                                     |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                     `- note: add 'if #available' version check
 73 |
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:74:56: error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 72 |         let basal = try await sum(from: basalStats, type: .basalEnergyBurned, unit: HKUnit.kilocalorie())
 73 |
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
    |                                                        |- error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
    |                                                        `- note: add 'if #available' version check
 75 |         if distanceStats != nil { sawData = true }
 76 |         let distance = try await sum(from: distanceStats, type: .distanceWalkingRunning, unit: HKUnit.meter())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:76:66: error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
 75 |         if distanceStats != nil { sawData = true }
 76 |         let distance = try await sum(from: distanceStats, type: .distanceWalkingRunning, unit: HKUnit.meter())
    |                                                                  |- error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
    |                                                                  `- note: add 'if #available' version check
 77 |
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:76:96: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 74 |         let distanceStats = try await statistics(for: .distanceWalkingRunning, predicate: predicate)
 75 |         if distanceStats != nil { sawData = true }
 76 |         let distance = try await sum(from: distanceStats, type: .distanceWalkingRunning, unit: HKUnit.meter())
    |                                                                                                |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                                `- note: add 'if #available' version check
 77 |
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:78:56: error: 'appleExerciseTime' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 76 |         let distance = try await sum(from: distanceStats, type: .distanceWalkingRunning, unit: HKUnit.meter())
 77 |
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
    |                                                        |- error: 'appleExerciseTime' is only available in macOS 13.0 or newer
    |                                                        `- note: add 'if #available' version check
 79 |         if exerciseStats != nil { sawData = true }
 80 |         let exerciseMinutes = Int((try await sum(from: exerciseStats, type: .appleExerciseTime, unit: HKUnit.minute())).rounded())
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:80:78: error: 'appleExerciseTime' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
 79 |         if exerciseStats != nil { sawData = true }
 80 |         let exerciseMinutes = Int((try await sum(from: exerciseStats, type: .appleExerciseTime, unit: HKUnit.minute())).rounded())
    |                                                                              |- error: 'appleExerciseTime' is only available in macOS 13.0 or newer
    |                                                                              `- note: add 'if #available' version check
 81 |
 82 |         let standSamples = try await standHourSamples(predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:80:103: error: 'HKUnit' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
 51 |     }
 52 |
 53 |     private func date(_ date: Date, calendar: Calendar) async throws -> ActivitySnapshot {
    |                  `- note: add '@available' attribute to enclosing instance method
 54 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
 55 |         guard let interval = CalendarDayRange.dayInterval(containing: date, calendar: calendar) else {
    :
 78 |         let exerciseStats = try await statistics(for: .appleExerciseTime, predicate: predicate)
 79 |         if exerciseStats != nil { sawData = true }
 80 |         let exerciseMinutes = Int((try await sum(from: exerciseStats, type: .appleExerciseTime, unit: HKUnit.minute())).rounded())
    |                                                                                                       |- error: 'HKUnit' is only available in macOS 13.0 or newer
    |                                                                                                       `- note: add 'if #available' version check
 81 |
 82 |         let standSamples = try await standHourSamples(predicate: predicate)
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:103:26: error: 'HKQuantityType' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
100 |     }
101 |
102 |     private func statistics(for identifier: HKQuantityTypeIdentifier, predicate: NSPredicate) async throws -> HKStatistics? {
    |                  `- note: add '@available' attribute to enclosing instance method
103 |         guard let type = HKQuantityType.quantityType(forIdentifier: identifier) else {
    |                          |- error: 'HKQuantityType' is only available in macOS 13.0 or newer
    |                          `- note: add 'if #available' version check
104 |             throw HealthSnapError.noData
105 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:114:39: error: 'HKQuantityType' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
111 |     }
112 |
113 |     private func sum(from statistics: HKStatistics?, type identifier: HKQuantityTypeIdentifier, unit: HKUnit) async throws -> Double {
    |                  `- note: add '@available' attribute to enclosing instance method
114 |         guard let statistics, let _ = HKQuantityType.quantityType(forIdentifier: identifier) else {
    |                                       |- error: 'HKQuantityType' is only available in macOS 13.0 or newer
    |                                       `- note: add 'if #available' version check
115 |             return 0
116 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:124:31: error: 'HKObjectType' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
    |                               |- error: 'HKObjectType' is only available in macOS 13.0 or newer
    |                               `- note: add 'if #available' version check
125 |             return []
126 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:124:73: error: 'appleStandHour' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
    |                                                                         |- error: 'appleStandHour' is only available in macOS 13.0 or newer
    |                                                                         `- note: add 'if #available' version check
125 |             return []
126 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:131:53: error: 'HKSampleSortIdentifierStartDate' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
125 |             return []
    :
129 |             predicate: predicate,
130 |             limit: HKObjectQueryNoLimit,
131 |             sortDescriptors: [NSSortDescriptor(key: HKSampleSortIdentifierStartDate, ascending: true)]
    |                                                     |- error: 'HKSampleSortIdentifierStartDate' is only available in macOS 13.0 or newer
    |                                                     `- note: add 'if #available' version check
132 |         )
133 |         return raw.compactMap { $0 as? HKCategorySample }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:133:40: error: 'HKCategorySample' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
121 |     }
122 |
123 |     private func standHourSamples(predicate: NSPredicate) async throws -> [HKCategorySample] {
    |                  `- note: add '@available' attribute to enclosing instance method
124 |         guard let standType = HKObjectType.categoryType(forIdentifier: .appleStandHour) else {
125 |             return []
    :
131 |             sortDescriptors: [NSSortDescriptor(key: HKSampleSortIdentifierStartDate, ascending: true)]
132 |         )
133 |         return raw.compactMap { $0 as? HKCategorySample }
    |                                        |- error: 'HKCategorySample' is only available in macOS 13.0 or newer
    |                                        `- note: add 'if #available' version check
134 |     }
135 |
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/ActivityProvider.swift:138:29: error: 'HKCategoryValueAppleStandHour' is only available in macOS 13.0 or newer
  4 | /// Fetches daily activity summaries (steps, energy, distance, exercise, stand).
  5 | @MainActor
  6 | public final class ActivityProvider {
    |                    `- note: add '@available' attribute to enclosing class
  7 |     private let store: HealthStoreProtocol
  8 |
    :
134 |     }
135 |
136 |     private func countStoodHours(samples: [HKCategorySample]) -> Int {
    |                  `- note: add '@available' attribute to enclosing instance method
137 |         samples.filter { sample in
138 |             sample.value == HKCategoryValueAppleStandHour.stood.rawValue
    |                             |- error: 'HKCategoryValueAppleStandHour' is only available in macOS 13.0 or newer
    |                             `- note: add 'if #available' version check
139 |         }.count
140 |     }
[16/20] Compiling HealthSnapKit HealthKitPermissions.swift
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:19:79: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   |                        |                                                      `- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                        `- note: add '@available' attribute to enclosing static method
20 |         var types = Set<HKObjectType>()
21 |         for domain in domains {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:38:52: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         |                          `- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:49:49: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         |                       `- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:57:48: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         |                      `- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:20:25: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   |                        `- note: add '@available' attribute to enclosing static method
20 |         var types = Set<HKObjectType>()
   |                         |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                         `- note: add 'if #available' version check
21 |         for domain in domains {
22 |             switch domain {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:26:36: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   |                        `- note: add '@available' attribute to enclosing static method
20 |         var types = Set<HKObjectType>()
21 |         for domain in domains {
   :
24 |                 types.formUnion(activityReadTypes())
25 |             case .sleep:
26 |                 if let sleepType = HKObjectType.categoryType(forIdentifier: .sleepAnalysis) {
   |                                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                                    `- note: add 'if #available' version check
27 |                     types.insert(sleepType)
28 |                 }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:26:78: error: 'sleepAnalysis' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   |                        `- note: add '@available' attribute to enclosing static method
20 |         var types = Set<HKObjectType>()
21 |         for domain in domains {
   :
24 |                 types.formUnion(activityReadTypes())
25 |             case .sleep:
26 |                 if let sleepType = HKObjectType.categoryType(forIdentifier: .sleepAnalysis) {
   |                                                                              |- error: 'sleepAnalysis' is only available in macOS 13.0 or newer
   |                                                                              `- note: add 'if #available' version check
27 |                     types.insert(sleepType)
28 |                 }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:39:23: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
   |                       |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                       `- note: add 'if #available' version check
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:40:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:40:62: error: 'stepCount' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   |                                                              |- error: 'stepCount' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:41:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:41:62: error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
   |                                                              |- error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:42:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:42:62: error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
   |                                                              |- error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:43:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:43:62: error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
   |                                                              |- error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:44:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   :
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
46 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:44:62: error: 'appleExerciseTime' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   :
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
   |                                                              |- error: 'appleExerciseTime' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
46 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:45:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   :
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
46 |         return set
47 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:45:62: error: 'appleStandHour' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   :
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
   |                                                              |- error: 'appleStandHour' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
46 |         return set
47 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:50:23: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
   |                       |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                       `- note: add 'if #available' version check
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:51:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:51:62: error: 'heartRate' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
   |                                                              |- error: 'heartRate' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:52:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
54 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:52:62: error: 'restingHeartRate' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
   |                                                              |- error: 'restingHeartRate' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
54 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:53:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
54 |         return set
55 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:53:62: error: 'heartRateVariabilitySDNN' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
   |                                                              |- error: 'heartRateVariabilitySDNN' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
54 |         return set
55 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:58:23: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
   |                       |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                       `- note: add 'if #available' version check
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:59:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:59:62: error: 'bodyMass' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
   |                                                              |- error: 'bodyMass' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:60:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
62 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:60:62: error: 'bodyMassIndex' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
   |                                                              |- error: 'bodyMassIndex' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
62 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:61:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
62 |         return set
63 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:61:62: error: 'bodyFatPercentage' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
   |                                                              |- error: 'bodyFatPercentage' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
62 |         return set
63 |     }
[17/20] Compiling HealthSnapKit HealthSnapError.swift
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:19:79: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   |                        |                                                      `- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                        `- note: add '@available' attribute to enclosing static method
20 |         var types = Set<HKObjectType>()
21 |         for domain in domains {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:38:52: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         |                          `- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:49:49: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         |                       `- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:57:48: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         |                      `- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:20:25: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   |                        `- note: add '@available' attribute to enclosing static method
20 |         var types = Set<HKObjectType>()
   |                         |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                         `- note: add 'if #available' version check
21 |         for domain in domains {
22 |             switch domain {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:26:36: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   |                        `- note: add '@available' attribute to enclosing static method
20 |         var types = Set<HKObjectType>()
21 |         for domain in domains {
   :
24 |                 types.formUnion(activityReadTypes())
25 |             case .sleep:
26 |                 if let sleepType = HKObjectType.categoryType(forIdentifier: .sleepAnalysis) {
   |                                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                                    `- note: add 'if #available' version check
27 |                     types.insert(sleepType)
28 |                 }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:26:78: error: 'sleepAnalysis' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   |                        `- note: add '@available' attribute to enclosing static method
20 |         var types = Set<HKObjectType>()
21 |         for domain in domains {
   :
24 |                 types.formUnion(activityReadTypes())
25 |             case .sleep:
26 |                 if let sleepType = HKObjectType.categoryType(forIdentifier: .sleepAnalysis) {
   |                                                                              |- error: 'sleepAnalysis' is only available in macOS 13.0 or newer
   |                                                                              `- note: add 'if #available' version check
27 |                     types.insert(sleepType)
28 |                 }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:39:23: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
   |                       |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                       `- note: add 'if #available' version check
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:40:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:40:62: error: 'stepCount' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   |                                                              |- error: 'stepCount' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:41:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:41:62: error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
   |                                                              |- error: 'activeEnergyBurned' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:42:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:42:62: error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
   |                                                              |- error: 'basalEnergyBurned' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:43:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:43:62: error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
41 |         if let t = HKObjectType.quantityType(forIdentifier: .activeEnergyBurned) { set.insert(t) }
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
   |                                                              |- error: 'distanceWalkingRunning' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:44:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   :
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
46 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:44:62: error: 'appleExerciseTime' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   :
42 |         if let t = HKObjectType.quantityType(forIdentifier: .basalEnergyBurned) { set.insert(t) }
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
   |                                                              |- error: 'appleExerciseTime' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
46 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:45:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   :
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
46 |         return set
47 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:45:62: error: 'appleStandHour' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
36 |     }
37 |
38 |     private static func activityReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
39 |         var set = Set<HKObjectType>()
40 |         if let t = HKObjectType.quantityType(forIdentifier: .stepCount) { set.insert(t) }
   :
43 |         if let t = HKObjectType.quantityType(forIdentifier: .distanceWalkingRunning) { set.insert(t) }
44 |         if let t = HKObjectType.quantityType(forIdentifier: .appleExerciseTime) { set.insert(t) }
45 |         if let t = HKObjectType.categoryType(forIdentifier: .appleStandHour) { set.insert(t) }
   |                                                              |- error: 'appleStandHour' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
46 |         return set
47 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:50:23: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
   |                       |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                       `- note: add 'if #available' version check
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:51:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:51:62: error: 'heartRate' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
   |                                                              |- error: 'heartRate' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:52:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
54 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:52:62: error: 'restingHeartRate' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
   |                                                              |- error: 'restingHeartRate' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
54 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:53:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
54 |         return set
55 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:53:62: error: 'heartRateVariabilitySDNN' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
47 |     }
48 |
49 |     private static func heartReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
50 |         var set = Set<HKObjectType>()
51 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRate) { set.insert(t) }
52 |         if let t = HKObjectType.quantityType(forIdentifier: .restingHeartRate) { set.insert(t) }
53 |         if let t = HKObjectType.quantityType(forIdentifier: .heartRateVariabilitySDNN) { set.insert(t) }
   |                                                              |- error: 'heartRateVariabilitySDNN' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
54 |         return set
55 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:58:23: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
   |                       |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                       `- note: add 'if #available' version check
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:59:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:59:62: error: 'bodyMass' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
   |                                                              |- error: 'bodyMass' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:60:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
62 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:60:62: error: 'bodyMassIndex' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
   |                                                              |- error: 'bodyMassIndex' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
62 |         return set
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:61:20: error: 'HKObjectType' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
   |                    |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                    `- note: add 'if #available' version check
62 |         return set
63 |     }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Authorization/HealthKitPermissions.swift:61:62: error: 'bodyFatPercentage' is only available in macOS 13.0 or newer
15 |
16 | /// Maps ``HealthDataDomain`` values to concrete HealthKit object types for authorization.
17 | public enum HealthKitPermissions: Sendable {
   |             `- note: add '@available' attribute to enclosing enum
18 |     /// All sample and object types required to read data for the given domains.
19 |     public static func objectTypes(for domains: Set<HealthDataDomain>) -> Set<HKObjectType> {
   :
55 |     }
56 |
57 |     private static func bodyReadTypes() -> Set<HKObjectType> {
   |                         `- note: add '@available' attribute to enclosing static method
58 |         var set = Set<HKObjectType>()
59 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMass) { set.insert(t) }
60 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyMassIndex) { set.insert(t) }
61 |         if let t = HKObjectType.quantityType(forIdentifier: .bodyFatPercentage) { set.insert(t) }
   |                                                              |- error: 'bodyFatPercentage' is only available in macOS 13.0 or newer
   |                                                              `- note: add 'if #available' version check
62 |         return set
63 |     }
[18/20] Compiling HealthSnapKit SleepAnalysisAggregator.swift
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:6:42: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
   |                 |                        `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                 `- note: add '@available' attribute to enclosing static method
 7 |         guard !samples.isEmpty else { return [] }
 8 |         let sorted = samples.sorted { $0.startDate < $1.startDate }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:14:50: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
12 |
13 |     /// Splits samples into sessions when there is a gap longer than four hours.
14 |     private static func splitSessions(_ sorted: [HKCategorySample]) -> [[HKCategorySample]] {
   |                         |                        `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
15 |         var sessions: [[HKCategorySample]] = []
16 |         var current: [HKCategorySample] = []
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:14:74: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
12 |
13 |     /// Splits samples into sessions when there is a gap longer than four hours.
14 |     private static func splitSessions(_ sorted: [HKCategorySample]) -> [[HKCategorySample]] {
   |                         |                                                `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
15 |         var sessions: [[HKCategorySample]] = []
16 |         var current: [HKCategorySample] = []
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:32:49: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
30 |     }
31 |
32 |     private static func buildSnapshot(samples: [HKCategorySample], calendar: Calendar) -> SleepSnapshot? {
   |                         |                       `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
33 |         var awake: TimeInterval = 0
34 |         var rem: TimeInterval = 0
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:15:25: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
12 |
13 |     /// Splits samples into sessions when there is a gap longer than four hours.
14 |     private static func splitSessions(_ sorted: [HKCategorySample]) -> [[HKCategorySample]] {
   |                         `- note: add '@available' attribute to enclosing static method
15 |         var sessions: [[HKCategorySample]] = []
   |                         |- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                         `- note: add 'if #available' version check
16 |         var current: [HKCategorySample] = []
17 |         let gap: TimeInterval = 4 * 3600
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:16:23: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
12 |
13 |     /// Splits samples into sessions when there is a gap longer than four hours.
14 |     private static func splitSessions(_ sorted: [HKCategorySample]) -> [[HKCategorySample]] {
   |                         `- note: add '@available' attribute to enclosing static method
15 |         var sessions: [[HKCategorySample]] = []
16 |         var current: [HKCategorySample] = []
   |                       |- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                       `- note: add 'if #available' version check
17 |         let gap: TimeInterval = 4 * 3600
18 |         for sample in sorted {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:42:31: error: 'HKCategoryValueSleepAnalysis' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
30 |     }
31 |
32 |     private static func buildSnapshot(samples: [HKCategorySample], calendar: Calendar) -> SleepSnapshot? {
   |                         `- note: add '@available' attribute to enclosing static method
33 |         var awake: TimeInterval = 0
34 |         var rem: TimeInterval = 0
   :
40 |         for sample in samples {
41 |             let duration = sample.endDate.timeIntervalSince(sample.startDate)
42 |             guard let value = HKCategoryValueSleepAnalysis(rawValue: sample.value) else { continue }
   |                               |- error: 'HKCategoryValueSleepAnalysis' is only available in macOS 13.0 or newer
   |                               `- note: add 'if #available' version check
43 |             switch value {
44 |             case .inBed:
[19/20] Compiling HealthSnapKit ActivitySnapshot.swift
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:6:42: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
   |                 |                        `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                 `- note: add '@available' attribute to enclosing static method
 7 |         guard !samples.isEmpty else { return [] }
 8 |         let sorted = samples.sorted { $0.startDate < $1.startDate }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:14:50: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
12 |
13 |     /// Splits samples into sessions when there is a gap longer than four hours.
14 |     private static func splitSessions(_ sorted: [HKCategorySample]) -> [[HKCategorySample]] {
   |                         |                        `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
15 |         var sessions: [[HKCategorySample]] = []
16 |         var current: [HKCategorySample] = []
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:14:74: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
12 |
13 |     /// Splits samples into sessions when there is a gap longer than four hours.
14 |     private static func splitSessions(_ sorted: [HKCategorySample]) -> [[HKCategorySample]] {
   |                         |                                                `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
15 |         var sessions: [[HKCategorySample]] = []
16 |         var current: [HKCategorySample] = []
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:32:49: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
30 |     }
31 |
32 |     private static func buildSnapshot(samples: [HKCategorySample], calendar: Calendar) -> SleepSnapshot? {
   |                         |                       `- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                         `- note: add '@available' attribute to enclosing static method
33 |         var awake: TimeInterval = 0
34 |         var rem: TimeInterval = 0
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:15:25: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
12 |
13 |     /// Splits samples into sessions when there is a gap longer than four hours.
14 |     private static func splitSessions(_ sorted: [HKCategorySample]) -> [[HKCategorySample]] {
   |                         `- note: add '@available' attribute to enclosing static method
15 |         var sessions: [[HKCategorySample]] = []
   |                         |- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                         `- note: add 'if #available' version check
16 |         var current: [HKCategorySample] = []
17 |         let gap: TimeInterval = 4 * 3600
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:16:23: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
12 |
13 |     /// Splits samples into sessions when there is a gap longer than four hours.
14 |     private static func splitSessions(_ sorted: [HKCategorySample]) -> [[HKCategorySample]] {
   |                         `- note: add '@available' attribute to enclosing static method
15 |         var sessions: [[HKCategorySample]] = []
16 |         var current: [HKCategorySample] = []
   |                       |- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                       `- note: add 'if #available' version check
17 |         let gap: TimeInterval = 4 * 3600
18 |         for sample in sorted {
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Internal/SleepAnalysisAggregator.swift:42:31: error: 'HKCategoryValueSleepAnalysis' is only available in macOS 13.0 or newer
 3 |
 4 | /// Turns overlapping ``HKCategorySample`` sleep records into per-night ``SleepSnapshot`` values.
 5 | enum SleepAnalysisAggregator {
   |      `- note: add '@available' attribute to enclosing enum
 6 |     static func snapshots(from samples: [HKCategorySample], calendar: Calendar) -> [SleepSnapshot] {
 7 |         guard !samples.isEmpty else { return [] }
   :
30 |     }
31 |
32 |     private static func buildSnapshot(samples: [HKCategorySample], calendar: Calendar) -> SleepSnapshot? {
   |                         `- note: add '@available' attribute to enclosing static method
33 |         var awake: TimeInterval = 0
34 |         var rem: TimeInterval = 0
   :
40 |         for sample in samples {
41 |             let duration = sample.endDate.timeIntervalSince(sample.startDate)
42 |             guard let value = HKCategoryValueSleepAnalysis(rawValue: sample.value) else { continue }
   |                               |- error: 'HKCategoryValueSleepAnalysis' is only available in macOS 13.0 or newer
   |                               `- note: add 'if #available' version check
43 |             switch value {
44 |             case .inBed:
[20/20] Compiling HealthSnapKit SleepProvider.swift
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/SleepProvider.swift:40:31: error: 'HKObjectType' is only available in macOS 13.0 or newer
 4 | /// Fetches sleep stage summaries grouped into nights.
 5 | @MainActor
 6 | public final class SleepProvider {
   |                    `- note: add '@available' attribute to enclosing class
 7 |     private let store: HealthStoreProtocol
 8 |
   :
36 |
37 |     /// Fetches sleep snapshots for each detected night overlapping `range`.
38 |     public func range(_ range: ClosedRange<Date>) async throws -> [SleepSnapshot] {
   |                 `- note: add '@available' attribute to enclosing instance method
39 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
40 |         guard let sleepType = HKObjectType.categoryType(forIdentifier: .sleepAnalysis) else {
   |                               |- error: 'HKObjectType' is only available in macOS 13.0 or newer
   |                               `- note: add 'if #available' version check
41 |             throw HealthSnapError.noData
42 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/SleepProvider.swift:40:73: error: 'sleepAnalysis' is only available in macOS 13.0 or newer
 4 | /// Fetches sleep stage summaries grouped into nights.
 5 | @MainActor
 6 | public final class SleepProvider {
   |                    `- note: add '@available' attribute to enclosing class
 7 |     private let store: HealthStoreProtocol
 8 |
   :
36 |
37 |     /// Fetches sleep snapshots for each detected night overlapping `range`.
38 |     public func range(_ range: ClosedRange<Date>) async throws -> [SleepSnapshot] {
   |                 `- note: add '@available' attribute to enclosing instance method
39 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
40 |         guard let sleepType = HKObjectType.categoryType(forIdentifier: .sleepAnalysis) else {
   |                                                                         |- error: 'sleepAnalysis' is only available in macOS 13.0 or newer
   |                                                                         `- note: add 'if #available' version check
41 |             throw HealthSnapError.noData
42 |         }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/SleepProvider.swift:48:25: error: 'HKQuery' is only available in macOS 13.0 or newer
 4 | /// Fetches sleep stage summaries grouped into nights.
 5 | @MainActor
 6 | public final class SleepProvider {
   |                    `- note: add '@available' attribute to enclosing class
 7 |     private let store: HealthStoreProtocol
 8 |
   :
36 |
37 |     /// Fetches sleep snapshots for each detected night overlapping `range`.
38 |     public func range(_ range: ClosedRange<Date>) async throws -> [SleepSnapshot] {
   |                 `- note: add '@available' attribute to enclosing instance method
39 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
40 |         guard let sleepType = HKObjectType.categoryType(forIdentifier: .sleepAnalysis) else {
   :
46 |             throw HealthSnapError.noData
47 |         }
48 |         let predicate = HKQuery.predicateForSamples(withStart: start, end: endExclusive, options: [])
   |                         |- error: 'HKQuery' is only available in macOS 13.0 or newer
   |                         `- note: add 'if #available' version check
49 |         let raw = try await store.samples(
50 |             sampleType: sleepType,
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/SleepProvider.swift:53:53: error: 'HKSampleSortIdentifierStartDate' is only available in macOS 13.0 or newer
 4 | /// Fetches sleep stage summaries grouped into nights.
 5 | @MainActor
 6 | public final class SleepProvider {
   |                    `- note: add '@available' attribute to enclosing class
 7 |     private let store: HealthStoreProtocol
 8 |
   :
36 |
37 |     /// Fetches sleep snapshots for each detected night overlapping `range`.
38 |     public func range(_ range: ClosedRange<Date>) async throws -> [SleepSnapshot] {
   |                 `- note: add '@available' attribute to enclosing instance method
39 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
40 |         guard let sleepType = HKObjectType.categoryType(forIdentifier: .sleepAnalysis) else {
   :
51 |             predicate: predicate,
52 |             limit: HKObjectQueryNoLimit,
53 |             sortDescriptors: [NSSortDescriptor(key: HKSampleSortIdentifierStartDate, ascending: true)]
   |                                                     |- error: 'HKSampleSortIdentifierStartDate' is only available in macOS 13.0 or newer
   |                                                     `- note: add 'if #available' version check
54 |         )
55 |         let samples = raw.compactMap { $0 as? HKCategorySample }
/Users/admin/builder/spi-builder-workspace/Sources/HealthSnapKit/Providers/SleepProvider.swift:55:47: error: 'HKCategorySample' is only available in macOS 13.0 or newer
 4 | /// Fetches sleep stage summaries grouped into nights.
 5 | @MainActor
 6 | public final class SleepProvider {
   |                    `- note: add '@available' attribute to enclosing class
 7 |     private let store: HealthStoreProtocol
 8 |
   :
36 |
37 |     /// Fetches sleep snapshots for each detected night overlapping `range`.
38 |     public func range(_ range: ClosedRange<Date>) async throws -> [SleepSnapshot] {
   |                 `- note: add '@available' attribute to enclosing instance method
39 |         guard store.isHealthDataAvailable() else { throw HealthSnapError.notAvailable }
40 |         guard let sleepType = HKObjectType.categoryType(forIdentifier: .sleepAnalysis) else {
   :
53 |             sortDescriptors: [NSSortDescriptor(key: HKSampleSortIdentifierStartDate, ascending: true)]
54 |         )
55 |         let samples = raw.compactMap { $0 as? HKCategorySample }
   |                                               |- error: 'HKCategorySample' is only available in macOS 13.0 or newer
   |                                               `- note: add 'if #available' version check
56 |         if samples.isEmpty {
57 |             throw HealthSnapError.noData
BUILD FAILURE 6.3 macosSpm