Build Information
Failed to build Recapi, reference main (a2c254), with Swift 6.2 for Wasm on 25 Nov 2026 04:10:32 UTC.
Build Command
bash -c docker run --pull=always --rm -v "checkouts-53886768-0":/host -w "$PWD" -e JAVA_HOME="/root/.sdkman/candidates/java/current" -e SPI_BUILD="1" -e SPI_PROCESSING="1" registry.gitlab.com/saguaro1/spi-images:wasm-6.2-latest swift build --swift-sdk swift-6.2-RELEASE_wasm 2>&1Build Log
========================================
RunAll
========================================
Builder version: 5.1.4
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/Blushedface/recapi-swift.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/Blushedface/recapi-swift
* branch main -> FETCH_HEAD
* [new branch] main -> origin/main
HEAD is now at a2c254d recapi-swift 0.1.18
Cloned https://github.com/Blushedface/recapi-swift.git
Revision (git rev-parse @):
a2c254d276f11f153e125aa58dbde176b12a02fc
SUCCESS checkout https://github.com/Blushedface/recapi-swift.git at main
========================================
Build
========================================
Selected platform: wasm
Swift version: 6.2
Building package at path: $PWD
https://github.com/Blushedface/recapi-swift.git
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-53886768-0":/host -w "$PWD" -e JAVA_HOME="/root/.sdkman/candidates/java/current" -e SPI_BUILD="1" -e SPI_PROCESSING="1" registry.gitlab.com/saguaro1/spi-images:wasm-6.2-latest swift build --swift-sdk swift-6.2-RELEASE_wasm 2>&1
wasm-6.2-latest: Pulling from saguaro1/spi-images
Digest: sha256:0edccce2083c005c7cf1d4a8cd47fd86214ad7a39c32bca4f7db4cf90ab01f49
Status: Image is up to date for registry.gitlab.com/saguaro1/spi-images:wasm-6.2-latest
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-24593BA9C3E375BF.txt
[3/9] Compiling Recapi Transport.swift
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:79:36: error: cannot find type 'URLSessionTaskDelegate' in scope
77 | /// Refuses redirects: a 3xx (an http:// base URL sent on to https) fails like
78 | /// a 4xx, or a DELETE would look done.
79 | final class NoRedirects: NSObject, URLSessionTaskDelegate, Sendable {
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:82:29: error: cannot find type 'URLRequest' in scope
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
| `- error: cannot find type 'URLRequest' in scope
83 | ) {
84 | completionHandler(nil)
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:82:81: error: cannot find type 'URLRequest' in scope
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
| `- error: cannot find type 'URLRequest' in scope
83 | ) {
84 | completionHandler(nil)
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:81:20: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
79 | final class NoRedirects: NSObject, URLSessionTaskDelegate, Sendable {
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
83 | ) {
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/Recapi/Transport.swift:81:38: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
79 | final class NoRedirects: NSObject, URLSessionTaskDelegate, Sendable {
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
| `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
83 | ) {
Foundation.URLSessionTask:2:18: note: 'URLSessionTask' 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 URLSessionTask = AnyObject
| `- note: 'URLSessionTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:81:91: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
79 | final class NoRedirects: NSObject, URLSessionTaskDelegate, Sendable {
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
83 | ) {
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/Recapi/Transport.swift:149:34: error: cannot find type 'URLRequest' in scope
147 | /// Linux's URLSession ignores timeoutInterval, so the deadline is the
148 | /// client's own: a timer races the request and cancels it.
149 | private func send(_ request: URLRequest, timeout: Double) async throws(RecapiError) -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
150 | let result = await withCheckedContinuation { (c: CheckedContinuation<Result<(Data, URLResponse), RecapiError>, Never>) in
151 | let once = Once(c)
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:149:99: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
147 | /// Linux's URLSession ignores timeoutInterval, so the deadline is the
148 | /// client's own: a timer races the request and cancels it.
149 | private func send(_ request: URLRequest, timeout: Double) async throws(RecapiError) -> (Data, URLResponse) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
150 | let result = await withCheckedContinuation { (c: CheckedContinuation<Result<(Data, URLResponse), RecapiError>, Never>) in
151 | let once = Once(c)
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/Recapi/Transport.swift:190:28: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
188 | }
189 |
190 | func httpError(_ response: HTTPURLResponse, _ data: Data) -> RecapiError {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
191 | let payload = (try? JSONValue.parse(data))?["error"]
192 | let status = response.statusCode
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/Recapi/Transport.swift:84:27: error: 'nil' requires a contextual type
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
83 | ) {
84 | completionHandler(nil)
| `- error: 'nil' requires a contextual type
85 | }
86 | }
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:118:23: error: cannot find 'URLRequest' in scope
116 | throw RecapiError(code: "invalid_request", message: "bad URL \(target)")
117 | }
118 | var request = URLRequest(url: url, cachePolicy: .reloadIgnoringLocalCacheData, timeoutInterval: timeout)
| `- error: cannot find 'URLRequest' in scope
119 | request.httpMethod = method
120 | for (name, value) in headers { request.setValue(value, forHTTPHeaderField: name) }
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:118:58: error: cannot infer contextual base in reference to member 'reloadIgnoringLocalCacheData'
116 | throw RecapiError(code: "invalid_request", message: "bad URL \(target)")
117 | }
118 | var request = URLRequest(url: url, cachePolicy: .reloadIgnoringLocalCacheData, timeoutInterval: timeout)
| `- error: cannot infer contextual base in reference to member 'reloadIgnoringLocalCacheData'
119 | request.httpMethod = method
120 | for (name, value) in headers { request.setValue(value, forHTTPHeaderField: name) }
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:161:13: error: cannot find 'DispatchQueue' in scope
159 | }
160 | }
161 | DispatchQueue.global().asyncAfter(deadline: .now() + timeout) {
| `- error: cannot find 'DispatchQueue' in scope
162 | if once.resume(.failure(RecapiError(code: "timeout", message: "no answer within \(timeout) s"))) {
163 | task.cancel()
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:152:32: error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
150 | let result = await withCheckedContinuation { (c: CheckedContinuation<Result<(Data, URLResponse), RecapiError>, Never>) in
151 | let once = Once(c)
152 | let task = session.dataTask(with: request) { data, response, error in
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
153 | if let response, error == nil {
154 | once.resume(.success((data ?? Data(), response)))
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:154:59: error: value of type '_' expected to be instance of class or class-constrained type
152 | let task = session.dataTask(with: request) { data, response, error in
153 | if let response, error == nil {
154 | once.resume(.success((data ?? Data(), response)))
| `- error: value of type '_' expected to be instance of class or class-constrained type
155 | } else if let error = error as? URLError, error.code == .timedOut {
156 | once.resume(.failure(RecapiError(code: "timeout", message: "no answer in time: \(error)")))
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:192:27: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
190 | func httpError(_ response: HTTPURLResponse, _ data: Data) -> RecapiError {
191 | let payload = (try? JSONValue.parse(data))?["error"]
192 | let status = response.statusCode
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
193 | var code = payload?["code"]?.stringValue ?? ""
194 | if code.isEmpty { code = codeByStatus[status] ?? (status >= 500 ? "internal" : "http_error") }
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:198:30: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
196 | if message.isEmpty { message = "HTTP \(status)" }
197 | var retryAfter: Double?
198 | if let header = response.value(forHTTPHeaderField: "Retry-After"),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
199 | let seconds = Double(header.trimmingCharacters(in: .whitespaces)), seconds >= 0, seconds.isFinite
200 | {
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:199:61: error: cannot infer contextual base in reference to member 'whitespaces'
197 | var retryAfter: Double?
198 | if let header = response.value(forHTTPHeaderField: "Retry-After"),
199 | let seconds = Double(header.trimmingCharacters(in: .whitespaces)), seconds >= 0, seconds.isFinite
| `- error: cannot infer contextual base in reference to member 'whitespaces'
200 | {
201 | retryAfter = seconds
[4/9] Compiling Recapi SHA256.swift
[5/9] Compiling Recapi Store.swift
/host/spi-builder-workspace/Sources/Recapi/Store.swift:69:25: error: cannot find 'DispatchQueue' in scope
67 | private let max: Int
68 | private let lock = NSLock()
69 | private let queue = DispatchQueue(label: "io.recapi.store")
| `- error: cannot find 'DispatchQueue' in scope
70 | // By file name. Each value's sequence number is stored with it: the
71 | // eviction order survives a restart without reading file dates.
/host/spi-builder-workspace/Sources/Recapi/Store.swift:171:93: error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
169 | if let entry {
170 | try FileManager.default.createDirectory(at: directory, withIntermediateDirectories: true)
171 | try Data("\(entry.seq)\n\(entry.value)".utf8).write(to: file, options: .atomic)
| `- error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
172 | } else if FileManager.default.fileExists(atPath: file.path) {
173 | try FileManager.default.removeItem(at: file)
FoundationEssentials.Data.WritingOptions.atomic:4:23: note: 'atomic' has been explicitly marked unavailable here
2 | struct WritingOptions {
3 | @available(*, unavailable, message: "atomic writing is unavailable in WASI because temporary files are not supported")
4 | public static let atomic: Data.WritingOptions }
| `- note: 'atomic' has been explicitly marked unavailable here
5 | }
6 |
[6/9] Compiling Recapi JSON.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)
[7/9] Emitting module Recapi
/host/spi-builder-workspace/Sources/Recapi/Client.swift:192:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
190 | let interval: Double
191 | let prefix: String
192 | let session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
193 |
194 | /// Guards the store's read-modify-writes, the queue, failures and started.
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/Recapi/Client.swift:242:47: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
240 | init(
241 | apiKey: String, baseURL: String, store: RecapiStore?, timeout: Double, maxBatch: Int?,
242 | flushInterval: Double, configuration: URLSessionConfiguration, sender: Bool
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
243 | ) throws(RecapiError) {
244 | guard !apiKey.isEmpty else { throw .invalid("apiKey is required") }
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' 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 URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Recapi/Store.swift:69:25: error: cannot find 'DispatchQueue' in scope
67 | private let max: Int
68 | private let lock = NSLock()
69 | private let queue = DispatchQueue(label: "io.recapi.store")
| `- error: cannot find 'DispatchQueue' in scope
70 | // By file name. Each value's sequence number is stored with it: the
71 | // eviction order survives a restart without reading file dates.
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:79:36: error: cannot find type 'URLSessionTaskDelegate' in scope
77 | /// Refuses redirects: a 3xx (an http:// base URL sent on to https) fails like
78 | /// a 4xx, or a DELETE would look done.
79 | final class NoRedirects: NSObject, URLSessionTaskDelegate, Sendable {
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:82:29: error: cannot find type 'URLRequest' in scope
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
| `- error: cannot find type 'URLRequest' in scope
83 | ) {
84 | completionHandler(nil)
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:82:81: error: cannot find type 'URLRequest' in scope
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
| `- error: cannot find type 'URLRequest' in scope
83 | ) {
84 | completionHandler(nil)
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:81:20: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
79 | final class NoRedirects: NSObject, URLSessionTaskDelegate, Sendable {
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
83 | ) {
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/Recapi/Transport.swift:81:38: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
79 | final class NoRedirects: NSObject, URLSessionTaskDelegate, Sendable {
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
| `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
83 | ) {
Foundation.URLSessionTask:2:18: note: 'URLSessionTask' 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 URLSessionTask = AnyObject
| `- note: 'URLSessionTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:81:91: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
79 | final class NoRedirects: NSObject, URLSessionTaskDelegate, Sendable {
80 | func urlSession(
81 | _ session: URLSession, task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
82 | newRequest request: URLRequest, completionHandler: @escaping @Sendable (URLRequest?) -> Void
83 | ) {
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/Recapi/Transport.swift:149:34: error: cannot find type 'URLRequest' in scope
147 | /// Linux's URLSession ignores timeoutInterval, so the deadline is the
148 | /// client's own: a timer races the request and cancels it.
149 | private func send(_ request: URLRequest, timeout: Double) async throws(RecapiError) -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
150 | let result = await withCheckedContinuation { (c: CheckedContinuation<Result<(Data, URLResponse), RecapiError>, Never>) in
151 | let once = Once(c)
/host/spi-builder-workspace/Sources/Recapi/Transport.swift:149:99: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
147 | /// Linux's URLSession ignores timeoutInterval, so the deadline is the
148 | /// client's own: a timer races the request and cancels it.
149 | private func send(_ request: URLRequest, timeout: Double) async throws(RecapiError) -> (Data, URLResponse) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
150 | let result = await withCheckedContinuation { (c: CheckedContinuation<Result<(Data, URLResponse), RecapiError>, Never>) in
151 | let once = Once(c)
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/Recapi/Transport.swift:190:28: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
188 | }
189 |
190 | func httpError(_ response: HTTPURLResponse, _ data: Data) -> RecapiError {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
191 | let payload = (try? JSONValue.parse(data))?["error"]
192 | let status = response.statusCode
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
[8/9] Compiling Recapi History.swift
[9/9] Compiling Recapi Client.swift
/host/spi-builder-workspace/Sources/Recapi/Client.swift:192:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
190 | let interval: Double
191 | let prefix: String
192 | let session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
193 |
194 | /// Guards the store's read-modify-writes, the queue, failures and started.
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/Recapi/Client.swift:242:47: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
240 | init(
241 | apiKey: String, baseURL: String, store: RecapiStore?, timeout: Double, maxBatch: Int?,
242 | flushInterval: Double, configuration: URLSessionConfiguration, sender: Bool
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
243 | ) throws(RecapiError) {
244 | guard !apiKey.isEmpty else { throw .invalid("apiKey is required") }
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' 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 URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Recapi/Client.swift:236:59: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
234 | try self.init(
235 | apiKey: apiKey, baseURL: baseURL, store: store, timeout: timeout, maxBatch: maxBatch,
236 | flushInterval: flushInterval, configuration: .ephemeral, sender: true)
| `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
237 | }
238 |
/host/spi-builder-workspace/Sources/Recapi/Client.swift:260:19: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
258 | // Two environments' keys may share one Redis: their users must not mix.
259 | prefix = "recapi:" + sha256Hex(apiKey).prefix(12) + ":"
260 | session = URLSession(configuration: configuration, delegate: NoRedirects(), delegateQueue: nil)
| `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
261 | }
262 |
/host/spi-builder-workspace/Sources/Recapi/Client.swift:260:100: error: 'nil' requires a contextual type
258 | // Two environments' keys may share one Redis: their users must not mix.
259 | prefix = "recapi:" + sha256Hex(apiKey).prefix(12) + ":"
260 | session = URLSession(configuration: configuration, delegate: NoRedirects(), delegateQueue: nil)
| `- error: 'nil' requires a contextual type
261 | }
262 |
/host/spi-builder-workspace/Sources/Recapi/Client.swift:263:22: error: value of type 'URLSession' (aka 'AnyObject') has no member 'finishTasksAndInvalidate'
261 | }
262 |
263 | deinit { session.finishTasksAndInvalidate() }
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'finishTasksAndInvalidate'
264 |
265 | static func sleeper(_ closed: Signal) -> @Sendable (Double, Bool) async -> Bool {
/host/spi-builder-workspace/Sources/Recapi/Client.swift:420:32: error: cannot find 'DispatchTime' in scope
418 | Task.detached { [weak self] in
419 | while let delay = self?.senderDelay() {
420 | let deadline = DispatchTime.now() + delay
| `- error: cannot find 'DispatchTime' in scope
421 | var woken = await wake.wait(delay)
422 | // A full batch goes at once, except after a failure: then the
/host/spi-builder-workspace/Sources/Recapi/Client.swift:425:74: error: cannot find 'DispatchTime' in scope
423 | // backoff holds, or a down API would be hammered.
424 | while woken, !closed.isFired, self?.fullBatchReady() == false {
425 | let left = Int64(deadline.uptimeNanoseconds) - Int64(DispatchTime.now().uptimeNanoseconds)
| `- error: cannot find 'DispatchTime' in scope
426 | woken = await wake.wait(Double(left) / 1e9)
427 | }
/host/spi-builder-workspace/Sources/Recapi/Client.swift:580:24: error: cannot find 'DispatchTime' in scope
578 | let limit = min(timeout, RecapiClient.recommendTimeout)
579 | // The restore and the recommendation share one deadline.
580 | let deadline = DispatchTime.now() + limit
| `- error: cannot find 'DispatchTime' in scope
581 | let left = { max(0, Double(Int64(deadline.uptimeNanoseconds) - Int64(DispatchTime.now().uptimeNanoseconds)) / 1e9) }
582 | var rows = rows, shared = shared
/host/spi-builder-workspace/Sources/Recapi/Client.swift:581:78: error: cannot find 'DispatchTime' in scope
579 | // The restore and the recommendation share one deadline.
580 | let deadline = DispatchTime.now() + limit
581 | let left = { max(0, Double(Int64(deadline.uptimeNanoseconds) - Int64(DispatchTime.now().uptimeNanoseconds)) / 1e9) }
| `- error: cannot find 'DispatchTime' in scope
582 | var rows = rows, shared = shared
583 | // One list sends its exclude as the call's.
/host/spi-builder-workspace/Sources/Recapi/Client.swift:921:13: error: cannot find 'DispatchQueue' in scope
919 | }
920 | guard let id else { return c.resume(returning: true) }
921 | DispatchQueue.global().asyncAfter(deadline: .now() + max(0, seconds)) {
| `- error: cannot find 'DispatchQueue' in scope
922 | self.lock.locked { self.waiters.removeValue(forKey: id) }?.resume(returning: false)
923 | }
/host/spi-builder-workspace/Sources/Recapi/Client.swift:921:58: error: cannot call value of non-function type 'Date'
919 | }
920 | guard let id else { return c.resume(returning: true) }
921 | DispatchQueue.global().asyncAfter(deadline: .now() + max(0, seconds)) {
| `- error: cannot call value of non-function type 'Date'
922 | self.lock.locked { self.waiters.removeValue(forKey: id) }?.resume(returning: false)
923 | }
BUILD FAILURE 6.2 wasm