The Swift Package Index logo.Swift Package Index

Build Information

Failed to build AdyenNetworking, reference develop (729258), with Swift 6.1 for Linux on 22 Jul 2025 11:23:18 UTC.

Build Command

bash -c docker run --pull=always --rm -v "checkouts-4606859-0":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:basic-6.1-latest swift build --triple x86_64-unknown-linux-gnu 2>&1

Build Log

    |                             `- error: cannot find type 'URLSessionDelegate' in scope
130 |     ) {
131 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:125:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
123 |     internal init(
124 |         apiContext: AnyAPIContext,
125 |         urlSession: URLSession,
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
126 |         coder: AnyCoder = Coder(),
127 |         debugLogger: any DebugLogging = DebugLogger(),
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:196:73: error: cannot find type 'URLRequest' in scope
194 |     }
195 |
196 |     private func buildUrlRequest<R: Request>(from request: R) throws -> URLRequest {
    |                                                                         `- error: cannot find type 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:269:46: error: cannot find type 'URLRequest' in scope
267 |     }
268 |
269 |     private func log<R: Request>(urlRequest: URLRequest, request: R) {
    |                                              `- error: cannot find type 'URLRequest' in scope
270 |         logger.print("---- Request (/\(request.path)) ----")
271 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:323:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
321 |
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
324 |         let config = URLSessionConfiguration.ephemeral
325 |         config.urlCache = nil
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:83: error: cannot find type 'URLRequest' in scope
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                                                   `- error: cannot find type 'URLRequest' in scope
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:53: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                     `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
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/AdyenNetworking/APIClient/APIClient.swift:441:57: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
439 |     }
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
    |                                                         `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
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/AdyenNetworking/Helpers/Logging/Logging.swift:12:23: warning: static property 'isEnabled' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
10 | public enum Logging {
11 |     /// Indicates whether to enable printing to the console.
12 |     public static var isEnabled: Bool = false
   |                       |- warning: static property 'isEnabled' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
   |                       |- note: convert 'isEnabled' to a 'let' constant to make 'Sendable' shared state immutable
   |                       |- note: add '@MainActor' to make static property 'isEnabled' part of global actor 'MainActor'
   |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
13 | }
14 |
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:16:42: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 |     internal let headers: [String: String]
15 |
16 |     internal init(data: Data?, response: URLResponse?) throws {
   |                                          `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:36:40: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |     internal let headers: [String: String]
35 |
36 |     internal init(url: URL?, response: URLResponse?) throws {
   |                                        `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:50:10: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
48 |
49 | /// :nodoc:
50 | internal extension URLSession {
   |          `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
51 |
52 |     /// :nodoc:
[4/23] Compiling AdyenNetworking AnyCoder.swift
[5/23] Compiling AdyenNetworking AnyResponseValidator.swift
[6/23] Compiling AdyenNetworking BackoffScheduler.swift
[7/23] Compiling AdyenNetworking URLHelpers.swift
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:16:42: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 |     internal let headers: [String: String]
15 |
16 |     internal init(data: Data?, response: URLResponse?) throws {
   |                                          `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:36:40: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |     internal let headers: [String: String]
35 |
36 |     internal init(url: URL?, response: URLResponse?) throws {
   |                                        `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:50:10: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
48 |
49 | /// :nodoc:
50 | internal extension URLSession {
   |          `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
51 |
52 |     /// :nodoc:
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:18:43: warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
16 |     internal init(data: Data?, response: URLResponse?) throws {
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
   |                                           `- warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
20 |                   throw APIClientError.invalidResponse
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:18:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
16 |     internal init(data: Data?, response: URLResponse?) throws {
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
   |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
20 |                   throw APIClientError.invalidResponse
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:19:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
   |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
20 |                   throw APIClientError.invalidResponse
21 |         }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:25:40: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
23 |         self.data = data
24 |         self.headers = headers
25 |         self.statusCode = httpResponse.statusCode
   |                                        `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
26 |     }
27 | }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:38:43: warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
36 |     internal init(url: URL?, response: URLResponse?) throws {
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
   |                                           `- warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
40 |                   throw APIClientError.invalidResponse
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:38:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
36 |     internal init(url: URL?, response: URLResponse?) throws {
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
   |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
40 |                   throw APIClientError.invalidResponse
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:39:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
   |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
40 |                   throw APIClientError.invalidResponse
41 |         }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:45:40: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
43 |         self.url = url
44 |         self.headers = headers
45 |         self.statusCode = httpResponse.statusCode
   |                                        `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
46 |     }
47 | }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:54:26: error: cannot find type 'URLRequest' in scope
52 |     /// :nodoc:
53 |     func dataTask(
54 |         with urlRequest: URLRequest,
   |                          `- error: cannot find type 'URLRequest' in scope
55 |         completion: @escaping ((Result<URLSessionSuccess, Error>) -> Void)
56 |     ) -> URLSessionDataTask {
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:68:26: error: cannot find type 'URLRequest' in scope
66 |     /// :nodoc:
67 |     func downloadTask(
68 |         with urlRequest: URLRequest,
   |                          `- error: cannot find type 'URLRequest' in scope
69 |         completion: @escaping ((Result<URLSessionDownloadSuccess, Error>) -> Void)
70 |     ) -> URLSessionDownloadTask {
[8/23] Compiling AdyenNetworking URLSessionHelpers.swift
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:16:42: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 |     internal let headers: [String: String]
15 |
16 |     internal init(data: Data?, response: URLResponse?) throws {
   |                                          `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:36:40: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |     internal let headers: [String: String]
35 |
36 |     internal init(url: URL?, response: URLResponse?) throws {
   |                                        `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:50:10: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
48 |
49 | /// :nodoc:
50 | internal extension URLSession {
   |          `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
51 |
52 |     /// :nodoc:
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:18:43: warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
16 |     internal init(data: Data?, response: URLResponse?) throws {
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
   |                                           `- warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
20 |                   throw APIClientError.invalidResponse
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:18:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
16 |     internal init(data: Data?, response: URLResponse?) throws {
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
   |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
20 |                   throw APIClientError.invalidResponse
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:19:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
   |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
20 |                   throw APIClientError.invalidResponse
21 |         }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:25:40: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
23 |         self.data = data
24 |         self.headers = headers
25 |         self.statusCode = httpResponse.statusCode
   |                                        `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
26 |     }
27 | }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:38:43: warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
36 |     internal init(url: URL?, response: URLResponse?) throws {
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
   |                                           `- warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
40 |                   throw APIClientError.invalidResponse
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:38:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
36 |     internal init(url: URL?, response: URLResponse?) throws {
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
   |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
40 |                   throw APIClientError.invalidResponse
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:39:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
   |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
40 |                   throw APIClientError.invalidResponse
41 |         }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:45:40: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
43 |         self.url = url
44 |         self.headers = headers
45 |         self.statusCode = httpResponse.statusCode
   |                                        `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
46 |     }
47 | }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:54:26: error: cannot find type 'URLRequest' in scope
52 |     /// :nodoc:
53 |     func dataTask(
54 |         with urlRequest: URLRequest,
   |                          `- error: cannot find type 'URLRequest' in scope
55 |         completion: @escaping ((Result<URLSessionSuccess, Error>) -> Void)
56 |     ) -> URLSessionDataTask {
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:68:26: error: cannot find type 'URLRequest' in scope
66 |     /// :nodoc:
67 |     func downloadTask(
68 |         with urlRequest: URLRequest,
   |                          `- error: cannot find type 'URLRequest' in scope
69 |         completion: @escaping ((Result<URLSessionDownloadSuccess, Error>) -> Void)
70 |     ) -> URLSessionDownloadTask {
[9/23] Compiling AdyenNetworking Coder.swift
[10/23] Compiling AdyenNetworking DebugLogger.swift
[11/23] Compiling AdyenNetworking SimpleScheduler.swift
[12/23] Compiling AdyenNetworking UniqueAssetAPIClient.swift
[13/23] Compiling AdyenNetworking Errors.swift
[14/23] Compiling AdyenNetworking HTTPResponse.swift
[15/23] Compiling AdyenNetworking Request.swift
[16/23] Compiling AdyenNetworking RetryAPIClient.swift
[17/23] Compiling AdyenNetworking RetryOnErrorAPIClient.swift
[18/23] Compiling AdyenNetworking Scheduler.swift
[19/23] Compiling AdyenNetworking DebugLogging.swift
/host/spi-builder-workspace/AdyenNetworking/Helpers/Logging/Logging.swift:12:23: warning: static property 'isEnabled' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
10 | public enum Logging {
11 |     /// Indicates whether to enable printing to the console.
12 |     public static var isEnabled: Bool = false
   |                       |- warning: static property 'isEnabled' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
   |                       |- note: convert 'isEnabled' to a 'let' constant to make 'Sendable' shared state immutable
   |                       |- note: add '@MainActor' to make static property 'isEnabled' part of global actor 'MainActor'
   |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
13 | }
14 |
[20/23] Compiling AdyenNetworking Logging.swift
/host/spi-builder-workspace/AdyenNetworking/Helpers/Logging/Logging.swift:12:23: warning: static property 'isEnabled' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
10 | public enum Logging {
11 |     /// Indicates whether to enable printing to the console.
12 |     public static var isEnabled: Bool = false
   |                       |- warning: static property 'isEnabled' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
   |                       |- note: convert 'isEnabled' to a 'let' constant to make 'Sendable' shared state immutable
   |                       |- note: add '@MainActor' to make static property 'isEnabled' part of global actor 'MainActor'
   |                       `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
13 | }
14 |
[21/23] Compiling AdyenNetworking APIClient.swift
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:81:29: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 79 |
 80 |     /// :nodoc:
 81 |     private let urlSession: URLSession
    |                             `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 82 |
 83 |     /// Encoding and Decoding
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:109:29: error: cannot find type 'URLSessionDelegate' in scope
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
109 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
110 |     ) {
111 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:106:24: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 |     public init(
105 |         apiContext: AnyAPIContext,
106 |         configuration: URLSessionConfiguration? = nil,
    |                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:129:29: error: cannot find type 'URLSessionDelegate' in scope
127 |         debugLogger: any DebugLogging = DebugLogger(),
128 |         responseValidator: (any AnyResponseValidator)? = nil,
129 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
130 |     ) {
131 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:125:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
123 |     internal init(
124 |         apiContext: AnyAPIContext,
125 |         urlSession: URLSession,
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
126 |         coder: AnyCoder = Coder(),
127 |         debugLogger: any DebugLogging = DebugLogger(),
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:196:73: error: cannot find type 'URLRequest' in scope
194 |     }
195 |
196 |     private func buildUrlRequest<R: Request>(from request: R) throws -> URLRequest {
    |                                                                         `- error: cannot find type 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:269:46: error: cannot find type 'URLRequest' in scope
267 |     }
268 |
269 |     private func log<R: Request>(urlRequest: URLRequest, request: R) {
    |                                              `- error: cannot find type 'URLRequest' in scope
270 |         logger.print("---- Request (/\(request.path)) ----")
271 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:323:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
321 |
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
324 |         let config = URLSessionConfiguration.ephemeral
325 |         config.urlCache = nil
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:83: error: cannot find type 'URLRequest' in scope
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                                                   `- error: cannot find type 'URLRequest' in scope
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:53: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                     `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
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/AdyenNetworking/APIClient/APIClient.swift:441:57: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
439 |     }
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
    |                                                         `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
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/AdyenNetworking/APIClient/APIClient.swift:112:27: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
110 |     ) {
111 |         self.apiContext = apiContext
112 |         self.urlSession = URLSession(
    |                           `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:115:28: error: 'nil' requires a contextual type
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
115 |             delegateQueue: nil
    |                            `- error: 'nil' requires a contextual type
116 |         )
117 |         self.responseValidator = responseValidator
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:89: error: cannot infer type of closure parameter 'result' without a type annotation
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                                                                                         `- error: cannot infer type of closure parameter 'result' without a type annotation
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:146:45: error: cannot infer contextual base in reference to member 'init'
144 |                 guard let self = self else { return }
145 |                 let result = result
146 |                     .flatMap { response in .init(catching: {
    |                                             `- error: cannot infer contextual base in reference to member 'init'
147 |                         try self.handleHttpError(from: response, request: request)
148 |                         return try self.handle(response, request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:150:26: error: cannot infer key path type from context; consider explicitly specifying a root type
148 |                         return try self.handle(response, request)
149 |                     })}
150 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
151 |                     .mapError { (error) -> Error in
152 |                         switch error {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:178:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
176 |     ) where R: Request, R.ResponseType == DownloadResponse {
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
179 |                 result in
180 |                 guard let self = self else { return }
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:179:17: error: cannot infer type of closure parameter 'result' without a type annotation
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
179 |                 result in
    |                 `- error: cannot infer type of closure parameter 'result' without a type annotation
180 |                 guard let self = self else { return }
181 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:182:45: error: cannot infer contextual base in reference to member 'init'
180 |                 guard let self = self else { return }
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
    |                                             `- error: cannot infer contextual base in reference to member 'init'
183 |                     .map(\.responseBody)
184 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:183:26: error: cannot infer key path type from context; consider explicitly specifying a root type
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
183 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
184 |
185 |                 DispatchQueue.main.async {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:199:26: error: cannot find 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
199 |         var urlRequest = URLRequest(url: add(queryParameters: request.queryParameters + apiContext.queryParameters, to: url))
    |                          `- error: cannot find 'URLRequest' in scope
200 |         urlRequest.httpMethod = request.method.rawValue
201 |         urlRequest.allHTTPHeaderFields = request.headers.merging(apiContext.headers, uniquingKeysWith: { key1, _ in key1 })
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:206:9: error: no exact matches in call to instance method 'log'
204 |         }
205 |
206 |         log(urlRequest: urlRequest, request: request)
    |         `- error: no exact matches in call to instance method 'log'
207 |
208 |         return urlRequest
    :
289 |     }
290 |
291 |     private func log<R: Request>(result: URLSessionSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
292 |         logger.print("---- Response Code (/\(request.path)) ----")
293 |         logger.print(result.statusCode)
    :
300 |     }
301 |
302 |     private func log<R: Request>(result: URLSessionDownloadSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
303 |         logger.print("---- Response Code (/\(request.path)) ----")
304 |         logger.print(result.statusCode)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:324:46: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
324 |         let config = URLSessionConfiguration.ephemeral
    |                                              `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
325 |         config.urlCache = nil
326 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:328:58: error: cannot infer contextual base in reference to member 'TLSv12'
326 |
327 |         if #available(iOS 13.0, *) {
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
    |                                                          `- error: cannot infer contextual base in reference to member 'TLSv12'
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:330:51: error: cannot infer contextual base in reference to member 'tlsProtocol12'
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
    |                                                   `- error: cannot infer contextual base in reference to member 'tlsProtocol12'
331 |         }
332 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:343:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
344 |         urlResponse.url?.lastPathComponent ??
345 |         urlRequest.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:344:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
345 |         urlRequest.url?.lastPathComponent ??
346 |         "Unknown-\(UUID().uuidString).tmp"
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:389:14: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
387 |     public func perform<R>(_ request: R) async throws -> HTTPResponse<R.ResponseType> where R: Request {
388 |         let result = try await urlSession
389 |             .data(for: try buildUrlRequest(from: request)) as (data: Data, urlResponse: URLResponse)
    |              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
390 |         let httpResult = try URLSessionSuccess(data: result.data, response: result.urlResponse)
391 |         try handleHttpError(from: httpResult, request: request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:400:63: error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
398 |     ) async throws -> HTTPResponse<R.ResponseType> where R: Request, R.ResponseType == DownloadResponse {
399 |         let urlRequest = try buildUrlRequest(from: request)
400 |         let (locationUrl, urlResponse) = try await urlSession.download(for: urlRequest)
    |                                                               `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
401 |         try handleHttpErrorCodes(from: urlResponse)
402 |         let destinationUrl = try generateFileDestination(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:415:62: error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
413 |     ) async throws -> HTTPResponse<R.ResponseType> where R: AsyncDownloadRequest, R.ResponseType == DownloadResponse {
414 |         let urlRequest = try buildUrlRequest(from: request)
415 |         let (asyncBytes, urlResponse) = try await urlSession.bytes(for: urlRequest)
    |                                                              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
416 |         try handleHttpErrorCodes(from: urlResponse)
417 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
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/AdyenNetworking/APIClient/APIClient.swift:443:46: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
    |                                              `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
445 |             throw HTTPErrorResponse(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:444:39: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
    |                                       `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:447:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
447 |                 statusCode: httpResponse.statusCode,
    |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
448 |                 responseBody: EmptyErrorResponse()
449 |             )
[22/23] Compiling AdyenNetworking AnyAPIContext.swift
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:81:29: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 79 |
 80 |     /// :nodoc:
 81 |     private let urlSession: URLSession
    |                             `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 82 |
 83 |     /// Encoding and Decoding
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:109:29: error: cannot find type 'URLSessionDelegate' in scope
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
109 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
110 |     ) {
111 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:106:24: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 |     public init(
105 |         apiContext: AnyAPIContext,
106 |         configuration: URLSessionConfiguration? = nil,
    |                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:129:29: error: cannot find type 'URLSessionDelegate' in scope
127 |         debugLogger: any DebugLogging = DebugLogger(),
128 |         responseValidator: (any AnyResponseValidator)? = nil,
129 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
130 |     ) {
131 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:125:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
123 |     internal init(
124 |         apiContext: AnyAPIContext,
125 |         urlSession: URLSession,
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
126 |         coder: AnyCoder = Coder(),
127 |         debugLogger: any DebugLogging = DebugLogger(),
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:196:73: error: cannot find type 'URLRequest' in scope
194 |     }
195 |
196 |     private func buildUrlRequest<R: Request>(from request: R) throws -> URLRequest {
    |                                                                         `- error: cannot find type 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:269:46: error: cannot find type 'URLRequest' in scope
267 |     }
268 |
269 |     private func log<R: Request>(urlRequest: URLRequest, request: R) {
    |                                              `- error: cannot find type 'URLRequest' in scope
270 |         logger.print("---- Request (/\(request.path)) ----")
271 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:323:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
321 |
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
324 |         let config = URLSessionConfiguration.ephemeral
325 |         config.urlCache = nil
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:83: error: cannot find type 'URLRequest' in scope
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                                                   `- error: cannot find type 'URLRequest' in scope
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:53: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                     `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
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/AdyenNetworking/APIClient/APIClient.swift:441:57: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
439 |     }
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
    |                                                         `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
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/AdyenNetworking/APIClient/APIClient.swift:112:27: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
110 |     ) {
111 |         self.apiContext = apiContext
112 |         self.urlSession = URLSession(
    |                           `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:115:28: error: 'nil' requires a contextual type
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
115 |             delegateQueue: nil
    |                            `- error: 'nil' requires a contextual type
116 |         )
117 |         self.responseValidator = responseValidator
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:89: error: cannot infer type of closure parameter 'result' without a type annotation
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                                                                                         `- error: cannot infer type of closure parameter 'result' without a type annotation
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:146:45: error: cannot infer contextual base in reference to member 'init'
144 |                 guard let self = self else { return }
145 |                 let result = result
146 |                     .flatMap { response in .init(catching: {
    |                                             `- error: cannot infer contextual base in reference to member 'init'
147 |                         try self.handleHttpError(from: response, request: request)
148 |                         return try self.handle(response, request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:150:26: error: cannot infer key path type from context; consider explicitly specifying a root type
148 |                         return try self.handle(response, request)
149 |                     })}
150 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
151 |                     .mapError { (error) -> Error in
152 |                         switch error {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:178:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
176 |     ) where R: Request, R.ResponseType == DownloadResponse {
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
179 |                 result in
180 |                 guard let self = self else { return }
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:179:17: error: cannot infer type of closure parameter 'result' without a type annotation
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
179 |                 result in
    |                 `- error: cannot infer type of closure parameter 'result' without a type annotation
180 |                 guard let self = self else { return }
181 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:182:45: error: cannot infer contextual base in reference to member 'init'
180 |                 guard let self = self else { return }
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
    |                                             `- error: cannot infer contextual base in reference to member 'init'
183 |                     .map(\.responseBody)
184 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:183:26: error: cannot infer key path type from context; consider explicitly specifying a root type
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
183 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
184 |
185 |                 DispatchQueue.main.async {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:199:26: error: cannot find 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
199 |         var urlRequest = URLRequest(url: add(queryParameters: request.queryParameters + apiContext.queryParameters, to: url))
    |                          `- error: cannot find 'URLRequest' in scope
200 |         urlRequest.httpMethod = request.method.rawValue
201 |         urlRequest.allHTTPHeaderFields = request.headers.merging(apiContext.headers, uniquingKeysWith: { key1, _ in key1 })
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:206:9: error: no exact matches in call to instance method 'log'
204 |         }
205 |
206 |         log(urlRequest: urlRequest, request: request)
    |         `- error: no exact matches in call to instance method 'log'
207 |
208 |         return urlRequest
    :
289 |     }
290 |
291 |     private func log<R: Request>(result: URLSessionSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
292 |         logger.print("---- Response Code (/\(request.path)) ----")
293 |         logger.print(result.statusCode)
    :
300 |     }
301 |
302 |     private func log<R: Request>(result: URLSessionDownloadSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
303 |         logger.print("---- Response Code (/\(request.path)) ----")
304 |         logger.print(result.statusCode)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:324:46: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
324 |         let config = URLSessionConfiguration.ephemeral
    |                                              `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
325 |         config.urlCache = nil
326 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:328:58: error: cannot infer contextual base in reference to member 'TLSv12'
326 |
327 |         if #available(iOS 13.0, *) {
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
    |                                                          `- error: cannot infer contextual base in reference to member 'TLSv12'
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:330:51: error: cannot infer contextual base in reference to member 'tlsProtocol12'
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
    |                                                   `- error: cannot infer contextual base in reference to member 'tlsProtocol12'
331 |         }
332 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:343:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
344 |         urlResponse.url?.lastPathComponent ??
345 |         urlRequest.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:344:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
345 |         urlRequest.url?.lastPathComponent ??
346 |         "Unknown-\(UUID().uuidString).tmp"
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:389:14: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
387 |     public func perform<R>(_ request: R) async throws -> HTTPResponse<R.ResponseType> where R: Request {
388 |         let result = try await urlSession
389 |             .data(for: try buildUrlRequest(from: request)) as (data: Data, urlResponse: URLResponse)
    |              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
390 |         let httpResult = try URLSessionSuccess(data: result.data, response: result.urlResponse)
391 |         try handleHttpError(from: httpResult, request: request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:400:63: error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
398 |     ) async throws -> HTTPResponse<R.ResponseType> where R: Request, R.ResponseType == DownloadResponse {
399 |         let urlRequest = try buildUrlRequest(from: request)
400 |         let (locationUrl, urlResponse) = try await urlSession.download(for: urlRequest)
    |                                                               `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
401 |         try handleHttpErrorCodes(from: urlResponse)
402 |         let destinationUrl = try generateFileDestination(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:415:62: error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
413 |     ) async throws -> HTTPResponse<R.ResponseType> where R: AsyncDownloadRequest, R.ResponseType == DownloadResponse {
414 |         let urlRequest = try buildUrlRequest(from: request)
415 |         let (asyncBytes, urlResponse) = try await urlSession.bytes(for: urlRequest)
    |                                                              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
416 |         try handleHttpErrorCodes(from: urlResponse)
417 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
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/AdyenNetworking/APIClient/APIClient.swift:443:46: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
    |                                              `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
445 |             throw HTTPErrorResponse(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:444:39: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
    |                                       `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:447:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
447 |                 statusCode: httpResponse.statusCode,
    |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
448 |                 responseBody: EmptyErrorResponse()
449 |             )
[23/23] Compiling AdyenNetworking AnyAPIEnvironment.swift
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:81:29: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 79 |
 80 |     /// :nodoc:
 81 |     private let urlSession: URLSession
    |                             `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 82 |
 83 |     /// Encoding and Decoding
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:109:29: error: cannot find type 'URLSessionDelegate' in scope
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
109 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
110 |     ) {
111 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:106:24: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 |     public init(
105 |         apiContext: AnyAPIContext,
106 |         configuration: URLSessionConfiguration? = nil,
    |                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:129:29: error: cannot find type 'URLSessionDelegate' in scope
127 |         debugLogger: any DebugLogging = DebugLogger(),
128 |         responseValidator: (any AnyResponseValidator)? = nil,
129 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
130 |     ) {
131 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:125:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
123 |     internal init(
124 |         apiContext: AnyAPIContext,
125 |         urlSession: URLSession,
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
126 |         coder: AnyCoder = Coder(),
127 |         debugLogger: any DebugLogging = DebugLogger(),
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:196:73: error: cannot find type 'URLRequest' in scope
194 |     }
195 |
196 |     private func buildUrlRequest<R: Request>(from request: R) throws -> URLRequest {
    |                                                                         `- error: cannot find type 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:269:46: error: cannot find type 'URLRequest' in scope
267 |     }
268 |
269 |     private func log<R: Request>(urlRequest: URLRequest, request: R) {
    |                                              `- error: cannot find type 'URLRequest' in scope
270 |         logger.print("---- Request (/\(request.path)) ----")
271 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:323:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
321 |
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
324 |         let config = URLSessionConfiguration.ephemeral
325 |         config.urlCache = nil
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:83: error: cannot find type 'URLRequest' in scope
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                                                   `- error: cannot find type 'URLRequest' in scope
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:53: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                     `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
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/AdyenNetworking/APIClient/APIClient.swift:441:57: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
439 |     }
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
    |                                                         `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
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/AdyenNetworking/APIClient/APIClient.swift:112:27: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
110 |     ) {
111 |         self.apiContext = apiContext
112 |         self.urlSession = URLSession(
    |                           `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:115:28: error: 'nil' requires a contextual type
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
115 |             delegateQueue: nil
    |                            `- error: 'nil' requires a contextual type
116 |         )
117 |         self.responseValidator = responseValidator
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:89: error: cannot infer type of closure parameter 'result' without a type annotation
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                                                                                         `- error: cannot infer type of closure parameter 'result' without a type annotation
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:146:45: error: cannot infer contextual base in reference to member 'init'
144 |                 guard let self = self else { return }
145 |                 let result = result
146 |                     .flatMap { response in .init(catching: {
    |                                             `- error: cannot infer contextual base in reference to member 'init'
147 |                         try self.handleHttpError(from: response, request: request)
148 |                         return try self.handle(response, request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:150:26: error: cannot infer key path type from context; consider explicitly specifying a root type
148 |                         return try self.handle(response, request)
149 |                     })}
150 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
151 |                     .mapError { (error) -> Error in
152 |                         switch error {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:178:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
176 |     ) where R: Request, R.ResponseType == DownloadResponse {
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
179 |                 result in
180 |                 guard let self = self else { return }
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:179:17: error: cannot infer type of closure parameter 'result' without a type annotation
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
179 |                 result in
    |                 `- error: cannot infer type of closure parameter 'result' without a type annotation
180 |                 guard let self = self else { return }
181 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:182:45: error: cannot infer contextual base in reference to member 'init'
180 |                 guard let self = self else { return }
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
    |                                             `- error: cannot infer contextual base in reference to member 'init'
183 |                     .map(\.responseBody)
184 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:183:26: error: cannot infer key path type from context; consider explicitly specifying a root type
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
183 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
184 |
185 |                 DispatchQueue.main.async {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:199:26: error: cannot find 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
199 |         var urlRequest = URLRequest(url: add(queryParameters: request.queryParameters + apiContext.queryParameters, to: url))
    |                          `- error: cannot find 'URLRequest' in scope
200 |         urlRequest.httpMethod = request.method.rawValue
201 |         urlRequest.allHTTPHeaderFields = request.headers.merging(apiContext.headers, uniquingKeysWith: { key1, _ in key1 })
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:206:9: error: no exact matches in call to instance method 'log'
204 |         }
205 |
206 |         log(urlRequest: urlRequest, request: request)
    |         `- error: no exact matches in call to instance method 'log'
207 |
208 |         return urlRequest
    :
289 |     }
290 |
291 |     private func log<R: Request>(result: URLSessionSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
292 |         logger.print("---- Response Code (/\(request.path)) ----")
293 |         logger.print(result.statusCode)
    :
300 |     }
301 |
302 |     private func log<R: Request>(result: URLSessionDownloadSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
303 |         logger.print("---- Response Code (/\(request.path)) ----")
304 |         logger.print(result.statusCode)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:324:46: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
324 |         let config = URLSessionConfiguration.ephemeral
    |                                              `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
325 |         config.urlCache = nil
326 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:328:58: error: cannot infer contextual base in reference to member 'TLSv12'
326 |
327 |         if #available(iOS 13.0, *) {
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
    |                                                          `- error: cannot infer contextual base in reference to member 'TLSv12'
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:330:51: error: cannot infer contextual base in reference to member 'tlsProtocol12'
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
    |                                                   `- error: cannot infer contextual base in reference to member 'tlsProtocol12'
331 |         }
332 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:343:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
344 |         urlResponse.url?.lastPathComponent ??
345 |         urlRequest.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:344:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
345 |         urlRequest.url?.lastPathComponent ??
346 |         "Unknown-\(UUID().uuidString).tmp"
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:389:14: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
387 |     public func perform<R>(_ request: R) async throws -> HTTPResponse<R.ResponseType> where R: Request {
388 |         let result = try await urlSession
389 |             .data(for: try buildUrlRequest(from: request)) as (data: Data, urlResponse: URLResponse)
    |              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
390 |         let httpResult = try URLSessionSuccess(data: result.data, response: result.urlResponse)
391 |         try handleHttpError(from: httpResult, request: request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:400:63: error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
398 |     ) async throws -> HTTPResponse<R.ResponseType> where R: Request, R.ResponseType == DownloadResponse {
399 |         let urlRequest = try buildUrlRequest(from: request)
400 |         let (locationUrl, urlResponse) = try await urlSession.download(for: urlRequest)
    |                                                               `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
401 |         try handleHttpErrorCodes(from: urlResponse)
402 |         let destinationUrl = try generateFileDestination(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:415:62: error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
413 |     ) async throws -> HTTPResponse<R.ResponseType> where R: AsyncDownloadRequest, R.ResponseType == DownloadResponse {
414 |         let urlRequest = try buildUrlRequest(from: request)
415 |         let (asyncBytes, urlResponse) = try await urlSession.bytes(for: urlRequest)
    |                                                              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
416 |         try handleHttpErrorCodes(from: urlResponse)
417 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
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/AdyenNetworking/APIClient/APIClient.swift:443:46: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
    |                                              `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
445 |             throw HTTPErrorResponse(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:444:39: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
    |                                       `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:447:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
447 |                 statusCode: httpResponse.statusCode,
    |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
448 |                 responseBody: EmptyErrorResponse()
449 |             )
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4606859-0":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:basic-6.1-latest swift build --triple x86_64-unknown-linux-gnu 2>&1
basic-6.1-latest: Pulling from finestructure/spi-images
Digest: sha256:2e2b3aca8600f890617c2faa770b70e33c1dfd303d6f92b308423b89ef6bde64
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:basic-6.1-latest
[0/1] Planning build
Building for debugging...
[0/1] Write swift-version-24593BA9C3E375BF.txt
error: emit-module command failed with exit code 1 (use -v to see invocation)
[2/20] Emitting module AdyenNetworking
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:81:29: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 79 |
 80 |     /// :nodoc:
 81 |     private let urlSession: URLSession
    |                             `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 82 |
 83 |     /// Encoding and Decoding
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:109:29: error: cannot find type 'URLSessionDelegate' in scope
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
109 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
110 |     ) {
111 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:106:24: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 |     public init(
105 |         apiContext: AnyAPIContext,
106 |         configuration: URLSessionConfiguration? = nil,
    |                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:129:29: error: cannot find type 'URLSessionDelegate' in scope
127 |         debugLogger: any DebugLogging = DebugLogger(),
128 |         responseValidator: (any AnyResponseValidator)? = nil,
129 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
130 |     ) {
131 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:125:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
123 |     internal init(
124 |         apiContext: AnyAPIContext,
125 |         urlSession: URLSession,
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
126 |         coder: AnyCoder = Coder(),
127 |         debugLogger: any DebugLogging = DebugLogger(),
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:196:73: error: cannot find type 'URLRequest' in scope
194 |     }
195 |
196 |     private func buildUrlRequest<R: Request>(from request: R) throws -> URLRequest {
    |                                                                         `- error: cannot find type 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:269:46: error: cannot find type 'URLRequest' in scope
267 |     }
268 |
269 |     private func log<R: Request>(urlRequest: URLRequest, request: R) {
    |                                              `- error: cannot find type 'URLRequest' in scope
270 |         logger.print("---- Request (/\(request.path)) ----")
271 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:323:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
321 |
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
324 |         let config = URLSessionConfiguration.ephemeral
325 |         config.urlCache = nil
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:83: error: cannot find type 'URLRequest' in scope
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                                                   `- error: cannot find type 'URLRequest' in scope
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:53: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                     `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
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/AdyenNetworking/APIClient/APIClient.swift:441:57: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
439 |     }
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
    |                                                         `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:16:42: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 |     internal let headers: [String: String]
15 |
16 |     internal init(data: Data?, response: URLResponse?) throws {
   |                                          `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:36:40: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |     internal let headers: [String: String]
35 |
36 |     internal init(url: URL?, response: URLResponse?) throws {
   |                                        `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:50:10: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
48 |
49 | /// :nodoc:
50 | internal extension URLSession {
   |          `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
51 |
52 |     /// :nodoc:
[3/22] Compiling AdyenNetworking AnyCoder.swift
[4/22] Compiling AdyenNetworking AnyResponseValidator.swift
[5/22] Compiling AdyenNetworking BackoffScheduler.swift
[6/22] Compiling AdyenNetworking Coder.swift
[7/22] Compiling AdyenNetworking DebugLogger.swift
[8/22] Compiling AdyenNetworking RetryAPIClient.swift
[9/22] Compiling AdyenNetworking RetryOnErrorAPIClient.swift
[10/22] Compiling AdyenNetworking Scheduler.swift
[11/22] Compiling AdyenNetworking SimpleScheduler.swift
[12/22] Compiling AdyenNetworking UniqueAssetAPIClient.swift
[13/22] Compiling AdyenNetworking Errors.swift
[14/22] Compiling AdyenNetworking HTTPResponse.swift
[15/22] Compiling AdyenNetworking Request.swift
[16/22] Compiling AdyenNetworking DebugLogging.swift
[17/22] Compiling AdyenNetworking Logging.swift
[18/22] Compiling AdyenNetworking URLHelpers.swift
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:16:42: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 |     internal let headers: [String: String]
15 |
16 |     internal init(data: Data?, response: URLResponse?) throws {
   |                                          `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:36:40: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |     internal let headers: [String: String]
35 |
36 |     internal init(url: URL?, response: URLResponse?) throws {
   |                                        `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:50:10: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
48 |
49 | /// :nodoc:
50 | internal extension URLSession {
   |          `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
51 |
52 |     /// :nodoc:
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:18:43: warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
16 |     internal init(data: Data?, response: URLResponse?) throws {
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
   |                                           `- warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
20 |                   throw APIClientError.invalidResponse
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:18:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
16 |     internal init(data: Data?, response: URLResponse?) throws {
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
   |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
20 |                   throw APIClientError.invalidResponse
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:19:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
   |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
20 |                   throw APIClientError.invalidResponse
21 |         }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:25:40: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
23 |         self.data = data
24 |         self.headers = headers
25 |         self.statusCode = httpResponse.statusCode
   |                                        `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
26 |     }
27 | }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:38:43: warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
36 |     internal init(url: URL?, response: URLResponse?) throws {
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
   |                                           `- warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
40 |                   throw APIClientError.invalidResponse
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:38:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
36 |     internal init(url: URL?, response: URLResponse?) throws {
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
   |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
40 |                   throw APIClientError.invalidResponse
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:39:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
   |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
40 |                   throw APIClientError.invalidResponse
41 |         }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:45:40: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
43 |         self.url = url
44 |         self.headers = headers
45 |         self.statusCode = httpResponse.statusCode
   |                                        `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
46 |     }
47 | }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:54:26: error: cannot find type 'URLRequest' in scope
52 |     /// :nodoc:
53 |     func dataTask(
54 |         with urlRequest: URLRequest,
   |                          `- error: cannot find type 'URLRequest' in scope
55 |         completion: @escaping ((Result<URLSessionSuccess, Error>) -> Void)
56 |     ) -> URLSessionDataTask {
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:68:26: error: cannot find type 'URLRequest' in scope
66 |     /// :nodoc:
67 |     func downloadTask(
68 |         with urlRequest: URLRequest,
   |                          `- error: cannot find type 'URLRequest' in scope
69 |         completion: @escaping ((Result<URLSessionDownloadSuccess, Error>) -> Void)
70 |     ) -> URLSessionDownloadTask {
[19/22] Compiling AdyenNetworking URLSessionHelpers.swift
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:16:42: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
14 |     internal let headers: [String: String]
15 |
16 |     internal init(data: Data?, response: URLResponse?) throws {
   |                                          `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:36:40: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 |     internal let headers: [String: String]
35 |
36 |     internal init(url: URL?, response: URLResponse?) throws {
   |                                        `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:50:10: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
48 |
49 | /// :nodoc:
50 | internal extension URLSession {
   |          `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
51 |
52 |     /// :nodoc:
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:18:43: warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
16 |     internal init(data: Data?, response: URLResponse?) throws {
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
   |                                           `- warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
20 |                   throw APIClientError.invalidResponse
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:18:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
16 |     internal init(data: Data?, response: URLResponse?) throws {
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
   |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
20 |                   throw APIClientError.invalidResponse
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:19:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
17 |         guard let data = data,
18 |               let httpResponse = response as? HTTPURLResponse,
19 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
   |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
20 |                   throw APIClientError.invalidResponse
21 |         }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:25:40: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
23 |         self.data = data
24 |         self.headers = headers
25 |         self.statusCode = httpResponse.statusCode
   |                                        `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
26 |     }
27 | }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:38:43: warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
36 |     internal init(url: URL?, response: URLResponse?) throws {
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
   |                                           `- warning: conditional downcast from 'URLResponse?' (aka 'Optional<AnyObject>') to 'HTTPURLResponse' (aka 'AnyObject') does nothing
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
40 |                   throw APIClientError.invalidResponse
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:38:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
36 |     internal init(url: URL?, response: URLResponse?) throws {
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
   |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
40 |                   throw APIClientError.invalidResponse
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/AdyenNetworking/Helpers/URLSessionHelpers.swift:39:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
37 |         guard let url = url,
38 |               let httpResponse = response as? HTTPURLResponse,
39 |               let headers = httpResponse.allHeaderFields as? [String: String] else {
   |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
40 |                   throw APIClientError.invalidResponse
41 |         }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:45:40: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
43 |         self.url = url
44 |         self.headers = headers
45 |         self.statusCode = httpResponse.statusCode
   |                                        `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
46 |     }
47 | }
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:54:26: error: cannot find type 'URLRequest' in scope
52 |     /// :nodoc:
53 |     func dataTask(
54 |         with urlRequest: URLRequest,
   |                          `- error: cannot find type 'URLRequest' in scope
55 |         completion: @escaping ((Result<URLSessionSuccess, Error>) -> Void)
56 |     ) -> URLSessionDataTask {
/host/spi-builder-workspace/AdyenNetworking/Helpers/URLSessionHelpers.swift:68:26: error: cannot find type 'URLRequest' in scope
66 |     /// :nodoc:
67 |     func downloadTask(
68 |         with urlRequest: URLRequest,
   |                          `- error: cannot find type 'URLRequest' in scope
69 |         completion: @escaping ((Result<URLSessionDownloadSuccess, Error>) -> Void)
70 |     ) -> URLSessionDownloadTask {
[20/22] Compiling AdyenNetworking APIClient.swift
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:81:29: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 79 |
 80 |     /// :nodoc:
 81 |     private let urlSession: URLSession
    |                             `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 82 |
 83 |     /// Encoding and Decoding
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:109:29: error: cannot find type 'URLSessionDelegate' in scope
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
109 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
110 |     ) {
111 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:106:24: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 |     public init(
105 |         apiContext: AnyAPIContext,
106 |         configuration: URLSessionConfiguration? = nil,
    |                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:129:29: error: cannot find type 'URLSessionDelegate' in scope
127 |         debugLogger: any DebugLogging = DebugLogger(),
128 |         responseValidator: (any AnyResponseValidator)? = nil,
129 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
130 |     ) {
131 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:125:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
123 |     internal init(
124 |         apiContext: AnyAPIContext,
125 |         urlSession: URLSession,
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
126 |         coder: AnyCoder = Coder(),
127 |         debugLogger: any DebugLogging = DebugLogger(),
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:196:73: error: cannot find type 'URLRequest' in scope
194 |     }
195 |
196 |     private func buildUrlRequest<R: Request>(from request: R) throws -> URLRequest {
    |                                                                         `- error: cannot find type 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:269:46: error: cannot find type 'URLRequest' in scope
267 |     }
268 |
269 |     private func log<R: Request>(urlRequest: URLRequest, request: R) {
    |                                              `- error: cannot find type 'URLRequest' in scope
270 |         logger.print("---- Request (/\(request.path)) ----")
271 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:323:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
321 |
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
324 |         let config = URLSessionConfiguration.ephemeral
325 |         config.urlCache = nil
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:83: error: cannot find type 'URLRequest' in scope
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                                                   `- error: cannot find type 'URLRequest' in scope
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:53: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                     `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
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/AdyenNetworking/APIClient/APIClient.swift:441:57: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
439 |     }
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
    |                                                         `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
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/AdyenNetworking/APIClient/APIClient.swift:112:27: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
110 |     ) {
111 |         self.apiContext = apiContext
112 |         self.urlSession = URLSession(
    |                           `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:115:28: error: 'nil' requires a contextual type
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
115 |             delegateQueue: nil
    |                            `- error: 'nil' requires a contextual type
116 |         )
117 |         self.responseValidator = responseValidator
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:89: error: cannot infer type of closure parameter 'result' without a type annotation
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                                                                                         `- error: cannot infer type of closure parameter 'result' without a type annotation
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:146:45: error: cannot infer contextual base in reference to member 'init'
144 |                 guard let self = self else { return }
145 |                 let result = result
146 |                     .flatMap { response in .init(catching: {
    |                                             `- error: cannot infer contextual base in reference to member 'init'
147 |                         try self.handleHttpError(from: response, request: request)
148 |                         return try self.handle(response, request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:150:26: error: cannot infer key path type from context; consider explicitly specifying a root type
148 |                         return try self.handle(response, request)
149 |                     })}
150 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
151 |                     .mapError { (error) -> Error in
152 |                         switch error {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:178:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
176 |     ) where R: Request, R.ResponseType == DownloadResponse {
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
179 |                 result in
180 |                 guard let self = self else { return }
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:179:17: error: cannot infer type of closure parameter 'result' without a type annotation
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
179 |                 result in
    |                 `- error: cannot infer type of closure parameter 'result' without a type annotation
180 |                 guard let self = self else { return }
181 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:182:45: error: cannot infer contextual base in reference to member 'init'
180 |                 guard let self = self else { return }
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
    |                                             `- error: cannot infer contextual base in reference to member 'init'
183 |                     .map(\.responseBody)
184 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:183:26: error: cannot infer key path type from context; consider explicitly specifying a root type
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
183 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
184 |
185 |                 DispatchQueue.main.async {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:199:26: error: cannot find 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
199 |         var urlRequest = URLRequest(url: add(queryParameters: request.queryParameters + apiContext.queryParameters, to: url))
    |                          `- error: cannot find 'URLRequest' in scope
200 |         urlRequest.httpMethod = request.method.rawValue
201 |         urlRequest.allHTTPHeaderFields = request.headers.merging(apiContext.headers, uniquingKeysWith: { key1, _ in key1 })
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:206:9: error: no exact matches in call to instance method 'log'
204 |         }
205 |
206 |         log(urlRequest: urlRequest, request: request)
    |         `- error: no exact matches in call to instance method 'log'
207 |
208 |         return urlRequest
    :
289 |     }
290 |
291 |     private func log<R: Request>(result: URLSessionSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
292 |         logger.print("---- Response Code (/\(request.path)) ----")
293 |         logger.print(result.statusCode)
    :
300 |     }
301 |
302 |     private func log<R: Request>(result: URLSessionDownloadSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
303 |         logger.print("---- Response Code (/\(request.path)) ----")
304 |         logger.print(result.statusCode)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:324:46: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
324 |         let config = URLSessionConfiguration.ephemeral
    |                                              `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
325 |         config.urlCache = nil
326 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:328:58: error: cannot infer contextual base in reference to member 'TLSv12'
326 |
327 |         if #available(iOS 13.0, *) {
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
    |                                                          `- error: cannot infer contextual base in reference to member 'TLSv12'
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:330:51: error: cannot infer contextual base in reference to member 'tlsProtocol12'
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
    |                                                   `- error: cannot infer contextual base in reference to member 'tlsProtocol12'
331 |         }
332 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:343:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
344 |         urlResponse.url?.lastPathComponent ??
345 |         urlRequest.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:344:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
345 |         urlRequest.url?.lastPathComponent ??
346 |         "Unknown-\(UUID().uuidString).tmp"
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:389:14: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
387 |     public func perform<R>(_ request: R) async throws -> HTTPResponse<R.ResponseType> where R: Request {
388 |         let result = try await urlSession
389 |             .data(for: try buildUrlRequest(from: request)) as (data: Data, urlResponse: URLResponse)
    |              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
390 |         let httpResult = try URLSessionSuccess(data: result.data, response: result.urlResponse)
391 |         try handleHttpError(from: httpResult, request: request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:400:63: error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
398 |     ) async throws -> HTTPResponse<R.ResponseType> where R: Request, R.ResponseType == DownloadResponse {
399 |         let urlRequest = try buildUrlRequest(from: request)
400 |         let (locationUrl, urlResponse) = try await urlSession.download(for: urlRequest)
    |                                                               `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
401 |         try handleHttpErrorCodes(from: urlResponse)
402 |         let destinationUrl = try generateFileDestination(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:415:62: error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
413 |     ) async throws -> HTTPResponse<R.ResponseType> where R: AsyncDownloadRequest, R.ResponseType == DownloadResponse {
414 |         let urlRequest = try buildUrlRequest(from: request)
415 |         let (asyncBytes, urlResponse) = try await urlSession.bytes(for: urlRequest)
    |                                                              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
416 |         try handleHttpErrorCodes(from: urlResponse)
417 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
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/AdyenNetworking/APIClient/APIClient.swift:443:46: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
    |                                              `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
445 |             throw HTTPErrorResponse(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:444:39: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
    |                                       `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:447:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
447 |                 statusCode: httpResponse.statusCode,
    |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
448 |                 responseBody: EmptyErrorResponse()
449 |             )
[21/22] Compiling AdyenNetworking AnyAPIContext.swift
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:81:29: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 79 |
 80 |     /// :nodoc:
 81 |     private let urlSession: URLSession
    |                             `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 82 |
 83 |     /// Encoding and Decoding
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:109:29: error: cannot find type 'URLSessionDelegate' in scope
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
109 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
110 |     ) {
111 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:106:24: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 |     public init(
105 |         apiContext: AnyAPIContext,
106 |         configuration: URLSessionConfiguration? = nil,
    |                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:129:29: error: cannot find type 'URLSessionDelegate' in scope
127 |         debugLogger: any DebugLogging = DebugLogger(),
128 |         responseValidator: (any AnyResponseValidator)? = nil,
129 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
130 |     ) {
131 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:125:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
123 |     internal init(
124 |         apiContext: AnyAPIContext,
125 |         urlSession: URLSession,
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
126 |         coder: AnyCoder = Coder(),
127 |         debugLogger: any DebugLogging = DebugLogger(),
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:196:73: error: cannot find type 'URLRequest' in scope
194 |     }
195 |
196 |     private func buildUrlRequest<R: Request>(from request: R) throws -> URLRequest {
    |                                                                         `- error: cannot find type 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:269:46: error: cannot find type 'URLRequest' in scope
267 |     }
268 |
269 |     private func log<R: Request>(urlRequest: URLRequest, request: R) {
    |                                              `- error: cannot find type 'URLRequest' in scope
270 |         logger.print("---- Request (/\(request.path)) ----")
271 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:323:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
321 |
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
324 |         let config = URLSessionConfiguration.ephemeral
325 |         config.urlCache = nil
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:83: error: cannot find type 'URLRequest' in scope
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                                                   `- error: cannot find type 'URLRequest' in scope
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:53: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                     `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
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/AdyenNetworking/APIClient/APIClient.swift:441:57: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
439 |     }
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
    |                                                         `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
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/AdyenNetworking/APIClient/APIClient.swift:112:27: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
110 |     ) {
111 |         self.apiContext = apiContext
112 |         self.urlSession = URLSession(
    |                           `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:115:28: error: 'nil' requires a contextual type
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
115 |             delegateQueue: nil
    |                            `- error: 'nil' requires a contextual type
116 |         )
117 |         self.responseValidator = responseValidator
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:89: error: cannot infer type of closure parameter 'result' without a type annotation
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                                                                                         `- error: cannot infer type of closure parameter 'result' without a type annotation
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:146:45: error: cannot infer contextual base in reference to member 'init'
144 |                 guard let self = self else { return }
145 |                 let result = result
146 |                     .flatMap { response in .init(catching: {
    |                                             `- error: cannot infer contextual base in reference to member 'init'
147 |                         try self.handleHttpError(from: response, request: request)
148 |                         return try self.handle(response, request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:150:26: error: cannot infer key path type from context; consider explicitly specifying a root type
148 |                         return try self.handle(response, request)
149 |                     })}
150 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
151 |                     .mapError { (error) -> Error in
152 |                         switch error {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:178:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
176 |     ) where R: Request, R.ResponseType == DownloadResponse {
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
179 |                 result in
180 |                 guard let self = self else { return }
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:179:17: error: cannot infer type of closure parameter 'result' without a type annotation
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
179 |                 result in
    |                 `- error: cannot infer type of closure parameter 'result' without a type annotation
180 |                 guard let self = self else { return }
181 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:182:45: error: cannot infer contextual base in reference to member 'init'
180 |                 guard let self = self else { return }
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
    |                                             `- error: cannot infer contextual base in reference to member 'init'
183 |                     .map(\.responseBody)
184 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:183:26: error: cannot infer key path type from context; consider explicitly specifying a root type
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
183 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
184 |
185 |                 DispatchQueue.main.async {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:199:26: error: cannot find 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
199 |         var urlRequest = URLRequest(url: add(queryParameters: request.queryParameters + apiContext.queryParameters, to: url))
    |                          `- error: cannot find 'URLRequest' in scope
200 |         urlRequest.httpMethod = request.method.rawValue
201 |         urlRequest.allHTTPHeaderFields = request.headers.merging(apiContext.headers, uniquingKeysWith: { key1, _ in key1 })
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:206:9: error: no exact matches in call to instance method 'log'
204 |         }
205 |
206 |         log(urlRequest: urlRequest, request: request)
    |         `- error: no exact matches in call to instance method 'log'
207 |
208 |         return urlRequest
    :
289 |     }
290 |
291 |     private func log<R: Request>(result: URLSessionSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
292 |         logger.print("---- Response Code (/\(request.path)) ----")
293 |         logger.print(result.statusCode)
    :
300 |     }
301 |
302 |     private func log<R: Request>(result: URLSessionDownloadSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
303 |         logger.print("---- Response Code (/\(request.path)) ----")
304 |         logger.print(result.statusCode)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:324:46: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
324 |         let config = URLSessionConfiguration.ephemeral
    |                                              `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
325 |         config.urlCache = nil
326 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:328:58: error: cannot infer contextual base in reference to member 'TLSv12'
326 |
327 |         if #available(iOS 13.0, *) {
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
    |                                                          `- error: cannot infer contextual base in reference to member 'TLSv12'
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:330:51: error: cannot infer contextual base in reference to member 'tlsProtocol12'
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
    |                                                   `- error: cannot infer contextual base in reference to member 'tlsProtocol12'
331 |         }
332 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:343:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
344 |         urlResponse.url?.lastPathComponent ??
345 |         urlRequest.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:344:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
345 |         urlRequest.url?.lastPathComponent ??
346 |         "Unknown-\(UUID().uuidString).tmp"
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:389:14: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
387 |     public func perform<R>(_ request: R) async throws -> HTTPResponse<R.ResponseType> where R: Request {
388 |         let result = try await urlSession
389 |             .data(for: try buildUrlRequest(from: request)) as (data: Data, urlResponse: URLResponse)
    |              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
390 |         let httpResult = try URLSessionSuccess(data: result.data, response: result.urlResponse)
391 |         try handleHttpError(from: httpResult, request: request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:400:63: error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
398 |     ) async throws -> HTTPResponse<R.ResponseType> where R: Request, R.ResponseType == DownloadResponse {
399 |         let urlRequest = try buildUrlRequest(from: request)
400 |         let (locationUrl, urlResponse) = try await urlSession.download(for: urlRequest)
    |                                                               `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
401 |         try handleHttpErrorCodes(from: urlResponse)
402 |         let destinationUrl = try generateFileDestination(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:415:62: error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
413 |     ) async throws -> HTTPResponse<R.ResponseType> where R: AsyncDownloadRequest, R.ResponseType == DownloadResponse {
414 |         let urlRequest = try buildUrlRequest(from: request)
415 |         let (asyncBytes, urlResponse) = try await urlSession.bytes(for: urlRequest)
    |                                                              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
416 |         try handleHttpErrorCodes(from: urlResponse)
417 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
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/AdyenNetworking/APIClient/APIClient.swift:443:46: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
    |                                              `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
445 |             throw HTTPErrorResponse(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:444:39: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
    |                                       `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:447:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
447 |                 statusCode: httpResponse.statusCode,
    |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
448 |                 responseBody: EmptyErrorResponse()
449 |             )
[22/22] Compiling AdyenNetworking AnyAPIEnvironment.swift
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:81:29: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 79 |
 80 |     /// :nodoc:
 81 |     private let urlSession: URLSession
    |                             `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 82 |
 83 |     /// Encoding and Decoding
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:109:29: error: cannot find type 'URLSessionDelegate' in scope
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
109 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
110 |     ) {
111 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:106:24: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 |     public init(
105 |         apiContext: AnyAPIContext,
106 |         configuration: URLSessionConfiguration? = nil,
    |                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
107 |         coder: AnyCoder = Coder(),
108 |         responseValidator: (any AnyResponseValidator)? = nil,
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:129:29: error: cannot find type 'URLSessionDelegate' in scope
127 |         debugLogger: any DebugLogging = DebugLogger(),
128 |         responseValidator: (any AnyResponseValidator)? = nil,
129 |         urlSessionDelegate: URLSessionDelegate? = nil
    |                             `- error: cannot find type 'URLSessionDelegate' in scope
130 |     ) {
131 |         self.apiContext = apiContext
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:125:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
123 |     internal init(
124 |         apiContext: AnyAPIContext,
125 |         urlSession: URLSession,
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
126 |         coder: AnyCoder = Coder(),
127 |         debugLogger: any DebugLogging = DebugLogger(),
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:196:73: error: cannot find type 'URLRequest' in scope
194 |     }
195 |
196 |     private func buildUrlRequest<R: Request>(from request: R) throws -> URLRequest {
    |                                                                         `- error: cannot find type 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:269:46: error: cannot find type 'URLRequest' in scope
267 |     }
268 |
269 |     private func log<R: Request>(urlRequest: URLRequest, request: R) {
    |                                              `- error: cannot find type 'URLRequest' in scope
270 |         logger.print("---- Request (/\(request.path)) ----")
271 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:323:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
321 |
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
324 |         let config = URLSessionConfiguration.ephemeral
325 |         config.urlCache = nil
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
  |                  `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:83: error: cannot find type 'URLRequest' in scope
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                                                   `- error: cannot find type 'URLRequest' in scope
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:342:53: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
340 |     ///
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
    |                                                     `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
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/AdyenNetworking/APIClient/APIClient.swift:441:57: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
439 |     }
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
    |                                                         `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
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/AdyenNetworking/APIClient/APIClient.swift:112:27: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
110 |     ) {
111 |         self.apiContext = apiContext
112 |         self.urlSession = URLSession(
    |                           `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:115:28: error: 'nil' requires a contextual type
113 |             configuration: configuration ?? Self.buildDefaultConfiguration(),
114 |             delegate: urlSessionDelegate,
115 |             delegateQueue: nil
    |                            `- error: 'nil' requires a contextual type
116 |         )
117 |         self.responseValidator = responseValidator
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:143:89: error: cannot infer type of closure parameter 'result' without a type annotation
141 |     ) where R: Request {
142 |         do {
143 |             urlSession.dataTask(with: try buildUrlRequest(from: request)) { [weak self] result in
    |                                                                                         `- error: cannot infer type of closure parameter 'result' without a type annotation
144 |                 guard let self = self else { return }
145 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:146:45: error: cannot infer contextual base in reference to member 'init'
144 |                 guard let self = self else { return }
145 |                 let result = result
146 |                     .flatMap { response in .init(catching: {
    |                                             `- error: cannot infer contextual base in reference to member 'init'
147 |                         try self.handleHttpError(from: response, request: request)
148 |                         return try self.handle(response, request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:150:26: error: cannot infer key path type from context; consider explicitly specifying a root type
148 |                         return try self.handle(response, request)
149 |                     })}
150 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
151 |                     .mapError { (error) -> Error in
152 |                         switch error {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:178:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
176 |     ) where R: Request, R.ResponseType == DownloadResponse {
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'downloadTask'
179 |                 result in
180 |                 guard let self = self else { return }
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:179:17: error: cannot infer type of closure parameter 'result' without a type annotation
177 |         do {
178 |             urlSession.downloadTask(with: try buildUrlRequest(from: request)) { [weak self]
179 |                 result in
    |                 `- error: cannot infer type of closure parameter 'result' without a type annotation
180 |                 guard let self = self else { return }
181 |                 let result = result
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:182:45: error: cannot infer contextual base in reference to member 'init'
180 |                 guard let self = self else { return }
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
    |                                             `- error: cannot infer contextual base in reference to member 'init'
183 |                     .map(\.responseBody)
184 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:183:26: error: cannot infer key path type from context; consider explicitly specifying a root type
181 |                 let result = result
182 |                     .flatMap { response in .init(catching: { try self.handle(response, request) }) }
183 |                     .map(\.responseBody)
    |                          `- error: cannot infer key path type from context; consider explicitly specifying a root type
184 |
185 |                 DispatchQueue.main.async {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:199:26: error: cannot find 'URLRequest' in scope
197 |         let url = apiContext.environment.baseURL.appendingPathComponent(request.path)
198 |
199 |         var urlRequest = URLRequest(url: add(queryParameters: request.queryParameters + apiContext.queryParameters, to: url))
    |                          `- error: cannot find 'URLRequest' in scope
200 |         urlRequest.httpMethod = request.method.rawValue
201 |         urlRequest.allHTTPHeaderFields = request.headers.merging(apiContext.headers, uniquingKeysWith: { key1, _ in key1 })
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:206:9: error: no exact matches in call to instance method 'log'
204 |         }
205 |
206 |         log(urlRequest: urlRequest, request: request)
    |         `- error: no exact matches in call to instance method 'log'
207 |
208 |         return urlRequest
    :
289 |     }
290 |
291 |     private func log<R: Request>(result: URLSessionSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
292 |         logger.print("---- Response Code (/\(request.path)) ----")
293 |         logger.print(result.statusCode)
    :
300 |     }
301 |
302 |     private func log<R: Request>(result: URLSessionDownloadSuccess, request: R) {
    |                  `- note: incorrect labels for candidate (have: '(urlRequest:request:)', expected: '(result:request:)')
303 |         logger.print("---- Response Code (/\(request.path)) ----")
304 |         logger.print(result.statusCode)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:324:46: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
322 |     /// :nodoc:
323 |     private static func buildDefaultConfiguration() -> URLSessionConfiguration {
324 |         let config = URLSessionConfiguration.ephemeral
    |                                              `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
325 |         config.urlCache = nil
326 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:328:58: error: cannot infer contextual base in reference to member 'TLSv12'
326 |
327 |         if #available(iOS 13.0, *) {
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
    |                                                          `- error: cannot infer contextual base in reference to member 'TLSv12'
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:330:51: error: cannot infer contextual base in reference to member 'tlsProtocol12'
328 |             config.tlsMinimumSupportedProtocolVersion = .TLSv12
329 |         } else {
330 |             config.tlsMinimumSupportedProtocol = .tlsProtocol12
    |                                                   `- error: cannot infer contextual base in reference to member 'tlsProtocol12'
331 |         }
332 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:343:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
341 |     /// If a filename from the `URLResponse` or `URLRequest` are `nil`, a default filename is given  in the form `Unknown-[UUID].tmp`.
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'suggestedFilename'
344 |         urlResponse.url?.lastPathComponent ??
345 |         urlRequest.url?.lastPathComponent ??
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:344:21: error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
342 |     private func generateFilename(from urlResponse: URLResponse, with urlRequest: URLRequest) -> String {
343 |         urlResponse.suggestedFilename ??
344 |         urlResponse.url?.lastPathComponent ??
    |                     `- error: value of type 'URLResponse' (aka 'AnyObject') has no member 'url'
345 |         urlRequest.url?.lastPathComponent ??
346 |         "Unknown-\(UUID().uuidString).tmp"
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:389:14: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
387 |     public func perform<R>(_ request: R) async throws -> HTTPResponse<R.ResponseType> where R: Request {
388 |         let result = try await urlSession
389 |             .data(for: try buildUrlRequest(from: request)) as (data: Data, urlResponse: URLResponse)
    |              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
390 |         let httpResult = try URLSessionSuccess(data: result.data, response: result.urlResponse)
391 |         try handleHttpError(from: httpResult, request: request)
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:400:63: error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
398 |     ) async throws -> HTTPResponse<R.ResponseType> where R: Request, R.ResponseType == DownloadResponse {
399 |         let urlRequest = try buildUrlRequest(from: request)
400 |         let (locationUrl, urlResponse) = try await urlSession.download(for: urlRequest)
    |                                                               `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'download'
401 |         try handleHttpErrorCodes(from: urlResponse)
402 |         let destinationUrl = try generateFileDestination(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:415:62: error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
413 |     ) async throws -> HTTPResponse<R.ResponseType> where R: AsyncDownloadRequest, R.ResponseType == DownloadResponse {
414 |         let urlRequest = try buildUrlRequest(from: request)
415 |         let (asyncBytes, urlResponse) = try await urlSession.bytes(for: urlRequest)
    |                                                              `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'bytes'
416 |         try handleHttpErrorCodes(from: urlResponse)
417 |
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:43: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                           `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:442:47: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
440 |
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
    |                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
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/AdyenNetworking/APIClient/APIClient.swift:443:46: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
441 |     private func handleHttpErrorCodes(from urlResponse: URLResponse) throws {
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
    |                                              `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
445 |             throw HTTPErrorResponse(
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:444:39: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
442 |         if let httpResponse = urlResponse as? HTTPURLResponse,
443 |            (400...599).contains(httpResponse.statusCode),
444 |            let headers = httpResponse.allHeaderFields as? [String: String] {
    |                                       `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
/host/spi-builder-workspace/AdyenNetworking/APIClient/APIClient.swift:447:42: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
445 |             throw HTTPErrorResponse(
446 |                 headers: headers,
447 |                 statusCode: httpResponse.statusCode,
    |                                          `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
448 |                 responseBody: EmptyErrorResponse()
449 |             )
BUILD FAILURE 6.1 linux