The Swift Package Index logo.Swift Package Index

Has it really been five years since Swift Package Index launched? Read our anniversary blog post!

Build Information

Failed to build OpenAIKit, reference master (d95088), with Swift 6.1 for Wasm on 27 Jun 2025 12:47:04 UTC.

Build Command

bash -c docker run --pull=always --rm -v "checkouts-4609320-0":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest swift build --swift-sdk wasm32-unknown-wasi 2>&1

Build Log

========================================
RunAll
========================================
Builder version: 4.64.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/marcusziade/OpenAIKit.git
Reference: master
Initialized empty Git repository in /host/spi-builder-workspace/.git/
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: 	git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: 	git branch -m <name>
From https://github.com/marcusziade/OpenAIKit
 * branch            master     -> FETCH_HEAD
 * [new branch]      master     -> origin/master
HEAD is now at d95088d docs: Add missing code files for DeepResearch streaming tutorial section 5
Cloned https://github.com/marcusziade/OpenAIKit.git
Revision (git rev-parse @):
d95088d74f21986e9e0b722ec155a99150ce5aae
SUCCESS checkout https://github.com/marcusziade/OpenAIKit.git at master
========================================
Build
========================================
Selected platform:         wasm
Swift version:             6.1
Building package at path:  $PWD
https://github.com/marcusziade/OpenAIKit.git
https://github.com/marcusziade/OpenAIKit.git
WARNING: environment variable SUPPRESS_SWIFT_6_FLAGS is not set
{
  "dependencies" : [
    {
      "identity" : "swift-docc-plugin",
      "requirement" : {
        "range" : [
          {
            "lower_bound" : "1.0.0",
            "upper_bound" : "2.0.0"
          }
        ]
      },
      "type" : "sourceControl",
      "url" : "https://github.com/apple/swift-docc-plugin"
    }
  ],
  "manifest_display_name" : "OpenAIKit",
  "name" : "OpenAIKit",
  "path" : "/host/spi-builder-workspace",
  "platforms" : [
    {
      "name" : "ios",
      "version" : "15.0"
    },
    {
      "name" : "macos",
      "version" : "13.0"
    },
    {
      "name" : "watchos",
      "version" : "8.0"
    },
    {
      "name" : "tvos",
      "version" : "15.0"
    },
    {
      "name" : "visionos",
      "version" : "1.0"
    }
  ],
  "products" : [
    {
      "name" : "OpenAIKit",
      "targets" : [
        "OpenAIKit"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    },
    {
      "name" : "OpenAIKitTester",
      "targets" : [
        "OpenAIKitTester"
      ],
      "type" : {
        "executable" : null
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "OpenAIKitTests",
      "module_type" : "SwiftTarget",
      "name" : "OpenAIKitTests",
      "path" : "Tests/OpenAIKitTests",
      "sources" : [
        "AudioModelsTests.swift",
        "ChatModelsTests.swift",
        "ConfigurationTests.swift",
        "EmbeddingModelsTests.swift",
        "EnhancedErrorHandlingTests.swift",
        "ErrorHandlingTests.swift",
        "JSONValueTests.swift",
        "ModelConstantsTests.swift",
        "OpenAIKitTests.swift",
        "RequestSerializationTests.swift",
        "ResponseParsingTests.swift"
      ],
      "target_dependencies" : [
        "OpenAIKit"
      ],
      "type" : "test"
    },
    {
      "c99name" : "OpenAIKitTester",
      "module_type" : "SwiftTarget",
      "name" : "OpenAIKitTester",
      "path" : "Sources/OpenAIKitTester",
      "product_memberships" : [
        "OpenAIKitTester"
      ],
      "sources" : [
        "Configuration/TestConfiguration.swift",
        "OpenAIKitTester.swift",
        "TestRunner.swift",
        "Tests/AdvancedTests.swift",
        "Tests/AudioTests.swift",
        "Tests/BatchTests.swift",
        "Tests/ChatTests.swift",
        "Tests/DeepResearchTests.swift",
        "Tests/EdgeCaseTests.swift",
        "Tests/EmbeddingTests.swift",
        "Tests/FileTests.swift",
        "Tests/ImageTests.swift",
        "Tests/ModelTests.swift",
        "Tests/ModerationTests.swift",
        "Utilities/TestProtocol.swift"
      ],
      "target_dependencies" : [
        "OpenAIKit"
      ],
      "type" : "executable"
    },
    {
      "c99name" : "OpenAIKit",
      "module_type" : "SwiftTarget",
      "name" : "OpenAIKit",
      "path" : "Sources/OpenAIKit",
      "product_memberships" : [
        "OpenAIKit",
        "OpenAIKitTester"
      ],
      "sources" : [
        "Core/NetworkClient.swift",
        "Core/OpenAIError.swift",
        "Core/Request.swift",
        "Core/RetryHandler.swift",
        "Endpoints/AssistantsEndpoint.swift",
        "Endpoints/AudioEndpoint.swift",
        "Endpoints/BatchEndpoint.swift",
        "Endpoints/BatchesEndpoint.swift",
        "Endpoints/ChatEndpoint.swift",
        "Endpoints/EmbeddingsEndpoint.swift",
        "Endpoints/FilesEndpoint.swift",
        "Endpoints/FineTuningEndpoint.swift",
        "Endpoints/ImagesEndpoint.swift",
        "Endpoints/ModelsEndpoint.swift",
        "Endpoints/ModerationsEndpoint.swift",
        "Endpoints/ResponsesEndpoint.swift",
        "Endpoints/ThreadsEndpoint.swift",
        "Endpoints/VectorStoresEndpoint.swift",
        "Extensions/OpenAIError+UI.swift",
        "Models/Audio.swift",
        "Models/Batch.swift",
        "Models/Chat.swift",
        "Models/Embeddings.swift",
        "Models/Files.swift",
        "Models/Images.swift",
        "Models/ModelConstants.swift",
        "Models/Models.swift",
        "Models/Moderations.swift",
        "Models/Responses.swift",
        "OpenAIKit.swift",
        "Utilities/JSONValue.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.9"
}
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4609320-0":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest swift build --swift-sdk wasm32-unknown-wasi -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete -Xswiftc -enable-upcoming-feature -Xswiftc StrictConcurrency -Xswiftc -enable-upcoming-feature -Xswiftc DisableOutwardActorInference -Xswiftc -enable-upcoming-feature -Xswiftc GlobalActorIsolatedTypesUsability -Xswiftc -enable-upcoming-feature -Xswiftc InferSendableFromCaptures 2>&1
wasm-6.1-latest: Pulling from finestructure/spi-images
Digest: sha256:8f9255989265d824b88e7d572b1a334a0dc9b701075ede1970390db95d315c35
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest
Fetching https://github.com/apple/swift-docc-plugin
[1/2082] Fetching swift-docc-plugin
Fetched https://github.com/apple/swift-docc-plugin from cache (0.43s)
Computing version for https://github.com/apple/swift-docc-plugin
Computed https://github.com/apple/swift-docc-plugin at 1.4.4 (2.31s)
Fetching https://github.com/swiftlang/swift-docc-symbolkit
[1/3418] Fetching swift-docc-symbolkit
Fetched https://github.com/swiftlang/swift-docc-symbolkit from cache (0.45s)
Computing version for https://github.com/swiftlang/swift-docc-symbolkit
Computed https://github.com/swiftlang/swift-docc-symbolkit at 1.0.0 (1.03s)
Creating working copy for https://github.com/swiftlang/swift-docc-symbolkit
Working copy of https://github.com/swiftlang/swift-docc-symbolkit resolved at 1.0.0
Creating working copy for https://github.com/apple/swift-docc-plugin
Working copy of https://github.com/apple/swift-docc-plugin resolved at 1.4.4
[1/1] Compiling plugin Swift-DocC Preview
[2/2] Compiling plugin Swift-DocC
Building for debugging...
[2/9] Write sources
[4/9] Write swift-version-24593BA9C3E375BF.txt
[6/38] Compiling OpenAIKit Images.swift
[7/38] Compiling OpenAIKit ModelConstants.swift
[8/38] Compiling OpenAIKit Models.swift
[9/38] Compiling OpenAIKit Moderations.swift
[10/41] Compiling OpenAIKit ThreadsEndpoint.swift
[11/41] Compiling OpenAIKit VectorStoresEndpoint.swift
[12/41] Compiling OpenAIKit OpenAIError+UI.swift
[13/41] Compiling OpenAIKit Audio.swift
[14/41] Compiling OpenAIKit NetworkClient.swift
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:21:60: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 19 |         self.configuration = configuration
 20 |
 21 |         let sessionConfiguration = URLSessionConfiguration.default
    |                                                            `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:24:24: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
 24 |         self.session = URLSession(configuration: sessionConfiguration)
    |                        `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 25 |
 26 |         self.decoder = JSONDecoder()
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:34:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 32 |         let urlRequest = try await buildURLRequest(from: request)
 33 |
 34 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 35 |
 36 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:163:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
161 |         let urlRequest = try await buildUploadURLRequest(from: request)
162 |
163 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
164 |
165 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:182:26: error: cannot find 'URLRequest' in scope
180 |             .appendingPathComponent(request.path)
181 |
182 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
183 |         urlRequest.httpMethod = request.method.rawValue
184 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:208:26: error: cannot find 'URLRequest' in scope
206 |             .appendingPathComponent(request.path)
207 |
208 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
209 |         urlRequest.httpMethod = "POST"
210 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
237 |             throw OpenAIError.invalidResponse
238 |         }
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
237 |             throw OpenAIError.invalidResponse
238 |         }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
  |                  `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:240:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
238 |         }
239 |
240 |         switch httpResponse.statusCode {
    |                             `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
241 |         case 200...299:
242 |             return
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:259:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
257 |                 throw OpenAIError.apiError(apiError)
258 |             }
259 |             throw OpenAIError.clientError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
260 |         case 500...599:
261 |             // Even server errors might have API error details
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:265:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
263 |                 throw OpenAIError.apiError(apiError)
264 |             }
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:267:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
    |                                                                     `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
268 |         }
269 |     }
[15/41] Compiling OpenAIKit OpenAIError.swift
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:21:60: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 19 |         self.configuration = configuration
 20 |
 21 |         let sessionConfiguration = URLSessionConfiguration.default
    |                                                            `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:24:24: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
 24 |         self.session = URLSession(configuration: sessionConfiguration)
    |                        `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 25 |
 26 |         self.decoder = JSONDecoder()
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:34:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 32 |         let urlRequest = try await buildURLRequest(from: request)
 33 |
 34 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 35 |
 36 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:163:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
161 |         let urlRequest = try await buildUploadURLRequest(from: request)
162 |
163 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
164 |
165 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:182:26: error: cannot find 'URLRequest' in scope
180 |             .appendingPathComponent(request.path)
181 |
182 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
183 |         urlRequest.httpMethod = request.method.rawValue
184 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:208:26: error: cannot find 'URLRequest' in scope
206 |             .appendingPathComponent(request.path)
207 |
208 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
209 |         urlRequest.httpMethod = "POST"
210 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
237 |             throw OpenAIError.invalidResponse
238 |         }
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
237 |             throw OpenAIError.invalidResponse
238 |         }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
  |                  `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:240:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
238 |         }
239 |
240 |         switch httpResponse.statusCode {
    |                             `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
241 |         case 200...299:
242 |             return
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:259:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
257 |                 throw OpenAIError.apiError(apiError)
258 |             }
259 |             throw OpenAIError.clientError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
260 |         case 500...599:
261 |             // Even server errors might have API error details
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:265:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
263 |                 throw OpenAIError.apiError(apiError)
264 |             }
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:267:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
    |                                                                     `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
268 |         }
269 |     }
[16/41] Compiling OpenAIKit Request.swift
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:21:60: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 19 |         self.configuration = configuration
 20 |
 21 |         let sessionConfiguration = URLSessionConfiguration.default
    |                                                            `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:24:24: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
 24 |         self.session = URLSession(configuration: sessionConfiguration)
    |                        `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 25 |
 26 |         self.decoder = JSONDecoder()
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:34:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 32 |         let urlRequest = try await buildURLRequest(from: request)
 33 |
 34 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 35 |
 36 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:163:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
