Build Information
Failed to build OpenAIImages, reference main (c80dfb
), with Swift 6.1 for Android on 30 May 2025 21:57:27 UTC.
Build Command
bash -c docker run --pull=always --rm -v "checkouts-4606859-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:android-6.1-latest swift build --swift-sdk aarch64-unknown-linux-android24 2>&1
Build Log
========================================
RunAll
========================================
Builder version: 4.63.1
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/m1guelpf/swift-openai-images.git
Reference: main
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/m1guelpf/swift-openai-images
* branch main -> FETCH_HEAD
* [new branch] main -> origin/main
HEAD is now at c80dfb5 init
Cloned https://github.com/m1guelpf/swift-openai-images.git
Revision (git rev-parse @):
c80dfb5360424b4ff9aa53c6ee4d1741bcd1d088
SPI manifest file found: $PWD/.spi.yml
SUCCESS checkout https://github.com/m1guelpf/swift-openai-images.git at main
========================================
Build
========================================
Selected platform: android
Swift version: 6.1
Building package at path: $PWD
https://github.com/m1guelpf/swift-openai-images.git
https://github.com/m1guelpf/swift-openai-images.git
WARNING: environment variable SUPPRESS_SWIFT_6_FLAGS is not set
{
"dependencies" : [
],
"manifest_display_name" : "OpenAIImages",
"name" : "OpenAIImages",
"path" : "/host/spi-builder-workspace",
"platforms" : [
{
"name" : "ios",
"version" : "17.0"
},
{
"name" : "tvos",
"version" : "17.0"
},
{
"name" : "macos",
"version" : "14.0"
},
{
"name" : "watchos",
"version" : "10.0"
},
{
"name" : "visionos",
"version" : "1.0"
},
{
"name" : "maccatalyst",
"version" : "17.0"
}
],
"products" : [
{
"name" : "OpenAIImages",
"targets" : [
"OpenAIImages"
],
"type" : {
"library" : [
"static"
]
}
}
],
"targets" : [
{
"c99name" : "OpenAIImages",
"module_type" : "SwiftTarget",
"name" : "OpenAIImages",
"path" : "src",
"product_memberships" : [
"OpenAIImages"
],
"sources" : [
"ImagesAPI.swift",
"Models/CreateImageRequest.swift",
"Models/EditImageRequest.swift",
"Models/ErrorResponse.swift",
"Models/ImageGenerationResponse.swift",
"Models/ImageModel.swift",
"Models/ImageQuality.swift",
"Models/ImageSize.swift",
"Support/FormData.swift"
],
"type" : "library"
}
],
"tools_version" : "6.0"
}
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4606859-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:android-6.1-latest swift build --swift-sdk aarch64-unknown-linux-android24 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats 2>&1
android-6.1-latest: Pulling from finestructure/spi-images
Digest: sha256:fe1962677657b2408c217cb5cceb3c09bc1d91486e360cebbc6eee461a5945d8
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:android-6.1-latest
Building for debugging...
[0/5] Write sources
[1/5] Write swift-version-24593BA9C3E375BF.txt
[3/14] Compiling OpenAIImages ErrorResponse.swift
[4/15] Compiling OpenAIImages ImageQuality.swift
[5/15] Compiling OpenAIImages ImageSize.swift
[6/15] Compiling OpenAIImages ImageModel.swift
[7/15] Compiling OpenAIImages EditImageRequest.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)
[8/15] Compiling OpenAIImages ImagesAPI.swift
/host/spi-builder-workspace/src/ImagesAPI.swift:7:23: error: cannot find type 'URLRequest' in scope
5 | public enum Error: Swift.Error {
6 | /// The provided request is invalid.
7 | case invalidRequest(URLRequest)
| `- error: cannot find type 'URLRequest' in scope
8 |
9 | /// The response was not a 200 or 400 status
/host/spi-builder-workspace/src/ImagesAPI.swift:10:24: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | }
12 |
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/src/ImagesAPI.swift:10:8: error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
11 | }
12 |
/host/spi-builder-workspace/src/ImagesAPI.swift:13:23: error: cannot find type 'URLRequest' in scope
11 | }
12 |
13 | private let request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
14 |
15 | private let encoder = {
/host/spi-builder-workspace/src/ImagesAPI.swift:32:36: error: cannot find type 'URLRequest' in scope
30 | ///
31 | /// - Parameter request: The `URLRequest` to use for the API.
32 | public init(connectingTo request: URLRequest) throws {
| `- error: cannot find type 'URLRequest' in scope
33 | guard let url = request.url else { throw Error.invalidRequest(request) }
34 |
/host/spi-builder-workspace/src/ImagesAPI.swift:187:21: error: cannot find type 'URLRequest' in scope
185 | ///
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
| `- error: cannot find type 'URLRequest' in scope
188 | let (data, res) = try await URLSession.shared.data(for: request)
189 |
/host/spi-builder-workspace/src/ImagesAPI.swift:51:17: error: cannot find 'URLRequest' in scope
49 | /// - Parameter projectId: The project associated with the request.
50 | public convenience init(authToken: String, organizationId: String? = nil, projectId: String? = nil) {
51 | var request = URLRequest(url: URL(string: "https://api.openai.com/")!)
| `- error: cannot find 'URLRequest' in scope
52 |
53 | request.addValue("Bearer \(authToken)", forHTTPHeaderField: "Authorization")
/host/spi-builder-workspace/src/ImagesAPI.swift:57:32: error: extra argument 'connectingTo' in call
55 | if let organizationId { request.addValue(organizationId, forHTTPHeaderField: "OpenAI-Organization") }
56 |
57 | try! self.init(connectingTo: request)
| `- error: extra argument 'connectingTo' in call
58 | }
59 |
/host/spi-builder-workspace/src/ImagesAPI.swift:57:18: error: missing argument for parameter 'authToken' in call
48 | /// - Parameter organizationId: The [organization](https://platform.openai.com/docs/guides/production-best-practices#setting-up-your-organization) associated with the request.
49 | /// - Parameter projectId: The project associated with the request.
50 | public convenience init(authToken: String, organizationId: String? = nil, projectId: String? = nil) {
| `- note: 'init(authToken:organizationId:projectId:)' declared here
51 | var request = URLRequest(url: URL(string: "https://api.openai.com/")!)
52 |
:
55 | if let organizationId { request.addValue(organizationId, forHTTPHeaderField: "OpenAI-Organization") }
56 |
57 | try! self.init(connectingTo: request)
| `- error: missing argument for parameter 'authToken' in call
58 | }
59 |
/host/spi-builder-workspace/src/ImagesAPI.swift:188:42: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
188 | let (data, res) = try await URLSession.shared.data(for: request)
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
189 |
190 | guard let res = res as? HTTPURLResponse else { throw Error.invalidResponse(res) }
[9/15] Compiling OpenAIImages CreateImageRequest.swift
/host/spi-builder-workspace/src/ImagesAPI.swift:7:23: error: cannot find type 'URLRequest' in scope
5 | public enum Error: Swift.Error {
6 | /// The provided request is invalid.
7 | case invalidRequest(URLRequest)
| `- error: cannot find type 'URLRequest' in scope
8 |
9 | /// The response was not a 200 or 400 status
/host/spi-builder-workspace/src/ImagesAPI.swift:10:24: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | }
12 |
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/src/ImagesAPI.swift:10:8: error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
11 | }
12 |
/host/spi-builder-workspace/src/ImagesAPI.swift:13:23: error: cannot find type 'URLRequest' in scope
11 | }
12 |
13 | private let request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
14 |
15 | private let encoder = {
/host/spi-builder-workspace/src/ImagesAPI.swift:32:36: error: cannot find type 'URLRequest' in scope
30 | ///
31 | /// - Parameter request: The `URLRequest` to use for the API.
32 | public init(connectingTo request: URLRequest) throws {
| `- error: cannot find type 'URLRequest' in scope
33 | guard let url = request.url else { throw Error.invalidRequest(request) }
34 |
/host/spi-builder-workspace/src/ImagesAPI.swift:187:21: error: cannot find type 'URLRequest' in scope
185 | ///
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
| `- error: cannot find type 'URLRequest' in scope
188 | let (data, res) = try await URLSession.shared.data(for: request)
189 |
/host/spi-builder-workspace/src/ImagesAPI.swift:51:17: error: cannot find 'URLRequest' in scope
49 | /// - Parameter projectId: The project associated with the request.
50 | public convenience init(authToken: String, organizationId: String? = nil, projectId: String? = nil) {
51 | var request = URLRequest(url: URL(string: "https://api.openai.com/")!)
| `- error: cannot find 'URLRequest' in scope
52 |
53 | request.addValue("Bearer \(authToken)", forHTTPHeaderField: "Authorization")
/host/spi-builder-workspace/src/ImagesAPI.swift:57:32: error: extra argument 'connectingTo' in call
55 | if let organizationId { request.addValue(organizationId, forHTTPHeaderField: "OpenAI-Organization") }
56 |
57 | try! self.init(connectingTo: request)
| `- error: extra argument 'connectingTo' in call
58 | }
59 |
/host/spi-builder-workspace/src/ImagesAPI.swift:57:18: error: missing argument for parameter 'authToken' in call
48 | /// - Parameter organizationId: The [organization](https://platform.openai.com/docs/guides/production-best-practices#setting-up-your-organization) associated with the request.
49 | /// - Parameter projectId: The project associated with the request.
50 | public convenience init(authToken: String, organizationId: String? = nil, projectId: String? = nil) {
| `- note: 'init(authToken:organizationId:projectId:)' declared here
51 | var request = URLRequest(url: URL(string: "https://api.openai.com/")!)
52 |
:
55 | if let organizationId { request.addValue(organizationId, forHTTPHeaderField: "OpenAI-Organization") }
56 |
57 | try! self.init(connectingTo: request)
| `- error: missing argument for parameter 'authToken' in call
58 | }
59 |
/host/spi-builder-workspace/src/ImagesAPI.swift:188:42: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
188 | let (data, res) = try await URLSession.shared.data(for: request)
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
189 |
190 | guard let res = res as? HTTPURLResponse else { throw Error.invalidResponse(res) }
[10/15] Emitting module OpenAIImages
/host/spi-builder-workspace/src/ImagesAPI.swift:7:23: error: cannot find type 'URLRequest' in scope
5 | public enum Error: Swift.Error {
6 | /// The provided request is invalid.
7 | case invalidRequest(URLRequest)
| `- error: cannot find type 'URLRequest' in scope
8 |
9 | /// The response was not a 200 or 400 status
/host/spi-builder-workspace/src/ImagesAPI.swift:10:24: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | }
12 |
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/src/ImagesAPI.swift:10:8: error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
11 | }
12 |
/host/spi-builder-workspace/src/ImagesAPI.swift:13:23: error: cannot find type 'URLRequest' in scope
11 | }
12 |
13 | private let request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
14 |
15 | private let encoder = {
/host/spi-builder-workspace/src/ImagesAPI.swift:32:36: error: cannot find type 'URLRequest' in scope
30 | ///
31 | /// - Parameter request: The `URLRequest` to use for the API.
32 | public init(connectingTo request: URLRequest) throws {
| `- error: cannot find type 'URLRequest' in scope
33 | guard let url = request.url else { throw Error.invalidRequest(request) }
34 |
/host/spi-builder-workspace/src/ImagesAPI.swift:187:21: error: cannot find type 'URLRequest' in scope
185 | ///
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
| `- error: cannot find type 'URLRequest' in scope
188 | let (data, res) = try await URLSession.shared.data(for: request)
189 |
/host/spi-builder-workspace/src/Support/FormData.swift:62:11: error: cannot find type 'URLRequest' in scope
60 | }
61 |
62 | extension URLRequest {
| `- error: cannot find type 'URLRequest' in scope
63 | mutating func attach(formData form: FormData) {
64 | httpBody = form.data
[11/15] Compiling OpenAIImages FormData.swift
/host/spi-builder-workspace/src/Support/FormData.swift:62:11: error: cannot find type 'URLRequest' in scope
60 | }
61 |
62 | extension URLRequest {
| `- error: cannot find type 'URLRequest' in scope
63 | mutating func attach(formData form: FormData) {
64 | httpBody = form.data
[12/15] Compiling OpenAIImages ImageGenerationResponse.swift
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4606859-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:android-6.1-latest swift build --swift-sdk aarch64-unknown-linux-android24 2>&1
android-6.1-latest: Pulling from finestructure/spi-images
Digest: sha256:fe1962677657b2408c217cb5cceb3c09bc1d91486e360cebbc6eee461a5945d8
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:android-6.1-latest
[0/1] Planning build
Building for debugging...
[0/4] Write swift-version-24593BA9C3E375BF.txt
[2/13] Compiling OpenAIImages ImageQuality.swift
[3/14] Compiling OpenAIImages ImageSize.swift
[4/14] Compiling OpenAIImages ImageModel.swift
[5/14] Compiling OpenAIImages FormData.swift
/host/spi-builder-workspace/src/Support/FormData.swift:62:11: error: cannot find type 'URLRequest' in scope
60 | }
61 |
62 | extension URLRequest {
| `- error: cannot find type 'URLRequest' in scope
63 | mutating func attach(formData form: FormData) {
64 | httpBody = form.data
error: emit-module command failed with exit code 1 (use -v to see invocation)
[6/14] Compiling OpenAIImages ErrorResponse.swift
[7/14] Compiling OpenAIImages ImageGenerationResponse.swift
[8/14] Compiling OpenAIImages EditImageRequest.swift
[9/14] Emitting module OpenAIImages
/host/spi-builder-workspace/src/ImagesAPI.swift:7:23: error: cannot find type 'URLRequest' in scope
5 | public enum Error: Swift.Error {
6 | /// The provided request is invalid.
7 | case invalidRequest(URLRequest)
| `- error: cannot find type 'URLRequest' in scope
8 |
9 | /// The response was not a 200 or 400 status
/host/spi-builder-workspace/src/ImagesAPI.swift:10:24: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | }
12 |
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/src/ImagesAPI.swift:10:8: error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
11 | }
12 |
/host/spi-builder-workspace/src/ImagesAPI.swift:13:23: error: cannot find type 'URLRequest' in scope
11 | }
12 |
13 | private let request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
14 |
15 | private let encoder = {
/host/spi-builder-workspace/src/ImagesAPI.swift:32:36: error: cannot find type 'URLRequest' in scope
30 | ///
31 | /// - Parameter request: The `URLRequest` to use for the API.
32 | public init(connectingTo request: URLRequest) throws {
| `- error: cannot find type 'URLRequest' in scope
33 | guard let url = request.url else { throw Error.invalidRequest(request) }
34 |
/host/spi-builder-workspace/src/ImagesAPI.swift:187:21: error: cannot find type 'URLRequest' in scope
185 | ///
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
| `- error: cannot find type 'URLRequest' in scope
188 | let (data, res) = try await URLSession.shared.data(for: request)
189 |
/host/spi-builder-workspace/src/Support/FormData.swift:62:11: error: cannot find type 'URLRequest' in scope
60 | }
61 |
62 | extension URLRequest {
| `- error: cannot find type 'URLRequest' in scope
63 | mutating func attach(formData form: FormData) {
64 | httpBody = form.data
[10/14] Compiling OpenAIImages ImagesAPI.swift
/host/spi-builder-workspace/src/ImagesAPI.swift:7:23: error: cannot find type 'URLRequest' in scope
5 | public enum Error: Swift.Error {
6 | /// The provided request is invalid.
7 | case invalidRequest(URLRequest)
| `- error: cannot find type 'URLRequest' in scope
8 |
9 | /// The response was not a 200 or 400 status
/host/spi-builder-workspace/src/ImagesAPI.swift:10:24: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | }
12 |
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/src/ImagesAPI.swift:10:8: error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
11 | }
12 |
/host/spi-builder-workspace/src/ImagesAPI.swift:13:23: error: cannot find type 'URLRequest' in scope
11 | }
12 |
13 | private let request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
14 |
15 | private let encoder = {
/host/spi-builder-workspace/src/ImagesAPI.swift:32:36: error: cannot find type 'URLRequest' in scope
30 | ///
31 | /// - Parameter request: The `URLRequest` to use for the API.
32 | public init(connectingTo request: URLRequest) throws {
| `- error: cannot find type 'URLRequest' in scope
33 | guard let url = request.url else { throw Error.invalidRequest(request) }
34 |
/host/spi-builder-workspace/src/ImagesAPI.swift:187:21: error: cannot find type 'URLRequest' in scope
185 | ///
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
| `- error: cannot find type 'URLRequest' in scope
188 | let (data, res) = try await URLSession.shared.data(for: request)
189 |
/host/spi-builder-workspace/src/ImagesAPI.swift:51:17: error: cannot find 'URLRequest' in scope
49 | /// - Parameter projectId: The project associated with the request.
50 | public convenience init(authToken: String, organizationId: String? = nil, projectId: String? = nil) {
51 | var request = URLRequest(url: URL(string: "https://api.openai.com/")!)
| `- error: cannot find 'URLRequest' in scope
52 |
53 | request.addValue("Bearer \(authToken)", forHTTPHeaderField: "Authorization")
/host/spi-builder-workspace/src/ImagesAPI.swift:57:32: error: extra argument 'connectingTo' in call
55 | if let organizationId { request.addValue(organizationId, forHTTPHeaderField: "OpenAI-Organization") }
56 |
57 | try! self.init(connectingTo: request)
| `- error: extra argument 'connectingTo' in call
58 | }
59 |
/host/spi-builder-workspace/src/ImagesAPI.swift:57:18: error: missing argument for parameter 'authToken' in call
48 | /// - Parameter organizationId: The [organization](https://platform.openai.com/docs/guides/production-best-practices#setting-up-your-organization) associated with the request.
49 | /// - Parameter projectId: The project associated with the request.
50 | public convenience init(authToken: String, organizationId: String? = nil, projectId: String? = nil) {
| `- note: 'init(authToken:organizationId:projectId:)' declared here
51 | var request = URLRequest(url: URL(string: "https://api.openai.com/")!)
52 |
:
55 | if let organizationId { request.addValue(organizationId, forHTTPHeaderField: "OpenAI-Organization") }
56 |
57 | try! self.init(connectingTo: request)
| `- error: missing argument for parameter 'authToken' in call
58 | }
59 |
/host/spi-builder-workspace/src/ImagesAPI.swift:188:42: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
188 | let (data, res) = try await URLSession.shared.data(for: request)
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
189 |
190 | guard let res = res as? HTTPURLResponse else { throw Error.invalidResponse(res) }
[11/14] Compiling OpenAIImages CreateImageRequest.swift
/host/spi-builder-workspace/src/ImagesAPI.swift:7:23: error: cannot find type 'URLRequest' in scope
5 | public enum Error: Swift.Error {
6 | /// The provided request is invalid.
7 | case invalidRequest(URLRequest)
| `- error: cannot find type 'URLRequest' in scope
8 |
9 | /// The response was not a 200 or 400 status
/host/spi-builder-workspace/src/ImagesAPI.swift:10:24: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | }
12 |
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/src/ImagesAPI.swift:10:8: error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
8 |
9 | /// The response was not a 200 or 400 status
10 | case invalidResponse(URLResponse)
| `- error: associated value 'invalidResponse' of 'Sendable'-conforming enum 'Error' has non-sendable type 'URLResponse' (aka 'AnyObject')
11 | }
12 |
/host/spi-builder-workspace/src/ImagesAPI.swift:13:23: error: cannot find type 'URLRequest' in scope
11 | }
12 |
13 | private let request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
14 |
15 | private let encoder = {
/host/spi-builder-workspace/src/ImagesAPI.swift:32:36: error: cannot find type 'URLRequest' in scope
30 | ///
31 | /// - Parameter request: The `URLRequest` to use for the API.
32 | public init(connectingTo request: URLRequest) throws {
| `- error: cannot find type 'URLRequest' in scope
33 | guard let url = request.url else { throw Error.invalidRequest(request) }
34 |
/host/spi-builder-workspace/src/ImagesAPI.swift:187:21: error: cannot find type 'URLRequest' in scope
185 | ///
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
| `- error: cannot find type 'URLRequest' in scope
188 | let (data, res) = try await URLSession.shared.data(for: request)
189 |
/host/spi-builder-workspace/src/ImagesAPI.swift:51:17: error: cannot find 'URLRequest' in scope
49 | /// - Parameter projectId: The project associated with the request.
50 | public convenience init(authToken: String, organizationId: String? = nil, projectId: String? = nil) {
51 | var request = URLRequest(url: URL(string: "https://api.openai.com/")!)
| `- error: cannot find 'URLRequest' in scope
52 |
53 | request.addValue("Bearer \(authToken)", forHTTPHeaderField: "Authorization")
/host/spi-builder-workspace/src/ImagesAPI.swift:57:32: error: extra argument 'connectingTo' in call
55 | if let organizationId { request.addValue(organizationId, forHTTPHeaderField: "OpenAI-Organization") }
56 |
57 | try! self.init(connectingTo: request)
| `- error: extra argument 'connectingTo' in call
58 | }
59 |
/host/spi-builder-workspace/src/ImagesAPI.swift:57:18: error: missing argument for parameter 'authToken' in call
48 | /// - Parameter organizationId: The [organization](https://platform.openai.com/docs/guides/production-best-practices#setting-up-your-organization) associated with the request.
49 | /// - Parameter projectId: The project associated with the request.
50 | public convenience init(authToken: String, organizationId: String? = nil, projectId: String? = nil) {
| `- note: 'init(authToken:organizationId:projectId:)' declared here
51 | var request = URLRequest(url: URL(string: "https://api.openai.com/")!)
52 |
:
55 | if let organizationId { request.addValue(organizationId, forHTTPHeaderField: "OpenAI-Organization") }
56 |
57 | try! self.init(connectingTo: request)
| `- error: missing argument for parameter 'authToken' in call
58 | }
59 |
/host/spi-builder-workspace/src/ImagesAPI.swift:188:42: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
186 | /// - Throws: If the request fails to send or has a non-200 status code.
187 | func send(request: URLRequest, expects statusCode: Int = 200) async throws -> Data {
188 | let (data, res) = try await URLSession.shared.data(for: request)
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
189 |
190 | guard let res = res as? HTTPURLResponse else { throw Error.invalidResponse(res) }
BUILD FAILURE 6.1 android