Build Information
Failed to build klaviyo-swift-sdk, reference 4.0.0 (896e2d
), with Swift 6.0 for macOS (SPM) on 4 Nov 2024 19:42:49 UTC.
Build Command
env DEVELOPER_DIR=/Applications/Xcode-16.1.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Build Log
========================================
RunAll
========================================
Builder version: 4.56.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/klaviyo/klaviyo-swift-sdk.git
Reference: 4.0.0
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/klaviyo/klaviyo-swift-sdk
* tag 4.0.0 -> FETCH_HEAD
HEAD is now at 896e2d3 Merge pull request #205 from klaviyo/as/rel-400
Cloned https://github.com/klaviyo/klaviyo-swift-sdk.git
Revision (git rev-parse @):
896e2d3af949dcfa14fea2e3c533f124ca4859d3
SUCCESS checkout https://github.com/klaviyo/klaviyo-swift-sdk.git at 4.0.0
Fetching https://github.com/pointfreeco/xctest-dynamic-overlay
Fetching https://github.com/pointfreeco/combine-schedulers
Fetching https://github.com/Flight-School/AnyCodable
Fetching https://github.com/pointfreeco/swift-custom-dump
Fetching https://github.com/pointfreeco/swift-case-paths
Fetching https://github.com/pointfreeco/swift-snapshot-testing
[1/4174] Fetching swift-case-paths
[43/16620] Fetching swift-case-paths, swift-snapshot-testing
[210/17402] Fetching swift-case-paths, swift-snapshot-testing, anycodable
[211/21913] Fetching swift-case-paths, swift-snapshot-testing, anycodable, swift-custom-dump
[389/24260] Fetching swift-case-paths, swift-snapshot-testing, anycodable, swift-custom-dump, combine-schedulers
[3692/29245] Fetching swift-case-paths, swift-snapshot-testing, anycodable, swift-custom-dump, combine-schedulers, xctest-dynamic-overlay
Fetched https://github.com/pointfreeco/swift-custom-dump from cache (1.05s)
[8575/24734] Fetching swift-case-paths, swift-snapshot-testing, anycodable, combine-schedulers, xctest-dynamic-overlay
Fetched https://github.com/pointfreeco/swift-snapshot-testing from cache (2.99s)
Fetched https://github.com/Flight-School/AnyCodable from cache (2.99s)
Fetched https://github.com/pointfreeco/swift-case-paths from cache (2.99s)
Fetched https://github.com/pointfreeco/xctest-dynamic-overlay from cache (2.99s)
Fetched https://github.com/pointfreeco/combine-schedulers from cache (2.99s)
Computing version for https://github.com/pointfreeco/combine-schedulers
Computed https://github.com/pointfreeco/combine-schedulers at 0.9.1 (0.66s)
Computing version for https://github.com/pointfreeco/swift-case-paths
Computed https://github.com/pointfreeco/swift-case-paths at 0.10.1 (0.66s)
Computing version for https://github.com/pointfreeco/swift-custom-dump
Computed https://github.com/pointfreeco/swift-custom-dump at 0.6.1 (0.63s)
Computing version for https://github.com/Flight-School/AnyCodable
Computed https://github.com/Flight-School/AnyCodable at 0.6.7 (0.65s)
Computing version for https://github.com/pointfreeco/swift-snapshot-testing
Computed https://github.com/pointfreeco/swift-snapshot-testing at 1.10.0 (0.69s)
Computing version for https://github.com/pointfreeco/xctest-dynamic-overlay
Computed https://github.com/pointfreeco/xctest-dynamic-overlay at 0.6.0 (0.64s)
Creating working copy for https://github.com/pointfreeco/swift-snapshot-testing
Working copy of https://github.com/pointfreeco/swift-snapshot-testing resolved at 1.10.0
Creating working copy for https://github.com/pointfreeco/combine-schedulers
Working copy of https://github.com/pointfreeco/combine-schedulers resolved at 0.9.1
Creating working copy for https://github.com/Flight-School/AnyCodable
Working copy of https://github.com/Flight-School/AnyCodable resolved at 0.6.7
Creating working copy for https://github.com/pointfreeco/swift-case-paths
Working copy of https://github.com/pointfreeco/swift-case-paths resolved at 0.10.1
Creating working copy for https://github.com/pointfreeco/xctest-dynamic-overlay
Working copy of https://github.com/pointfreeco/xctest-dynamic-overlay resolved at 0.6.0
Creating working copy for https://github.com/pointfreeco/swift-custom-dump
Working copy of https://github.com/pointfreeco/swift-custom-dump resolved at 0.6.1
========================================
ResolveProductDependencies
========================================
Resolving dependencies ...
{
"identity": ".resolve-product-dependencies",
"name": "resolve-dependencies",
"url": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies",
"version": "unspecified",
"path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies",
"dependencies": [
{
"identity": "klaviyo-swift-sdk",
"name": "klaviyo-swift-sdk",
"url": "https://github.com/klaviyo/klaviyo-swift-sdk.git",
"version": "unspecified",
"path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/klaviyo-swift-sdk",
"dependencies": [
{
"identity": "anycodable",
"name": "AnyCodable",
"url": "https://github.com/Flight-School/AnyCodable",
"version": "0.6.7",
"path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/AnyCodable",
"dependencies": [
]
}
]
}
]
}
Fetching https://github.com/klaviyo/klaviyo-swift-sdk.git
[1/7883] Fetching klaviyo-swift-sdk
Fetched https://github.com/klaviyo/klaviyo-swift-sdk.git from cache (2.89s)
Fetching https://github.com/Flight-School/AnyCodable from cache
Fetched https://github.com/Flight-School/AnyCodable from cache (0.53s)
Computing version for https://github.com/Flight-School/AnyCodable
Computed https://github.com/Flight-School/AnyCodable at 0.6.7 (0.02s)
Creating working copy for https://github.com/Flight-School/AnyCodable
Working copy of https://github.com/Flight-School/AnyCodable resolved at 0.6.7
Creating working copy for https://github.com/klaviyo/klaviyo-swift-sdk.git
Working copy of https://github.com/klaviyo/klaviyo-swift-sdk.git resolved at 4.0.0 (896e2d3)
warning: '.resolve-product-dependencies': dependency 'klaviyo-swift-sdk' is not used by any target
Found 1 product dependencies
- AnyCodable
========================================
Build
========================================
Selected platform: macosSpm
Swift version: 6.0
Building package at path: $PWD
https://github.com/klaviyo/klaviyo-swift-sdk.git
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-16.1.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Building for debugging...
[0/6] Write sources
[3/6] Copying PrivacyInfo.xcprivacy
[5/6] Write swift-version--7754E27361AE5C74.txt
[7/12] Compiling AnyCodable AnyDecodable.swift
[8/12] Compiling AnyCodable AnyEncodable.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)
[9/12] Emitting module AnyCodable
[10/12] Compiling AnyCodable AnyCodable.swift
[11/12] Emitting module KlaviyoSwiftExtension
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:23:18: error: 'UNNotificationRequest' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
20 | /// - bestAttemptContent: this is also received in `didReceive(_:withContentHandler:)` and is the best attempt at mutating the APNS payload before attaching it to the push notification
21 | /// - contentHandler: this is also received in `didReceive(_:withContentHandler:)` and is the closure that needs to be called before the time iOS provides for us to mutate the content. This closure will be called with the `bestAttemptContent` once the image is downloaded and attached.
22 | public static func handleNotificationServiceDidReceivedRequest(
| `- note: add @available attribute to enclosing static method
23 | request: UNNotificationRequest,
| `- error: 'UNNotificationRequest' is only available in macOS 10.14 or newer
24 | bestAttemptContent: UNMutableNotificationContent,
25 | contentHandler: @escaping (UNNotificationContent) -> Void,
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:24:29: error: 'UNMutableNotificationContent' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
20 | /// - bestAttemptContent: this is also received in `didReceive(_:withContentHandler:)` and is the best attempt at mutating the APNS payload before attaching it to the push notification
21 | /// - contentHandler: this is also received in `didReceive(_:withContentHandler:)` and is the closure that needs to be called before the time iOS provides for us to mutate the content. This closure will be called with the `bestAttemptContent` once the image is downloaded and attached.
22 | public static func handleNotificationServiceDidReceivedRequest(
| `- note: add @available attribute to enclosing static method
23 | request: UNNotificationRequest,
24 | bestAttemptContent: UNMutableNotificationContent,
| `- error: 'UNMutableNotificationContent' is only available in macOS 10.14 or newer
25 | contentHandler: @escaping (UNNotificationContent) -> Void,
26 | fallbackMediaType: String = "jpeg") {
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:25:36: error: 'UNNotificationContent' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
20 | /// - bestAttemptContent: this is also received in `didReceive(_:withContentHandler:)` and is the best attempt at mutating the APNS payload before attaching it to the push notification
21 | /// - contentHandler: this is also received in `didReceive(_:withContentHandler:)` and is the closure that needs to be called before the time iOS provides for us to mutate the content. This closure will be called with the `bestAttemptContent` once the image is downloaded and attached.
22 | public static func handleNotificationServiceDidReceivedRequest(
| `- note: add @available attribute to enclosing static method
23 | request: UNNotificationRequest,
24 | bestAttemptContent: UNMutableNotificationContent,
25 | contentHandler: @escaping (UNNotificationContent) -> Void,
| `- error: 'UNNotificationContent' is only available in macOS 10.14 or newer
26 | fallbackMediaType: String = "jpeg") {
27 | // 1a. get the rich media url from the push notification payload
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:63:18: error: 'UNNotificationRequest' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
60 | }
61 |
62 | public static func handleNotificationServiceExtensionTimeWillExpireRequest(
| `- note: add @available attribute to enclosing static method
63 | request: UNNotificationRequest,
| `- error: 'UNNotificationRequest' is only available in macOS 10.14 or newer
64 | bestAttemptContent: UNMutableNotificationContent,
65 | contentHandler: @escaping (UNNotificationContent) -> Void) {
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:64:29: error: 'UNMutableNotificationContent' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
60 | }
61 |
62 | public static func handleNotificationServiceExtensionTimeWillExpireRequest(
| `- note: add @available attribute to enclosing static method
63 | request: UNNotificationRequest,
64 | bestAttemptContent: UNMutableNotificationContent,
| `- error: 'UNMutableNotificationContent' is only available in macOS 10.14 or newer
65 | contentHandler: @escaping (UNNotificationContent) -> Void) {
66 | contentHandler(bestAttemptContent)
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:65:36: error: 'UNNotificationContent' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
60 | }
61 |
62 | public static func handleNotificationServiceExtensionTimeWillExpireRequest(
| `- note: add @available attribute to enclosing static method
63 | request: UNNotificationRequest,
64 | bestAttemptContent: UNMutableNotificationContent,
65 | contentHandler: @escaping (UNNotificationContent) -> Void) {
| `- error: 'UNNotificationContent' is only available in macOS 10.14 or newer
66 | contentHandler(bestAttemptContent)
67 | }
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:107:32: error: 'UNNotificationAttachment' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
102 | /// - completion: closure that will be called once the file has been moved and an attachment has been created.
103 | /// Note that in the case of failure during file transfer or creating an attachment this closure will be called with `nil` indicating a failure.
104 | private static func createAttachment(
| `- note: add @available attribute to enclosing static method
105 | localFileURL: URL,
106 | localFilePathWithTypeString: String,
107 | completion: @escaping (UNNotificationAttachment?) -> Void) {
| `- error: 'UNNotificationAttachment' is only available in macOS 10.14 or newer
108 | let localFileURLWithType: URL
109 | if #available(iOS 16.0, *) {
[12/12] Compiling KlaviyoSwiftExtension KlaviyoExtension.swift
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:23:18: error: 'UNNotificationRequest' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
20 | /// - bestAttemptContent: this is also received in `didReceive(_:withContentHandler:)` and is the best attempt at mutating the APNS payload before attaching it to the push notification
21 | /// - contentHandler: this is also received in `didReceive(_:withContentHandler:)` and is the closure that needs to be called before the time iOS provides for us to mutate the content. This closure will be called with the `bestAttemptContent` once the image is downloaded and attached.
22 | public static func handleNotificationServiceDidReceivedRequest(
| `- note: add @available attribute to enclosing static method
23 | request: UNNotificationRequest,
| `- error: 'UNNotificationRequest' is only available in macOS 10.14 or newer
24 | bestAttemptContent: UNMutableNotificationContent,
25 | contentHandler: @escaping (UNNotificationContent) -> Void,
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:24:29: error: 'UNMutableNotificationContent' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
20 | /// - bestAttemptContent: this is also received in `didReceive(_:withContentHandler:)` and is the best attempt at mutating the APNS payload before attaching it to the push notification
21 | /// - contentHandler: this is also received in `didReceive(_:withContentHandler:)` and is the closure that needs to be called before the time iOS provides for us to mutate the content. This closure will be called with the `bestAttemptContent` once the image is downloaded and attached.
22 | public static func handleNotificationServiceDidReceivedRequest(
| `- note: add @available attribute to enclosing static method
23 | request: UNNotificationRequest,
24 | bestAttemptContent: UNMutableNotificationContent,
| `- error: 'UNMutableNotificationContent' is only available in macOS 10.14 or newer
25 | contentHandler: @escaping (UNNotificationContent) -> Void,
26 | fallbackMediaType: String = "jpeg") {
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:25:36: error: 'UNNotificationContent' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
20 | /// - bestAttemptContent: this is also received in `didReceive(_:withContentHandler:)` and is the best attempt at mutating the APNS payload before attaching it to the push notification
21 | /// - contentHandler: this is also received in `didReceive(_:withContentHandler:)` and is the closure that needs to be called before the time iOS provides for us to mutate the content. This closure will be called with the `bestAttemptContent` once the image is downloaded and attached.
22 | public static func handleNotificationServiceDidReceivedRequest(
| `- note: add @available attribute to enclosing static method
23 | request: UNNotificationRequest,
24 | bestAttemptContent: UNMutableNotificationContent,
25 | contentHandler: @escaping (UNNotificationContent) -> Void,
| `- error: 'UNNotificationContent' is only available in macOS 10.14 or newer
26 | fallbackMediaType: String = "jpeg") {
27 | // 1a. get the rich media url from the push notification payload
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:63:18: error: 'UNNotificationRequest' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
60 | }
61 |
62 | public static func handleNotificationServiceExtensionTimeWillExpireRequest(
| `- note: add @available attribute to enclosing static method
63 | request: UNNotificationRequest,
| `- error: 'UNNotificationRequest' is only available in macOS 10.14 or newer
64 | bestAttemptContent: UNMutableNotificationContent,
65 | contentHandler: @escaping (UNNotificationContent) -> Void) {
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:64:29: error: 'UNMutableNotificationContent' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
60 | }
61 |
62 | public static func handleNotificationServiceExtensionTimeWillExpireRequest(
| `- note: add @available attribute to enclosing static method
63 | request: UNNotificationRequest,
64 | bestAttemptContent: UNMutableNotificationContent,
| `- error: 'UNMutableNotificationContent' is only available in macOS 10.14 or newer
65 | contentHandler: @escaping (UNNotificationContent) -> Void) {
66 | contentHandler(bestAttemptContent)
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:65:36: error: 'UNNotificationContent' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
60 | }
61 |
62 | public static func handleNotificationServiceExtensionTimeWillExpireRequest(
| `- note: add @available attribute to enclosing static method
63 | request: UNNotificationRequest,
64 | bestAttemptContent: UNMutableNotificationContent,
65 | contentHandler: @escaping (UNNotificationContent) -> Void) {
| `- error: 'UNNotificationContent' is only available in macOS 10.14 or newer
66 | contentHandler(bestAttemptContent)
67 | }
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:107:32: error: 'UNNotificationAttachment' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
102 | /// - completion: closure that will be called once the file has been moved and an attachment has been created.
103 | /// Note that in the case of failure during file transfer or creating an attachment this closure will be called with `nil` indicating a failure.
104 | private static func createAttachment(
| `- note: add @available attribute to enclosing static method
105 | localFileURL: URL,
106 | localFilePathWithTypeString: String,
107 | completion: @escaping (UNNotificationAttachment?) -> Void) {
| `- error: 'UNNotificationAttachment' is only available in macOS 10.14 or newer
108 | let localFileURLWithType: URL
109 | if #available(iOS 16.0, *) {
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:85:17: warning: capture of 'completion' with non-sendable type '(URL?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
83 | if let error = error {
84 | print("error when downloading push media = \(error.localizedDescription)")
85 | completion(nil)
| |- warning: capture of 'completion' with non-sendable type '(URL?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
86 | return
87 | }
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:110:36: error: 'init(filePath:directoryHint:relativeTo:)' is only available in macOS 13.0 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
102 | /// - completion: closure that will be called once the file has been moved and an attachment has been created.
103 | /// Note that in the case of failure during file transfer or creating an attachment this closure will be called with `nil` indicating a failure.
104 | private static func createAttachment(
| `- note: add @available attribute to enclosing static method
105 | localFileURL: URL,
106 | localFilePathWithTypeString: String,
:
108 | let localFileURLWithType: URL
109 | if #available(iOS 16.0, *) {
110 | localFileURLWithType = URL(filePath: localFilePathWithTypeString)
| |- error: 'init(filePath:directoryHint:relativeTo:)' is only available in macOS 13.0 or newer
| `- note: add 'if #available' version check
111 | } else {
112 | localFileURLWithType = URL(fileURLWithPath: localFilePathWithTypeString)
/Users/admin/builder/spi-builder-workspace/Sources/KlaviyoSwiftExtension/KlaviyoExtension.swift:122:37: error: 'UNNotificationAttachment' is only available in macOS 10.14 or newer
8 | import UserNotifications
9 |
10 | public enum KlaviyoExtensionSDK {
| `- note: add @available attribute to enclosing enum
11 | /// Call this method when you receive a rich push notification in the notification service extension.
12 | /// This method should be called from within `didReceive(_:withContentHandler:)` method of `UNNotificationServiceExtension`.
:
102 | /// - completion: closure that will be called once the file has been moved and an attachment has been created.
103 | /// Note that in the case of failure during file transfer or creating an attachment this closure will be called with `nil` indicating a failure.
104 | private static func createAttachment(
| `- note: add @available attribute to enclosing static method
105 | localFileURL: URL,
106 | localFilePathWithTypeString: String,
:
120 | }
121 |
122 | guard let attachment = try? UNNotificationAttachment(
| |- error: 'UNNotificationAttachment' is only available in macOS 10.14 or newer
| `- note: add 'if #available' version check
123 | identifier: "",
124 | url: localFileURLWithType,
BUILD FAILURE 6.0 macosSpm