161 |         let urlRequest = try await buildUploadURLRequest(from: request)
162 |
163 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
164 |
165 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:182:26: error: cannot find 'URLRequest' in scope
180 |             .appendingPathComponent(request.path)
181 |
182 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
183 |         urlRequest.httpMethod = request.method.rawValue
184 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:208:26: error: cannot find 'URLRequest' in scope
206 |             .appendingPathComponent(request.path)
207 |
208 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
209 |         urlRequest.httpMethod = "POST"
210 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
237 |             throw OpenAIError.invalidResponse
238 |         }
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
237 |             throw OpenAIError.invalidResponse
238 |         }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
  |                  `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:240:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
238 |         }
239 |
240 |         switch httpResponse.statusCode {
    |                             `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
241 |         case 200...299:
242 |             return
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:259:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
257 |                 throw OpenAIError.apiError(apiError)
258 |             }
259 |             throw OpenAIError.clientError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
260 |         case 500...599:
261 |             // Even server errors might have API error details
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:265:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
263 |                 throw OpenAIError.apiError(apiError)
264 |             }
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:267:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
    |                                                                     `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
268 |         }
269 |     }
[17/41] Compiling OpenAIKit RetryHandler.swift
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:21:60: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 19 |         self.configuration = configuration
 20 |
 21 |         let sessionConfiguration = URLSessionConfiguration.default
    |                                                            `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:24:24: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
 24 |         self.session = URLSession(configuration: sessionConfiguration)
    |                        `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 25 |
 26 |         self.decoder = JSONDecoder()
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:34:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 32 |         let urlRequest = try await buildURLRequest(from: request)
 33 |
 34 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 35 |
 36 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:163:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
161 |         let urlRequest = try await buildUploadURLRequest(from: request)
162 |
163 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
164 |
165 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:182:26: error: cannot find 'URLRequest' in scope
180 |             .appendingPathComponent(request.path)
181 |
182 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
183 |         urlRequest.httpMethod = request.method.rawValue
184 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:208:26: error: cannot find 'URLRequest' in scope
206 |             .appendingPathComponent(request.path)
207 |
208 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
209 |         urlRequest.httpMethod = "POST"
210 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
237 |             throw OpenAIError.invalidResponse
238 |         }
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
237 |             throw OpenAIError.invalidResponse
238 |         }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
  |                  `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:240:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
