Build Information
Failed to build swift-blocks, reference main (5017a4), with Swift 6.2 for Wasm on 12 Nov 2026 22:03:20 UTC.
Build Command
bash -c docker run --pull=always --rm -v "checkouts-54344843-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
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
30 | httpVersion: nil,
| `- error: 'nil' requires a contextual type
31 | headerFields: nil
32 | )
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:31:37: error: 'nil' requires a contextual type
29 | statusCode: 200,
30 | httpVersion: nil,
31 | headerFields: nil
| `- error: 'nil' requires a contextual type
32 | )
33 | else {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:45:21: error: cannot find type 'URLRequest' in scope
43 | /// - Throws: An error if the request fails after retry attempts.
44 | public func send(
45 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:46:19: error: cannot find type 'URLSessionTaskDelegate' in scope
44 | public func send(
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
47 | ) async throws -> (Data, HTTPURLResponse) {
48 | var nbAttempts = 0
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:47:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
48 | var nbAttempts = 0
49 | var errors: [Error] = []
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/Blocks/Transport/StatusCodeCheckingTransport.swift:75:21: error: cannot find type 'URLRequest' in scope
73 | /// - Throws: A `WrongStatusCodeError` if the actual status code does not match the expected range.
74 | public func send(
75 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:76:19: error: cannot find type 'URLSessionTaskDelegate' in scope
74 | public func send(
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
77 | ) async throws -> (Data, HTTPURLResponse) {
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:77:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
79 |
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:26: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 |
107 | /// The response body data associated with the error.
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/Blocks/Transport/StatusCodeCheckingTransport.swift:115:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
113 | /// - response: The HTTP URL response associated with the error.
114 | /// - responseBody: The response body data associated with the error.
115 | public init(statusCode: Int, response: HTTPURLResponse?, responseBody: Data?) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
116 | self.statusCode = statusCode
117 | self.response = response
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:16: warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
106 |
107 | /// The response body data associated with the error.
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:13:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 | }
15 |
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/Blocks/Transport/Transport.swift:25:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
23 | @available(iOS 15.0.0, *)
24 | @available(macOS 12.0, *)
25 | extension URLSession: Transport {
| `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
26 | public func send(
27 | urlRequest: URLRequest,
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:27:21: error: cannot find type 'URLRequest' in scope
25 | extension URLSession: Transport {
26 | public func send(
27 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
28 | delegate: URLSessionTaskDelegate?
29 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:28:19: error: cannot find type 'URLSessionTaskDelegate' in scope
26 | public func send(
27 | urlRequest: URLRequest,
28 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
29 | ) async throws -> (Data, HTTPURLResponse) {
30 | let (data, response) = try await self.data(for: urlRequest, delegate: delegate)
[#NominalTypes]: <https://docs.swift.org/compiler/documentation/diagnostics/nominal-types>
[22/67] Compiling Blocks MultipartRequest.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:10:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
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/Blocks/Transport/MockTransport.swift:12:74: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
10 | let response: HTTPURLResponse?
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
13 | self.data = data
14 | self.response = response
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/Blocks/Transport/MockTransport.swift:18:21: error: cannot find type 'URLRequest' in scope
16 |
17 | public func send(
18 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:19:21: error: cannot find type 'URLSessionTaskDelegate' in scope
17 | public func send(
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:20:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
21 | let actualResponse: HTTPURLResponse
22 |
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/Blocks/Transport/MockTransport.swift:10:9: error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:21:29: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | if let response {
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/Blocks/Transport/MockTransport.swift:27:38: error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
25 | } else {
26 | guard let fallbackURL = URL(string: "https://foo.tld/bar"),
27 | let httpResponse = HTTPURLResponse(
| `- error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:30:36: error: 'nil' requires a contextual type
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
30 | httpVersion: nil,
| `- error: 'nil' requires a contextual type
31 | headerFields: nil
32 | )
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:31:37: error: 'nil' requires a contextual type
29 | statusCode: 200,
30 | httpVersion: nil,
31 | headerFields: nil
| `- error: 'nil' requires a contextual type
32 | )
33 | else {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:45:21: error: cannot find type 'URLRequest' in scope
43 | /// - Throws: An error if the request fails after retry attempts.
44 | public func send(
45 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:46:19: error: cannot find type 'URLSessionTaskDelegate' in scope
44 | public func send(
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
47 | ) async throws -> (Data, HTTPURLResponse) {
48 | var nbAttempts = 0
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:47:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
48 | var nbAttempts = 0
49 | var errors: [Error] = []
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/Blocks/Transport/StatusCodeCheckingTransport.swift:75:21: error: cannot find type 'URLRequest' in scope
73 | /// - Throws: A `WrongStatusCodeError` if the actual status code does not match the expected range.
74 | public func send(
75 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:76:19: error: cannot find type 'URLSessionTaskDelegate' in scope
74 | public func send(
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
77 | ) async throws -> (Data, HTTPURLResponse) {
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:77:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
79 |
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:26: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 |
107 | /// The response body data associated with the error.
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/Blocks/Transport/StatusCodeCheckingTransport.swift:115:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
113 | /// - response: The HTTP URL response associated with the error.
114 | /// - responseBody: The response body data associated with the error.
115 | public init(statusCode: Int, response: HTTPURLResponse?, responseBody: Data?) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
116 | self.statusCode = statusCode
117 | self.response = response
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:16: warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
106 |
107 | /// The response body data associated with the error.
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:13:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 | }
15 |
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/Blocks/Transport/Transport.swift:25:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
23 | @available(iOS 15.0.0, *)
24 | @available(macOS 12.0, *)
25 | extension URLSession: Transport {
| `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
26 | public func send(
27 | urlRequest: URLRequest,
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:27:21: error: cannot find type 'URLRequest' in scope
25 | extension URLSession: Transport {
26 | public func send(
27 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
28 | delegate: URLSessionTaskDelegate?
29 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:28:19: error: cannot find type 'URLSessionTaskDelegate' in scope
26 | public func send(
27 | urlRequest: URLRequest,
28 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
29 | ) async throws -> (Data, HTTPURLResponse) {
30 | let (data, response) = try await self.data(for: urlRequest, delegate: delegate)
[#NominalTypes]: <https://docs.swift.org/compiler/documentation/diagnostics/nominal-types>
[23/67] Compiling Blocks RetryTransport.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:10:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
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/Blocks/Transport/MockTransport.swift:12:74: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
10 | let response: HTTPURLResponse?
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
13 | self.data = data
14 | self.response = response
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/Blocks/Transport/MockTransport.swift:18:21: error: cannot find type 'URLRequest' in scope
16 |
17 | public func send(
18 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:19:21: error: cannot find type 'URLSessionTaskDelegate' in scope
17 | public func send(
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:20:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
21 | let actualResponse: HTTPURLResponse
22 |
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/Blocks/Transport/MockTransport.swift:10:9: error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:21:29: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | if let response {
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/Blocks/Transport/MockTransport.swift:27:38: error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
25 | } else {
26 | guard let fallbackURL = URL(string: "https://foo.tld/bar"),
27 | let httpResponse = HTTPURLResponse(
| `- error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:30:36: error: 'nil' requires a contextual type
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
30 | httpVersion: nil,
| `- error: 'nil' requires a contextual type
31 | headerFields: nil
32 | )
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:31:37: error: 'nil' requires a contextual type
29 | statusCode: 200,
30 | httpVersion: nil,
31 | headerFields: nil
| `- error: 'nil' requires a contextual type
32 | )
33 | else {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:45:21: error: cannot find type 'URLRequest' in scope
43 | /// - Throws: An error if the request fails after retry attempts.
44 | public func send(
45 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:46:19: error: cannot find type 'URLSessionTaskDelegate' in scope
44 | public func send(
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
47 | ) async throws -> (Data, HTTPURLResponse) {
48 | var nbAttempts = 0
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:47:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
48 | var nbAttempts = 0
49 | var errors: [Error] = []
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/Blocks/Transport/StatusCodeCheckingTransport.swift:75:21: error: cannot find type 'URLRequest' in scope
73 | /// - Throws: A `WrongStatusCodeError` if the actual status code does not match the expected range.
74 | public func send(
75 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:76:19: error: cannot find type 'URLSessionTaskDelegate' in scope
74 | public func send(
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
77 | ) async throws -> (Data, HTTPURLResponse) {
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:77:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
79 |
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:26: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 |
107 | /// The response body data associated with the error.
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/Blocks/Transport/StatusCodeCheckingTransport.swift:115:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
113 | /// - response: The HTTP URL response associated with the error.
114 | /// - responseBody: The response body data associated with the error.
115 | public init(statusCode: Int, response: HTTPURLResponse?, responseBody: Data?) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
116 | self.statusCode = statusCode
117 | self.response = response
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:16: warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
106 |
107 | /// The response body data associated with the error.
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:13:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 | }
15 |
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/Blocks/Transport/Transport.swift:25:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
23 | @available(iOS 15.0.0, *)
24 | @available(macOS 12.0, *)
25 | extension URLSession: Transport {
| `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
26 | public func send(
27 | urlRequest: URLRequest,
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:27:21: error: cannot find type 'URLRequest' in scope
25 | extension URLSession: Transport {
26 | public func send(
27 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
28 | delegate: URLSessionTaskDelegate?
29 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:28:19: error: cannot find type 'URLSessionTaskDelegate' in scope
26 | public func send(
27 | urlRequest: URLRequest,
28 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
29 | ) async throws -> (Data, HTTPURLResponse) {
30 | let (data, response) = try await self.data(for: urlRequest, delegate: delegate)
[#NominalTypes]: <https://docs.swift.org/compiler/documentation/diagnostics/nominal-types>
[24/67] Compiling Blocks StatusCodeCheckingTransport.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:10:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
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/Blocks/Transport/MockTransport.swift:12:74: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
10 | let response: HTTPURLResponse?
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
13 | self.data = data
14 | self.response = response
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/Blocks/Transport/MockTransport.swift:18:21: error: cannot find type 'URLRequest' in scope
16 |
17 | public func send(
18 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:19:21: error: cannot find type 'URLSessionTaskDelegate' in scope
17 | public func send(
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:20:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
21 | let actualResponse: HTTPURLResponse
22 |
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/Blocks/Transport/MockTransport.swift:10:9: error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:21:29: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | if let response {
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/Blocks/Transport/MockTransport.swift:27:38: error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
25 | } else {
26 | guard let fallbackURL = URL(string: "https://foo.tld/bar"),
27 | let httpResponse = HTTPURLResponse(
| `- error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:30:36: error: 'nil' requires a contextual type
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
30 | httpVersion: nil,
| `- error: 'nil' requires a contextual type
31 | headerFields: nil
32 | )
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:31:37: error: 'nil' requires a contextual type
29 | statusCode: 200,
30 | httpVersion: nil,
31 | headerFields: nil
| `- error: 'nil' requires a contextual type
32 | )
33 | else {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:45:21: error: cannot find type 'URLRequest' in scope
43 | /// - Throws: An error if the request fails after retry attempts.
44 | public func send(
45 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:46:19: error: cannot find type 'URLSessionTaskDelegate' in scope
44 | public func send(
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
47 | ) async throws -> (Data, HTTPURLResponse) {
48 | var nbAttempts = 0
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:47:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
48 | var nbAttempts = 0
49 | var errors: [Error] = []
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/Blocks/Transport/StatusCodeCheckingTransport.swift:75:21: error: cannot find type 'URLRequest' in scope
73 | /// - Throws: A `WrongStatusCodeError` if the actual status code does not match the expected range.
74 | public func send(
75 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:76:19: error: cannot find type 'URLSessionTaskDelegate' in scope
74 | public func send(
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
77 | ) async throws -> (Data, HTTPURLResponse) {
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:77:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
79 |
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:26: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 |
107 | /// The response body data associated with the error.
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/Blocks/Transport/StatusCodeCheckingTransport.swift:115:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
113 | /// - response: The HTTP URL response associated with the error.
114 | /// - responseBody: The response body data associated with the error.
115 | public init(statusCode: Int, response: HTTPURLResponse?, responseBody: Data?) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
116 | self.statusCode = statusCode
117 | self.response = response
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:16: warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
106 |
107 | /// The response body data associated with the error.
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:13:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 | }
15 |
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/Blocks/Transport/Transport.swift:25:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
23 | @available(iOS 15.0.0, *)
24 | @available(macOS 12.0, *)
25 | extension URLSession: Transport {
| `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
26 | public func send(
27 | urlRequest: URLRequest,
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:27:21: error: cannot find type 'URLRequest' in scope
25 | extension URLSession: Transport {
26 | public func send(
27 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
28 | delegate: URLSessionTaskDelegate?
29 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:28:19: error: cannot find type 'URLSessionTaskDelegate' in scope
26 | public func send(
27 | urlRequest: URLRequest,
28 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
29 | ) async throws -> (Data, HTTPURLResponse) {
30 | let (data, response) = try await self.data(for: urlRequest, delegate: delegate)
[#NominalTypes]: <https://docs.swift.org/compiler/documentation/diagnostics/nominal-types>
[25/67] Compiling Blocks TaskState.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:10:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
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/Blocks/Transport/MockTransport.swift:12:74: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
10 | let response: HTTPURLResponse?
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
13 | self.data = data
14 | self.response = response
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/Blocks/Transport/MockTransport.swift:18:21: error: cannot find type 'URLRequest' in scope
16 |
17 | public func send(
18 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:19:21: error: cannot find type 'URLSessionTaskDelegate' in scope
17 | public func send(
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:20:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
21 | let actualResponse: HTTPURLResponse
22 |
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/Blocks/Transport/MockTransport.swift:10:9: error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:21:29: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | if let response {
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/Blocks/Transport/MockTransport.swift:27:38: error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
25 | } else {
26 | guard let fallbackURL = URL(string: "https://foo.tld/bar"),
27 | let httpResponse = HTTPURLResponse(
| `- error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:30:36: error: 'nil' requires a contextual type
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
30 | httpVersion: nil,
| `- error: 'nil' requires a contextual type
31 | headerFields: nil
32 | )
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:31:37: error: 'nil' requires a contextual type
29 | statusCode: 200,
30 | httpVersion: nil,
31 | headerFields: nil
| `- error: 'nil' requires a contextual type
32 | )
33 | else {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:45:21: error: cannot find type 'URLRequest' in scope
43 | /// - Throws: An error if the request fails after retry attempts.
44 | public func send(
45 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:46:19: error: cannot find type 'URLSessionTaskDelegate' in scope
44 | public func send(
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
47 | ) async throws -> (Data, HTTPURLResponse) {
48 | var nbAttempts = 0
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:47:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
48 | var nbAttempts = 0
49 | var errors: [Error] = []
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/Blocks/Transport/StatusCodeCheckingTransport.swift:75:21: error: cannot find type 'URLRequest' in scope
73 | /// - Throws: A `WrongStatusCodeError` if the actual status code does not match the expected range.
74 | public func send(
75 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:76:19: error: cannot find type 'URLSessionTaskDelegate' in scope
74 | public func send(
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
77 | ) async throws -> (Data, HTTPURLResponse) {
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:77:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
79 |
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:26: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 |
107 | /// The response body data associated with the error.
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/Blocks/Transport/StatusCodeCheckingTransport.swift:115:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
113 | /// - response: The HTTP URL response associated with the error.
114 | /// - responseBody: The response body data associated with the error.
115 | public init(statusCode: Int, response: HTTPURLResponse?, responseBody: Data?) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
116 | self.statusCode = statusCode
117 | self.response = response
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:16: warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
106 |
107 | /// The response body data associated with the error.
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:13:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 | }
15 |
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/Blocks/Transport/Transport.swift:25:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
23 | @available(iOS 15.0.0, *)
24 | @available(macOS 12.0, *)
25 | extension URLSession: Transport {
| `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
26 | public func send(
27 | urlRequest: URLRequest,
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:27:21: error: cannot find type 'URLRequest' in scope
25 | extension URLSession: Transport {
26 | public func send(
27 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
28 | delegate: URLSessionTaskDelegate?
29 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:28:19: error: cannot find type 'URLSessionTaskDelegate' in scope
26 | public func send(
27 | urlRequest: URLRequest,
28 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
29 | ) async throws -> (Data, HTTPURLResponse) {
30 | let (data, response) = try await self.data(for: urlRequest, delegate: delegate)
[#NominalTypes]: <https://docs.swift.org/compiler/documentation/diagnostics/nominal-types>
[26/67] Compiling Blocks Transport.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:10:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
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/Blocks/Transport/MockTransport.swift:12:74: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
10 | let response: HTTPURLResponse?
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
13 | self.data = data
14 | self.response = response
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/Blocks/Transport/MockTransport.swift:18:21: error: cannot find type 'URLRequest' in scope
16 |
17 | public func send(
18 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:19:21: error: cannot find type 'URLSessionTaskDelegate' in scope
17 | public func send(
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:20:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
21 | let actualResponse: HTTPURLResponse
22 |
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/Blocks/Transport/MockTransport.swift:10:9: error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:21:29: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | if let response {
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/Blocks/Transport/MockTransport.swift:27:38: error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
25 | } else {
26 | guard let fallbackURL = URL(string: "https://foo.tld/bar"),
27 | let httpResponse = HTTPURLResponse(
| `- error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:30:36: error: 'nil' requires a contextual type
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
30 | httpVersion: nil,
| `- error: 'nil' requires a contextual type
31 | headerFields: nil
32 | )
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:31:37: error: 'nil' requires a contextual type
29 | statusCode: 200,
30 | httpVersion: nil,
31 | headerFields: nil
| `- error: 'nil' requires a contextual type
32 | )
33 | else {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:45:21: error: cannot find type 'URLRequest' in scope
43 | /// - Throws: An error if the request fails after retry attempts.
44 | public func send(
45 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:46:19: error: cannot find type 'URLSessionTaskDelegate' in scope
44 | public func send(
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
47 | ) async throws -> (Data, HTTPURLResponse) {
48 | var nbAttempts = 0
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:47:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
48 | var nbAttempts = 0
49 | var errors: [Error] = []
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/Blocks/Transport/StatusCodeCheckingTransport.swift:75:21: error: cannot find type 'URLRequest' in scope
73 | /// - Throws: A `WrongStatusCodeError` if the actual status code does not match the expected range.
74 | public func send(
75 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:76:19: error: cannot find type 'URLSessionTaskDelegate' in scope
74 | public func send(
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
77 | ) async throws -> (Data, HTTPURLResponse) {
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:77:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
79 |
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:26: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 |
107 | /// The response body data associated with the error.
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/Blocks/Transport/StatusCodeCheckingTransport.swift:115:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
113 | /// - response: The HTTP URL response associated with the error.
114 | /// - responseBody: The response body data associated with the error.
115 | public init(statusCode: Int, response: HTTPURLResponse?, responseBody: Data?) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
116 | self.statusCode = statusCode
117 | self.response = response
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:16: warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
106 |
107 | /// The response body data associated with the error.
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:13:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 | }
15 |
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/Blocks/Transport/Transport.swift:25:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
23 | @available(iOS 15.0.0, *)
24 | @available(macOS 12.0, *)
25 | extension URLSession: Transport {
| `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
26 | public func send(
27 | urlRequest: URLRequest,
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:27:21: error: cannot find type 'URLRequest' in scope
25 | extension URLSession: Transport {
26 | public func send(
27 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
28 | delegate: URLSessionTaskDelegate?
29 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:28:19: error: cannot find type 'URLSessionTaskDelegate' in scope
26 | public func send(
27 | urlRequest: URLRequest,
28 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
29 | ) async throws -> (Data, HTTPURLResponse) {
30 | let (data, response) = try await self.data(for: urlRequest, delegate: delegate)
[#NominalTypes]: <https://docs.swift.org/compiler/documentation/diagnostics/nominal-types>
[27/67] Compiling Blocks TransportError.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:10:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
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/Blocks/Transport/MockTransport.swift:12:74: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
10 | let response: HTTPURLResponse?
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
13 | self.data = data
14 | self.response = response
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/Blocks/Transport/MockTransport.swift:18:21: error: cannot find type 'URLRequest' in scope
16 |
17 | public func send(
18 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:19:21: error: cannot find type 'URLSessionTaskDelegate' in scope
17 | public func send(
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:20:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
18 | urlRequest: URLRequest,
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
21 | let actualResponse: HTTPURLResponse
22 |
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/Blocks/Transport/MockTransport.swift:10:9: error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
8 | public final class MockTransport: Transport {
9 | let data: Data
10 | let response: HTTPURLResponse?
| `- error: stored property 'response' of 'Sendable'-conforming class 'MockTransport' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
11 |
12 | public init(data: Data = Data("Hello MockTransport".utf8), response: HTTPURLResponse? = nil) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:21:29: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | delegate _: URLSessionTaskDelegate?
20 | ) async throws -> (Data, HTTPURLResponse) {
21 | let actualResponse: HTTPURLResponse
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | if let response {
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/Blocks/Transport/MockTransport.swift:27:38: error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
25 | } else {
26 | guard let fallbackURL = URL(string: "https://foo.tld/bar"),
27 | let httpResponse = HTTPURLResponse(
| `- error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:30:36: error: 'nil' requires a contextual type
28 | url: urlRequest.url ?? fallbackURL,
29 | statusCode: 200,
30 | httpVersion: nil,
| `- error: 'nil' requires a contextual type
31 | headerFields: nil
32 | )
/host/spi-builder-workspace/Sources/Blocks/Transport/MockTransport.swift:31:37: error: 'nil' requires a contextual type
29 | statusCode: 200,
30 | httpVersion: nil,
31 | headerFields: nil
| `- error: 'nil' requires a contextual type
32 | )
33 | else {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:45:21: error: cannot find type 'URLRequest' in scope
43 | /// - Throws: An error if the request fails after retry attempts.
44 | public func send(
45 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:46:19: error: cannot find type 'URLSessionTaskDelegate' in scope
44 | public func send(
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
47 | ) async throws -> (Data, HTTPURLResponse) {
48 | var nbAttempts = 0
/host/spi-builder-workspace/Sources/Blocks/Transport/RetryTransport.swift:47:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
45 | urlRequest: URLRequest,
46 | delegate: URLSessionTaskDelegate?
47 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
48 | var nbAttempts = 0
49 | var errors: [Error] = []
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/Blocks/Transport/StatusCodeCheckingTransport.swift:75:21: error: cannot find type 'URLRequest' in scope
73 | /// - Throws: A `WrongStatusCodeError` if the actual status code does not match the expected range.
74 | public func send(
75 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:76:19: error: cannot find type 'URLSessionTaskDelegate' in scope
74 | public func send(
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
77 | ) async throws -> (Data, HTTPURLResponse) {
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
/host/spi-builder-workspace/Sources/Blocks/Transport/StatusCodeCheckingTransport.swift:77:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | urlRequest: URLRequest,
76 | delegate: URLSessionTaskDelegate?
77 | ) async throws -> (Data, HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
78 | let (data, httpResponse) = try await wrapped.send(urlRequest: urlRequest, delegate: delegate)
79 |
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:26: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 |
107 | /// The response body data associated with the error.
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/Blocks/Transport/StatusCodeCheckingTransport.swift:115:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
113 | /// - response: The HTTP URL response associated with the error.
114 | /// - responseBody: The response body data associated with the error.
115 | public init(statusCode: Int, response: HTTPURLResponse?, responseBody: Data?) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
116 | self.statusCode = statusCode
117 | self.response = response
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/Blocks/Transport/StatusCodeCheckingTransport.swift:105:16: warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
103 |
104 | /// The HTTP URL response associated with the error.
105 | public let response: HTTPURLResponse?
| `- warning: stored property 'response' of 'Sendable'-conforming struct 'WrongStatusCodeError' contains non-Sendable type 'HTTPURLResponse' (aka 'AnyObject')
106 |
107 | /// The response body data associated with the error.
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:13:30: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 | }
15 |
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/Blocks/Transport/Transport.swift:25:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
23 | @available(iOS 15.0.0, *)
24 | @available(macOS 12.0, *)
25 | extension URLSession: Transport {
| `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended [#NominalTypes]
26 | public func send(
27 | urlRequest: URLRequest,
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:27:21: error: cannot find type 'URLRequest' in scope
25 | extension URLSession: Transport {
26 | public func send(
27 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
28 | delegate: URLSessionTaskDelegate?
29 | ) async throws -> (Data, HTTPURLResponse) {
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:28:19: error: cannot find type 'URLSessionTaskDelegate' in scope
26 | public func send(
27 | urlRequest: URLRequest,
28 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
29 | ) async throws -> (Data, HTTPURLResponse) {
30 | let (data, response) = try await self.data(for: urlRequest, delegate: delegate)
[#NominalTypes]: <https://docs.swift.org/compiler/documentation/diagnostics/nominal-types>
[28/67] Compiling Blocks Pasteboard.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
[29/67] Compiling Blocks PlainDate.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
[30/67] Compiling Blocks QueryCache.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
[31/67] Compiling Blocks QueryClient.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
[32/67] Compiling Blocks QueryError.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
[33/67] Compiling Blocks QueryKey.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
[34/67] Compiling Blocks QueryOptions.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
[35/67] Compiling Blocks QueryState.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
[36/67] Compiling Blocks JSONEncoder.swift
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:35: error: cannot find 'applyingTransform' in scope
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot find 'applyingTransform' in scope
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:54: error: cannot infer contextual base in reference to member 'toUnicodeName'
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot infer contextual base in reference to member 'toUnicodeName'
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
[37/67] Compiling Blocks StringProtocol+Filename.swift
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:35: error: cannot find 'applyingTransform' in scope
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot find 'applyingTransform' in scope
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:54: error: cannot infer contextual base in reference to member 'toUnicodeName'
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot infer contextual base in reference to member 'toUnicodeName'
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
[38/67] Compiling Blocks StringProtocol.swift
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:35: error: cannot find 'applyingTransform' in scope
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot find 'applyingTransform' in scope
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:54: error: cannot infer contextual base in reference to member 'toUnicodeName'
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot infer contextual base in reference to member 'toUnicodeName'
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
[39/67] Compiling Blocks URLComponents.swift
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:35: error: cannot find 'applyingTransform' in scope
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot find 'applyingTransform' in scope
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:54: error: cannot infer contextual base in reference to member 'toUnicodeName'
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot infer contextual base in reference to member 'toUnicodeName'
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
[40/67] Compiling Blocks CompressionPreset.swift
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:35: error: cannot find 'applyingTransform' in scope
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot find 'applyingTransform' in scope
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:54: error: cannot infer contextual base in reference to member 'toUnicodeName'
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot infer contextual base in reference to member 'toUnicodeName'
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
[41/67] Compiling Blocks DocumentDetector.swift
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:35: error: cannot find 'applyingTransform' in scope
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot find 'applyingTransform' in scope
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:54: error: cannot infer contextual base in reference to member 'toUnicodeName'
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot infer contextual base in reference to member 'toUnicodeName'
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
[42/67] Compiling Blocks ImageCompressor.swift
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:35: error: cannot find 'applyingTransform' in scope
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot find 'applyingTransform' in scope
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:54: error: cannot infer contextual base in reference to member 'toUnicodeName'
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot infer contextual base in reference to member 'toUnicodeName'
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
[43/67] Compiling Blocks ImageResizer.swift
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:35: error: cannot find 'applyingTransform' in scope
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot find 'applyingTransform' in scope
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
/host/spi-builder-workspace/Sources/Blocks/Extensions/StringProtocol.swift:38:54: error: cannot infer contextual base in reference to member 'toUnicodeName'
36 |
37 | if !isEmpty, slug.isEmpty {
38 | if let extendedSelf = applyingTransform(.toUnicodeName, reverse: false)?
| `- error: cannot infer contextual base in reference to member 'toUnicodeName'
39 | .replacingOccurrences(of: "\\N", with: ""), self != extendedSelf {
40 | return extendedSelf.slugify()
[44/67] Compiling Blocks ICalendar.swift
[45/67] Compiling Blocks CopyUtils.swift
[46/67] Compiling Blocks DataFormatter.swift
[47/67] Compiling Blocks Bundle.swift
[48/67] Compiling Blocks Calendar.swift
[49/67] Compiling Blocks Data.swift
[50/67] Compiling Blocks Font.swift
[51/67] Compiling Blocks JSONDecoder.swift
[52/67] Compiling Blocks GenericPasswordKeychainItem.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:30:25: error: cannot find type 'URLRequest' in scope
28 |
29 | /// The request for this endpoint
30 | public var request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
31 |
32 | /// This is used to (try to) parse a response into an `A`.
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:33:34: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 |
32 | /// This is used to (try to) parse a response into an `A`.
33 | var parse: @Sendable (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |
35 | /// Transforms the result
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/Blocks/Transport/Endpoint.swift:68:44: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
66 | headers: [URLRequestHeaderItem] = [],
67 | query: [URLQueryItem] = [],
68 | parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
69 | ) {
70 | var requestUrl: URL
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/Blocks/Transport/Endpoint.swift:103:26: error: cannot find type 'URLRequest' in scope
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: cannot find type 'URLRequest' in scope
104 | self.request = request
105 | self.parse = parse
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:103:73: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 | self.request = request
105 | self.parse = parse
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/Blocks/Transport/Endpoint.swift:37:20: error: extraneous argument label 'request:' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: extraneous argument label 'request:' in call
38 | parse(value, response).map(f)
39 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:37:37: error: missing argument for parameter 'url' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: missing argument for parameter 'url' in call
38 | parse(value, response).map(f)
39 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:20: error: extraneous argument label 'request:' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: extraneous argument label 'request:' in call
45 | parse(data, response).flatMap(transform)
46 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:37: error: missing argument for parameter 'url' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: missing argument for parameter 'url' in call
45 | parse(data, response).flatMap(transform)
46 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:79:19: error: cannot find 'URLRequest' in scope
77 | requestUrl = comps.url!
78 | }
79 | request = URLRequest(url: requestUrl)
| `- error: cannot find 'URLRequest' in scope
80 | if let a = accept {
81 | request.setValue(a.rawValue, forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:191:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
189 | ) {
190 | self.init(method, url: url, accept: accept, body: nil, headers: headers, query: query) { data, _ in
191 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
192 | guard let dat = data else { throw NoDataError() }
193 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:221:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
219 | let b = body.map { try! encoder.encode($0) }
220 | self.init(method, url: url, accept: accept, contentType: .json, body: b, headers: headers, query: query) { data, _ in
221 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
222 | guard let dat = data else { throw NoDataError() }
223 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:245:91: error: 'nil' requires a contextual type
243 | @discardableResult
244 | func load<A>(_ endpoint: Endpoint<A>) async throws -> A {
245 | let (data, httpResponse) = try await send(urlRequest: endpoint.request, delegate: nil)
| `- error: 'nil' requires a contextual type
246 | let result = endpoint.parse(data, httpResponse)
247 | return try result.get()
[#SendableMetatypes]: <https://docs.swift.org/compiler/documentation/diagnostics/sendable-metatypes>
[53/67] Compiling Blocks PKCE.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:30:25: error: cannot find type 'URLRequest' in scope
28 |
29 | /// The request for this endpoint
30 | public var request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
31 |
32 | /// This is used to (try to) parse a response into an `A`.
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:33:34: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 |
32 | /// This is used to (try to) parse a response into an `A`.
33 | var parse: @Sendable (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |
35 | /// Transforms the result
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/Blocks/Transport/Endpoint.swift:68:44: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
66 | headers: [URLRequestHeaderItem] = [],
67 | query: [URLQueryItem] = [],
68 | parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
69 | ) {
70 | var requestUrl: URL
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/Blocks/Transport/Endpoint.swift:103:26: error: cannot find type 'URLRequest' in scope
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: cannot find type 'URLRequest' in scope
104 | self.request = request
105 | self.parse = parse
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:103:73: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 | self.request = request
105 | self.parse = parse
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/Blocks/Transport/Endpoint.swift:37:20: error: extraneous argument label 'request:' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: extraneous argument label 'request:' in call
38 | parse(value, response).map(f)
39 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:37:37: error: missing argument for parameter 'url' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: missing argument for parameter 'url' in call
38 | parse(value, response).map(f)
39 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:20: error: extraneous argument label 'request:' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: extraneous argument label 'request:' in call
45 | parse(data, response).flatMap(transform)
46 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:37: error: missing argument for parameter 'url' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: missing argument for parameter 'url' in call
45 | parse(data, response).flatMap(transform)
46 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:79:19: error: cannot find 'URLRequest' in scope
77 | requestUrl = comps.url!
78 | }
79 | request = URLRequest(url: requestUrl)
| `- error: cannot find 'URLRequest' in scope
80 | if let a = accept {
81 | request.setValue(a.rawValue, forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:191:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
189 | ) {
190 | self.init(method, url: url, accept: accept, body: nil, headers: headers, query: query) { data, _ in
191 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
192 | guard let dat = data else { throw NoDataError() }
193 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:221:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
219 | let b = body.map { try! encoder.encode($0) }
220 | self.init(method, url: url, accept: accept, contentType: .json, body: b, headers: headers, query: query) { data, _ in
221 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
222 | guard let dat = data else { throw NoDataError() }
223 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:245:91: error: 'nil' requires a contextual type
243 | @discardableResult
244 | func load<A>(_ endpoint: Endpoint<A>) async throws -> A {
245 | let (data, httpResponse) = try await send(urlRequest: endpoint.request, delegate: nil)
| `- error: 'nil' requires a contextual type
246 | let result = endpoint.parse(data, httpResponse)
247 | return try result.get()
[#SendableMetatypes]: <https://docs.swift.org/compiler/documentation/diagnostics/sendable-metatypes>
[54/67] Compiling Blocks SecurityError.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:30:25: error: cannot find type 'URLRequest' in scope
28 |
29 | /// The request for this endpoint
30 | public var request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
31 |
32 | /// This is used to (try to) parse a response into an `A`.
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:33:34: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 |
32 | /// This is used to (try to) parse a response into an `A`.
33 | var parse: @Sendable (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |
35 | /// Transforms the result
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/Blocks/Transport/Endpoint.swift:68:44: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
66 | headers: [URLRequestHeaderItem] = [],
67 | query: [URLQueryItem] = [],
68 | parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
69 | ) {
70 | var requestUrl: URL
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/Blocks/Transport/Endpoint.swift:103:26: error: cannot find type 'URLRequest' in scope
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: cannot find type 'URLRequest' in scope
104 | self.request = request
105 | self.parse = parse
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:103:73: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 | self.request = request
105 | self.parse = parse
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/Blocks/Transport/Endpoint.swift:37:20: error: extraneous argument label 'request:' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: extraneous argument label 'request:' in call
38 | parse(value, response).map(f)
39 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:37:37: error: missing argument for parameter 'url' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: missing argument for parameter 'url' in call
38 | parse(value, response).map(f)
39 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:20: error: extraneous argument label 'request:' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: extraneous argument label 'request:' in call
45 | parse(data, response).flatMap(transform)
46 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:37: error: missing argument for parameter 'url' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: missing argument for parameter 'url' in call
45 | parse(data, response).flatMap(transform)
46 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:79:19: error: cannot find 'URLRequest' in scope
77 | requestUrl = comps.url!
78 | }
79 | request = URLRequest(url: requestUrl)
| `- error: cannot find 'URLRequest' in scope
80 | if let a = accept {
81 | request.setValue(a.rawValue, forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:191:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
189 | ) {
190 | self.init(method, url: url, accept: accept, body: nil, headers: headers, query: query) { data, _ in
191 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
192 | guard let dat = data else { throw NoDataError() }
193 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:221:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
219 | let b = body.map { try! encoder.encode($0) }
220 | self.init(method, url: url, accept: accept, contentType: .json, body: b, headers: headers, query: query) { data, _ in
221 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
222 | guard let dat = data else { throw NoDataError() }
223 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:245:91: error: 'nil' requires a contextual type
243 | @discardableResult
244 | func load<A>(_ endpoint: Endpoint<A>) async throws -> A {
245 | let (data, httpResponse) = try await send(urlRequest: endpoint.request, delegate: nil)
| `- error: 'nil' requires a contextual type
246 | let result = endpoint.parse(data, httpResponse)
247 | return try result.get()
[#SendableMetatypes]: <https://docs.swift.org/compiler/documentation/diagnostics/sendable-metatypes>
[55/67] Compiling Blocks SecurityUtils.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:30:25: error: cannot find type 'URLRequest' in scope
28 |
29 | /// The request for this endpoint
30 | public var request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
31 |
32 | /// This is used to (try to) parse a response into an `A`.
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:33:34: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 |
32 | /// This is used to (try to) parse a response into an `A`.
33 | var parse: @Sendable (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |
35 | /// Transforms the result
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/Blocks/Transport/Endpoint.swift:68:44: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
66 | headers: [URLRequestHeaderItem] = [],
67 | query: [URLQueryItem] = [],
68 | parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
69 | ) {
70 | var requestUrl: URL
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/Blocks/Transport/Endpoint.swift:103:26: error: cannot find type 'URLRequest' in scope
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: cannot find type 'URLRequest' in scope
104 | self.request = request
105 | self.parse = parse
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:103:73: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 | self.request = request
105 | self.parse = parse
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/Blocks/Transport/Endpoint.swift:37:20: error: extraneous argument label 'request:' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: extraneous argument label 'request:' in call
38 | parse(value, response).map(f)
39 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:37:37: error: missing argument for parameter 'url' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: missing argument for parameter 'url' in call
38 | parse(value, response).map(f)
39 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:20: error: extraneous argument label 'request:' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: extraneous argument label 'request:' in call
45 | parse(data, response).flatMap(transform)
46 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:37: error: missing argument for parameter 'url' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: missing argument for parameter 'url' in call
45 | parse(data, response).flatMap(transform)
46 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:79:19: error: cannot find 'URLRequest' in scope
77 | requestUrl = comps.url!
78 | }
79 | request = URLRequest(url: requestUrl)
| `- error: cannot find 'URLRequest' in scope
80 | if let a = accept {
81 | request.setValue(a.rawValue, forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:191:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
189 | ) {
190 | self.init(method, url: url, accept: accept, body: nil, headers: headers, query: query) { data, _ in
191 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
192 | guard let dat = data else { throw NoDataError() }
193 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:221:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
219 | let b = body.map { try! encoder.encode($0) }
220 | self.init(method, url: url, accept: accept, contentType: .json, body: b, headers: headers, query: query) { data, _ in
221 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
222 | guard let dat = data else { throw NoDataError() }
223 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:245:91: error: 'nil' requires a contextual type
243 | @discardableResult
244 | func load<A>(_ endpoint: Endpoint<A>) async throws -> A {
245 | let (data, httpResponse) = try await send(urlRequest: endpoint.request, delegate: nil)
| `- error: 'nil' requires a contextual type
246 | let result = endpoint.parse(data, httpResponse)
247 | return try result.get()
[#SendableMetatypes]: <https://docs.swift.org/compiler/documentation/diagnostics/sendable-metatypes>
[56/67] Compiling Blocks SimpleMessageError.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:30:25: error: cannot find type 'URLRequest' in scope
28 |
29 | /// The request for this endpoint
30 | public var request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
31 |
32 | /// This is used to (try to) parse a response into an `A`.
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:33:34: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 |
32 | /// This is used to (try to) parse a response into an `A`.
33 | var parse: @Sendable (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |
35 | /// Transforms the result
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/Blocks/Transport/Endpoint.swift:68:44: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
66 | headers: [URLRequestHeaderItem] = [],
67 | query: [URLQueryItem] = [],
68 | parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
69 | ) {
70 | var requestUrl: URL
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/Blocks/Transport/Endpoint.swift:103:26: error: cannot find type 'URLRequest' in scope
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: cannot find type 'URLRequest' in scope
104 | self.request = request
105 | self.parse = parse
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:103:73: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 | self.request = request
105 | self.parse = parse
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/Blocks/Transport/Endpoint.swift:37:20: error: extraneous argument label 'request:' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: extraneous argument label 'request:' in call
38 | parse(value, response).map(f)
39 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:37:37: error: missing argument for parameter 'url' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: missing argument for parameter 'url' in call
38 | parse(value, response).map(f)
39 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:20: error: extraneous argument label 'request:' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: extraneous argument label 'request:' in call
45 | parse(data, response).flatMap(transform)
46 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:37: error: missing argument for parameter 'url' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: missing argument for parameter 'url' in call
45 | parse(data, response).flatMap(transform)
46 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:79:19: error: cannot find 'URLRequest' in scope
77 | requestUrl = comps.url!
78 | }
79 | request = URLRequest(url: requestUrl)
| `- error: cannot find 'URLRequest' in scope
80 | if let a = accept {
81 | request.setValue(a.rawValue, forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:191:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
189 | ) {
190 | self.init(method, url: url, accept: accept, body: nil, headers: headers, query: query) { data, _ in
191 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
192 | guard let dat = data else { throw NoDataError() }
193 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:221:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
219 | let b = body.map { try! encoder.encode($0) }
220 | self.init(method, url: url, accept: accept, contentType: .json, body: b, headers: headers, query: query) { data, _ in
221 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
222 | guard let dat = data else { throw NoDataError() }
223 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:245:91: error: 'nil' requires a contextual type
243 | @discardableResult
244 | func load<A>(_ endpoint: Endpoint<A>) async throws -> A {
245 | let (data, httpResponse) = try await send(urlRequest: endpoint.request, delegate: nil)
| `- error: 'nil' requires a contextual type
246 | let result = endpoint.parse(data, httpResponse)
247 | return try result.get()
[#SendableMetatypes]: <https://docs.swift.org/compiler/documentation/diagnostics/sendable-metatypes>
[57/67] Compiling Blocks Sitemap.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:30:25: error: cannot find type 'URLRequest' in scope
28 |
29 | /// The request for this endpoint
30 | public var request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
31 |
32 | /// This is used to (try to) parse a response into an `A`.
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:33:34: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 |
32 | /// This is used to (try to) parse a response into an `A`.
33 | var parse: @Sendable (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |
35 | /// Transforms the result
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/Blocks/Transport/Endpoint.swift:68:44: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
66 | headers: [URLRequestHeaderItem] = [],
67 | query: [URLQueryItem] = [],
68 | parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
69 | ) {
70 | var requestUrl: URL
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/Blocks/Transport/Endpoint.swift:103:26: error: cannot find type 'URLRequest' in scope
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: cannot find type 'URLRequest' in scope
104 | self.request = request
105 | self.parse = parse
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:103:73: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 | self.request = request
105 | self.parse = parse
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/Blocks/Transport/Endpoint.swift:37:20: error: extraneous argument label 'request:' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: extraneous argument label 'request:' in call
38 | parse(value, response).map(f)
39 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:37:37: error: missing argument for parameter 'url' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: missing argument for parameter 'url' in call
38 | parse(value, response).map(f)
39 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:20: error: extraneous argument label 'request:' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: extraneous argument label 'request:' in call
45 | parse(data, response).flatMap(transform)
46 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:37: error: missing argument for parameter 'url' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: missing argument for parameter 'url' in call
45 | parse(data, response).flatMap(transform)
46 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:79:19: error: cannot find 'URLRequest' in scope
77 | requestUrl = comps.url!
78 | }
79 | request = URLRequest(url: requestUrl)
| `- error: cannot find 'URLRequest' in scope
80 | if let a = accept {
81 | request.setValue(a.rawValue, forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:191:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
189 | ) {
190 | self.init(method, url: url, accept: accept, body: nil, headers: headers, query: query) { data, _ in
191 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
192 | guard let dat = data else { throw NoDataError() }
193 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:221:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
219 | let b = body.map { try! encoder.encode($0) }
220 | self.init(method, url: url, accept: accept, contentType: .json, body: b, headers: headers, query: query) { data, _ in
221 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
222 | guard let dat = data else { throw NoDataError() }
223 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:245:91: error: 'nil' requires a contextual type
243 | @discardableResult
244 | func load<A>(_ endpoint: Endpoint<A>) async throws -> A {
245 | let (data, httpResponse) = try await send(urlRequest: endpoint.request, delegate: nil)
| `- error: 'nil' requires a contextual type
246 | let result = endpoint.parse(data, httpResponse)
247 | return try result.get()
[#SendableMetatypes]: <https://docs.swift.org/compiler/documentation/diagnostics/sendable-metatypes>
[58/67] Compiling Blocks Endpoint.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:30:25: error: cannot find type 'URLRequest' in scope
28 |
29 | /// The request for this endpoint
30 | public var request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
31 |
32 | /// This is used to (try to) parse a response into an `A`.
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:33:34: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 |
32 | /// This is used to (try to) parse a response into an `A`.
33 | var parse: @Sendable (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |
35 | /// Transforms the result
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/Blocks/Transport/Endpoint.swift:68:44: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
66 | headers: [URLRequestHeaderItem] = [],
67 | query: [URLQueryItem] = [],
68 | parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
69 | ) {
70 | var requestUrl: URL
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/Blocks/Transport/Endpoint.swift:103:26: error: cannot find type 'URLRequest' in scope
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: cannot find type 'URLRequest' in scope
104 | self.request = request
105 | self.parse = parse
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:103:73: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 | self.request = request
105 | self.parse = parse
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/Blocks/Transport/Endpoint.swift:37:20: error: extraneous argument label 'request:' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: extraneous argument label 'request:' in call
38 | parse(value, response).map(f)
39 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:37:37: error: missing argument for parameter 'url' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: missing argument for parameter 'url' in call
38 | parse(value, response).map(f)
39 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:20: error: extraneous argument label 'request:' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: extraneous argument label 'request:' in call
45 | parse(data, response).flatMap(transform)
46 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:37: error: missing argument for parameter 'url' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: missing argument for parameter 'url' in call
45 | parse(data, response).flatMap(transform)
46 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:79:19: error: cannot find 'URLRequest' in scope
77 | requestUrl = comps.url!
78 | }
79 | request = URLRequest(url: requestUrl)
| `- error: cannot find 'URLRequest' in scope
80 | if let a = accept {
81 | request.setValue(a.rawValue, forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:191:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
189 | ) {
190 | self.init(method, url: url, accept: accept, body: nil, headers: headers, query: query) { data, _ in
191 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
192 | guard let dat = data else { throw NoDataError() }
193 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:221:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
219 | let b = body.map { try! encoder.encode($0) }
220 | self.init(method, url: url, accept: accept, contentType: .json, body: b, headers: headers, query: query) { data, _ in
221 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
222 | guard let dat = data else { throw NoDataError() }
223 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:245:91: error: 'nil' requires a contextual type
243 | @discardableResult
244 | func load<A>(_ endpoint: Endpoint<A>) async throws -> A {
245 | let (data, httpResponse) = try await send(urlRequest: endpoint.request, delegate: nil)
| `- error: 'nil' requires a contextual type
246 | let result = endpoint.parse(data, httpResponse)
247 | return try result.get()
[#SendableMetatypes]: <https://docs.swift.org/compiler/documentation/diagnostics/sendable-metatypes>
[59/67] Compiling Blocks LoggingTransport.swift
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:30:25: error: cannot find type 'URLRequest' in scope
28 |
29 | /// The request for this endpoint
30 | public var request: URLRequest
| `- error: cannot find type 'URLRequest' in scope
31 |
32 | /// This is used to (try to) parse a response into an `A`.
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:33:34: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 |
32 | /// This is used to (try to) parse a response into an `A`.
33 | var parse: @Sendable (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |
35 | /// Transforms the result
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/Blocks/Transport/Endpoint.swift:68:44: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
66 | headers: [URLRequestHeaderItem] = [],
67 | query: [URLQueryItem] = [],
68 | parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
69 | ) {
70 | var requestUrl: URL
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/Blocks/Transport/Endpoint.swift:103:26: error: cannot find type 'URLRequest' in scope
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: cannot find type 'URLRequest' in scope
104 | self.request = request
105 | self.parse = parse
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:103:73: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
101 | /// - expectedStatusCode: the status code that's expected. If this returns false for a given status code, parsing fails.
102 | /// - parse: this converts a response into an `A`.
103 | public init(request: URLRequest, parse: @Sendable @escaping (Data?, URLResponse?) -> Result<A, Error>) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 | self.request = request
105 | self.parse = parse
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/Blocks/Transport/Endpoint.swift:37:20: error: extraneous argument label 'request:' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: extraneous argument label 'request:' in call
38 | parse(value, response).map(f)
39 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:37:37: error: missing argument for parameter 'url' in call
35 | /// Transforms the result
36 | public func map<B>(_ f: @Sendable @escaping (A) -> B) -> Endpoint<B> {
37 | Endpoint<B>(request: request, parse: { value, response in
| `- error: missing argument for parameter 'url' in call
38 | parse(value, response).map(f)
39 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:20: error: extraneous argument label 'request:' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: extraneous argument label 'request:' in call
45 | parse(data, response).flatMap(transform)
46 | })
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:44:37: error: missing argument for parameter 'url' in call
42 | /// Transforms the result
43 | public func compactMap<B>(_ transform: @Sendable @escaping (A) -> Result<B, Error>) -> Endpoint<B> {
44 | Endpoint<B>(request: request, parse: { data, response in
| `- error: missing argument for parameter 'url' in call
45 | parse(data, response).flatMap(transform)
46 | })
:
58 | /// - query: query parameters to append to the url
59 | /// - parse: this converts a response into an `A`.
60 | public init(
| `- note: 'init(_:url:accept:contentType:body:headers:query:parse:)' declared here
61 | _ method: Method,
62 | url: URL,
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:79:19: error: cannot find 'URLRequest' in scope
77 | requestUrl = comps.url!
78 | }
79 | request = URLRequest(url: requestUrl)
| `- error: cannot find 'URLRequest' in scope
80 | if let a = accept {
81 | request.setValue(a.rawValue, forHTTPHeaderField: "Accept")
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:191:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
189 | ) {
190 | self.init(method, url: url, accept: accept, body: nil, headers: headers, query: query) { data, _ in
191 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
192 | guard let dat = data else { throw NoDataError() }
193 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:221:13: warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
219 | let b = body.map { try! encoder.encode($0) }
220 | self.init(method, url: url, accept: accept, contentType: .json, body: b, headers: headers, query: query) { data, _ in
221 | Result {
| `- warning: capture of non-Sendable type 'A.Type' in an isolated closure [#SendableMetatypes]
222 | guard let dat = data else { throw NoDataError() }
223 | return try decoder.decode(A.self, from: dat)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:11:21: error: cannot find type 'URLRequest' in scope
9 | public protocol Transport: Sendable {
10 | func send(
11 | urlRequest: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
12 | delegate: URLSessionTaskDelegate?
13 | ) async throws -> (Data, HTTPURLResponse)
/host/spi-builder-workspace/Sources/Blocks/Transport/Transport.swift:12:19: error: cannot find type 'URLSessionTaskDelegate' in scope
10 | func send(
11 | urlRequest: URLRequest,
12 | delegate: URLSessionTaskDelegate?
| `- error: cannot find type 'URLSessionTaskDelegate' in scope
13 | ) async throws -> (Data, HTTPURLResponse)
14 | }
/host/spi-builder-workspace/Sources/Blocks/Transport/Endpoint.swift:245:91: error: 'nil' requires a contextual type
243 | @discardableResult
244 | func load<A>(_ endpoint: Endpoint<A>) async throws -> A {
245 | let (data, httpResponse) = try await send(urlRequest: endpoint.request, delegate: nil)
| `- error: 'nil' requires a contextual type
246 | let result = endpoint.parse(data, httpResponse)
247 | return try result.get()
[#SendableMetatypes]: <https://docs.swift.org/compiler/documentation/diagnostics/sendable-metatypes>
[60/67] Compiling Blocks ImageSource.swift
[61/67] Compiling Blocks ImagingError.swift
[62/67] Compiling Blocks NetworkConditionMonitor.swift
[63/67] Compiling Blocks JSON.swift
[64/67] Compiling Blocks JavaScriptISO8601DateFormatter.swift
[65/67] Compiling Blocks Arithmetic.swift
[66/67] Compiling Blocks PackageDump.swift
[67/67] Compiling Blocks PrivateIPAddresses.swift
BUILD FAILURE 6.2 wasm