238 |         }
239 |
240 |         switch httpResponse.statusCode {
    |                             `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
241 |         case 200...299:
242 |             return
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:259:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
257 |                 throw OpenAIError.apiError(apiError)
258 |             }
259 |             throw OpenAIError.clientError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
260 |         case 500...599:
261 |             // Even server errors might have API error details
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:265:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
263 |                 throw OpenAIError.apiError(apiError)
264 |             }
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:267:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
    |                                                                     `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
268 |         }
269 |     }
[18/41] Compiling OpenAIKit Batch.swift
[19/41] Compiling OpenAIKit Chat.swift
[20/41] Compiling OpenAIKit Embeddings.swift
[21/41] Compiling OpenAIKit Files.swift
[22/41] Compiling OpenAIKit ChatEndpoint.swift
[23/41] Compiling OpenAIKit EmbeddingsEndpoint.swift
[24/41] Compiling OpenAIKit FilesEndpoint.swift
[25/41] Compiling OpenAIKit FineTuningEndpoint.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)
[26/41] Emitting module OpenAIKit
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
[27/41] Compiling OpenAIKit ImagesEndpoint.swift
[28/41] Compiling OpenAIKit ModelsEndpoint.swift
[29/41] Compiling OpenAIKit ModerationsEndpoint.swift
[30/41] Compiling OpenAIKit ResponsesEndpoint.swift
[31/41] Compiling OpenAIKit AssistantsEndpoint.swift
[32/41] Compiling OpenAIKit AudioEndpoint.swift
[33/41] Compiling OpenAIKit BatchEndpoint.swift
[34/41] Compiling OpenAIKit BatchesEndpoint.swift
[35/41] Compiling OpenAIKit Responses.swift
[36/41] Compiling OpenAIKit OpenAIKit.swift
[37/41] Compiling OpenAIKit JSONValue.swift
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4609320-0":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest swift build --swift-sdk wasm32-unknown-wasi 2>&1
wasm-6.1-latest: Pulling from finestructure/spi-images
Digest: sha256:8f9255989265d824b88e7d572b1a334a0dc9b701075ede1970390db95d315c35
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest
[0/1] Planning build
[1/1] Compiling plugin Swift-DocC Preview
[2/2] Compiling plugin Swift-DocC
Building for debugging...
[2/7] Write swift-version-24593BA9C3E375BF.txt
error: emit-module command failed with exit code 1 (use -v to see invocation)
[4/36] Emitting module OpenAIKit
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
[5/39] Compiling OpenAIKit AssistantsEndpoint.swift
[6/39] Compiling OpenAIKit AudioEndpoint.swift
[7/39] Compiling OpenAIKit BatchEndpoint.swift
[8/39] Compiling OpenAIKit BatchesEndpoint.swift
[9/39] Compiling OpenAIKit ChatEndpoint.swift
[10/39] Compiling OpenAIKit EmbeddingsEndpoint.swift
[11/39] Compiling OpenAIKit FilesEndpoint.swift
[12/39] Compiling OpenAIKit FineTuningEndpoint.swift
[13/39] Compiling OpenAIKit NetworkClient.swift
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:21:60: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 19 |         self.configuration = configuration
 20 |
 21 |         let sessionConfiguration = URLSessionConfiguration.default
    |                                                            `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:24:24: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
 24 |         self.session = URLSession(configuration: sessionConfiguration)
    |                        `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 25 |
 26 |         self.decoder = JSONDecoder()
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:34:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 32 |         let urlRequest = try await buildURLRequest(from: request)
 33 |
 34 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 35 |
 36 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:163:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
161 |         let urlRequest = try await buildUploadURLRequest(from: request)
162 |
163 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
164 |
165 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:182:26: error: cannot find 'URLRequest' in scope
180 |             .appendingPathComponent(request.path)
181 |
182 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
183 |         urlRequest.httpMethod = request.method.rawValue
184 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:208:26: error: cannot find 'URLRequest' in scope
206 |             .appendingPathComponent(request.path)
207 |
208 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
209 |         urlRequest.httpMethod = "POST"
210 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
237 |             throw OpenAIError.invalidResponse
238 |         }
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
237 |             throw OpenAIError.invalidResponse
238 |         }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
  |                  `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:240:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
238 |         }
239 |
240 |         switch httpResponse.statusCode {
    |                             `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
241 |         case 200...299:
242 |             return
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:259:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
257 |                 throw OpenAIError.apiError(apiError)
258 |             }
259 |             throw OpenAIError.clientError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
260 |         case 500...599:
261 |             // Even server errors might have API error details
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:265:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
263 |                 throw OpenAIError.apiError(apiError)
264 |             }
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:267:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
    |                                                                     `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
268 |         }
269 |     }
[14/39] Compiling OpenAIKit OpenAIError.swift
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:21:60: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 19 |         self.configuration = configuration
 20 |
 21 |         let sessionConfiguration = URLSessionConfiguration.default
    |                                                            `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:24:24: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
 24 |         self.session = URLSession(configuration: sessionConfiguration)
    |                        `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 25 |
 26 |         self.decoder = JSONDecoder()
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:34:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 32 |         let urlRequest = try await buildURLRequest(from: request)
 33 |
 34 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 35 |
 36 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:163:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
161 |         let urlRequest = try await buildUploadURLRequest(from: request)
162 |
163 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
164 |
165 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:182:26: error: cannot find 'URLRequest' in scope
180 |             .appendingPathComponent(request.path)
181 |
182 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
183 |         urlRequest.httpMethod = request.method.rawValue
184 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:208:26: error: cannot find 'URLRequest' in scope
206 |             .appendingPathComponent(request.path)
207 |
208 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
209 |         urlRequest.httpMethod = "POST"
210 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
237 |             throw OpenAIError.invalidResponse
238 |         }
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
237 |             throw OpenAIError.invalidResponse
238 |         }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
  |                  `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:240:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
238 |         }
239 |
240 |         switch httpResponse.statusCode {
    |                             `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
241 |         case 200...299:
242 |             return
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:259:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
257 |                 throw OpenAIError.apiError(apiError)
258 |             }
259 |             throw OpenAIError.clientError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
260 |         case 500...599:
261 |             // Even server errors might have API error details
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:265:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
263 |                 throw OpenAIError.apiError(apiError)
264 |             }
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:267:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
    |                                                                     `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
268 |         }
269 |     }
[15/39] Compiling OpenAIKit Request.swift
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:21:60: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 19 |         self.configuration = configuration
 20 |
 21 |         let sessionConfiguration = URLSessionConfiguration.default
    |                                                            `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:24:24: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
 24 |         self.session = URLSession(configuration: sessionConfiguration)
    |                        `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 25 |
 26 |         self.decoder = JSONDecoder()
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:34:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 32 |         let urlRequest = try await buildURLRequest(from: request)
 33 |
 34 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 35 |
 36 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:163:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
161 |         let urlRequest = try await buildUploadURLRequest(from: request)
162 |
163 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
164 |
165 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:182:26: error: cannot find 'URLRequest' in scope
180 |             .appendingPathComponent(request.path)
181 |
182 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
183 |         urlRequest.httpMethod = request.method.rawValue
184 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:208:26: error: cannot find 'URLRequest' in scope
206 |             .appendingPathComponent(request.path)
207 |
208 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
209 |         urlRequest.httpMethod = "POST"
210 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
237 |             throw OpenAIError.invalidResponse
238 |         }
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
237 |             throw OpenAIError.invalidResponse
238 |         }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
  |                  `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:240:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
238 |         }
239 |
240 |         switch httpResponse.statusCode {
    |                             `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
241 |         case 200...299:
242 |             return
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:259:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
257 |                 throw OpenAIError.apiError(apiError)
258 |             }
259 |             throw OpenAIError.clientError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
260 |         case 500...599:
261 |             // Even server errors might have API error details
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:265:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
263 |                 throw OpenAIError.apiError(apiError)
264 |             }
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:267:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
    |                                                                     `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
268 |         }
269 |     }
[16/39] Compiling OpenAIKit RetryHandler.swift
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:14:26: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 12 | public final class NetworkClient: NetworkClientProtocol, @unchecked Sendable {
 13 |
 14 |     private let session: URLSession
    |                          `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 15 |     private let configuration: Configuration
 16 |     private let decoder: JSONDecoder
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:177:77: error: cannot find type 'URLRequest' in scope
175 |     }
176 |
177 |     private func buildURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                             `- error: cannot find type 'URLRequest' in scope
178 |         let url = configuration.baseURL
179 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:197:86: error: cannot find type 'URLRequest' in scope
195 |     }
196 |
197 |     private func buildStreamingURLRequest(from request: any Request) async throws -> URLRequest {
    |                                                                                      `- error: cannot find type 'URLRequest' in scope
198 |         var urlRequest = try await buildURLRequest(from: request)
199 |         urlRequest.setValue("text/event-stream", forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:203:89: error: cannot find type 'URLRequest' in scope
201 |     }
202 |
203 |     private func buildUploadURLRequest(from request: any UploadRequest) async throws -> URLRequest {
    |                                                                                         `- error: cannot find type 'URLRequest' in scope
204 |         let url = configuration.baseURL
205 |             .appendingPathComponent("v1")
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:221:52: error: cannot find type 'URLRequest' in scope
219 |     }
220 |
221 |     private func configureHeaders(_ request: inout URLRequest) {
    |                                                    `- error: cannot find type 'URLRequest' in scope
222 |         request.setValue("Bearer \(configuration.apiKey)", forHTTPHeaderField: "Authorization")
223 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:235:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
233 |     }
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
236 |         guard let httpResponse = response as? HTTPURLResponse else {
237 |             throw OpenAIError.invalidResponse
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
  |                  `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:21:60: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 19 |         self.configuration = configuration
 20 |
 21 |         let sessionConfiguration = URLSessionConfiguration.default
    |                                                            `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:24:24: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 22 |         sessionConfiguration.timeoutIntervalForRequest = configuration.timeoutInterval
 23 |         sessionConfiguration.timeoutIntervalForResource = configuration.timeoutInterval * 2
 24 |         self.session = URLSession(configuration: sessionConfiguration)
    |                        `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 25 |
 26 |         self.decoder = JSONDecoder()
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:34:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 32 |         let urlRequest = try await buildURLRequest(from: request)
 33 |
 34 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
 35 |
 36 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:163:50: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
161 |         let urlRequest = try await buildUploadURLRequest(from: request)
162 |
163 |         let (data, response) = try await session.data(for: urlRequest)
    |                                                  `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
164 |
165 |         try validateResponse(response, data: data)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:182:26: error: cannot find 'URLRequest' in scope
180 |             .appendingPathComponent(request.path)
181 |
182 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
183 |         urlRequest.httpMethod = request.method.rawValue
184 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:208:26: error: cannot find 'URLRequest' in scope
206 |             .appendingPathComponent(request.path)
207 |
208 |         var urlRequest = URLRequest(url: url)
    |                          `- error: cannot find 'URLRequest' in scope
209 |         urlRequest.httpMethod = "POST"
210 |
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
237 |             throw OpenAIError.invalidResponse
238 |         }
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:236:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
234 |
235 |     private func validateResponse(_ response: URLResponse, data: Data?) throws {
236 |         guard let httpResponse = response as? HTTPURLResponse else {
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
237 |             throw OpenAIError.invalidResponse
238 |         }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
  |                  `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:240:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
238 |         }
239 |
240 |         switch httpResponse.statusCode {
    |                             `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
241 |         case 200...299:
242 |             return
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:259:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
257 |                 throw OpenAIError.apiError(apiError)
258 |             }
259 |             throw OpenAIError.clientError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
260 |         case 500...599:
261 |             // Even server errors might have API error details
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:265:68: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
263 |                 throw OpenAIError.apiError(apiError)
264 |             }
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
    |                                                                    `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
/host/spi-builder-workspace/Sources/OpenAIKit/Core/NetworkClient.swift:267:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
265 |             throw OpenAIError.serverError(statusCode: httpResponse.statusCode)
266 |         default:
267 |             throw OpenAIError.unknownError(statusCode: httpResponse.statusCode)
    |                                                                     `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
268 |         }
269 |     }
[17/39] Compiling OpenAIKit ThreadsEndpoint.swift
[18/39] Compiling OpenAIKit VectorStoresEndpoint.swift
[19/39] Compiling OpenAIKit OpenAIError+UI.swift
[20/39] Compiling OpenAIKit Audio.swift
[21/39] Compiling OpenAIKit Responses.swift
[22/39] Compiling OpenAIKit OpenAIKit.swift
[23/39] Compiling OpenAIKit JSONValue.swift
[24/39] Compiling OpenAIKit Images.swift
[25/39] Compiling OpenAIKit ModelConstants.swift
[26/39] Compiling OpenAIKit Models.swift
[27/39] Compiling OpenAIKit Moderations.swift
[28/39] Compiling OpenAIKit ImagesEndpoint.swift
[29/39] Compiling OpenAIKit ModelsEndpoint.swift
[30/39] Compiling OpenAIKit ModerationsEndpoint.swift
[31/39] Compiling OpenAIKit ResponsesEndpoint.swift
[32/39] Compiling OpenAIKit Batch.swift
[33/39] Compiling OpenAIKit Chat.swift
[34/39] Compiling OpenAIKit Embeddings.swift
[35/39] Compiling OpenAIKit Files.swift
BUILD FAILURE 6.1 wasm