Build Information
Failed to build YouVersionPlatform, reference main (2deece), with Swift 6.2 for Wasm on 30 Nov 2026 19:53:57 UTC.
Build Command
bash -c docker run --pull=always --rm -v "checkouts-54344844-0":/host -w "$PWD" -e GIT_HTTP_LOW_SPEED_LIMIT="100000" -e GIT_HTTP_LOW_SPEED_TIME="60" -e JAVA_HOME="/root/.sdkman/candidates/java/current" -e SPI_BUILD="1" -e SPI_PROCESSING="1" registry.gitlab.com/saguaro1/spi-images:wasm-6.2-latest swift build --swift-sdk swift-6.2-RELEASE_wasm 2>&1Build Log
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:174:10: error: cannot find type 'URLRequest' in scope
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:172:22: error: cannot find type 'URLRequest' in scope
170 | accessToken: String?,
171 | session: URLSession,
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
| `- error: cannot find type 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:171:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
169 | with url: URL,
170 | accessToken: String?,
171 | session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:259:31: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
257 | private var refreshTask: Task<String?, Never>?
258 |
259 | func accessToken(session: URLSession) async -> String? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
260 | guard let authData = YouVersionPlatformConfiguration.authData,
261 | let accessToken = authData.accessToken else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:309:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
307 | refreshToken: String,
308 | idToken: String?,
309 | session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
310 | ) async -> String? {
311 | guard let result = try? await YouVersionAPI.Users.refreshSignIn(
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:64:51: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
62 | return BibleContentResponse(
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
65 | isCacheable: response.httpResponse.allowsCaching
66 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:65:48: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
65 | isCacheable: response.httpResponse.allowsCaching
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
66 | )
67 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:70: error: extra argument 'for' in call
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: extra argument 'for' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:64: error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
67 | }
68 |
69 | private static func response(
| `- note: 'response(at:accessToken:session:allowsNoContent:)' declared here
70 | at url: URL,
71 | accessToken: String?,
:
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:106:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
104 | /// `YouVersionAPIError.cannotDownload` for any other status.
105 | static func error(for httpResponse: HTTPURLResponse, data: Data) -> any Error {
106 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:108:60: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
106 | switch httpResponse.statusCode {
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
109 | return YouVersionAPIError.notPermitted
110 | default:
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:123:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
121 | static func responseError(for httpResponse: HTTPURLResponse, data: Data) -> YouVersionAPIResponseError? {
122 | let code: YouVersionAPIResponseError.Code
123 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
124 | case 401, 403:
125 | return nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:136:76: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
134 | }
135 |
136 | let body = ResponseErrorBody(data: data, contentType: httpResponse.value(forHTTPHeaderField: "Content-Type"))
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
137 | return YouVersionAPIResponseError(
138 | code: code,
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:139:38: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
137 | return YouVersionAPIResponseError(
138 | code: code,
139 | statusCode: httpResponse.statusCode,
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:141:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
139 | statusCode: httpResponse.statusCode,
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
142 | validationIssues: body.validationIssues
143 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:175:23: error: cannot find 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
| `- error: cannot find 'URLRequest' in scope
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:177:44: error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
178 | for (key, value) in additionalHeaders {
179 | guard let headerField = key as? String else { continue }
[492/505] Compiling YouVersionPlatformCore YouVersionVerseOfTheDay.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:109: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:123: error: value of type '_' expected to be instance of class or class-constrained type
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: value of type '_' expected to be instance of class or class-constrained type
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:123: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:22: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:36: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:36: error: value of type '_' expected to be instance of class or class-constrained type
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:22: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:36: error: value of type '_' expected to be instance of class or class-constrained type
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:36: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:47: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:61: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:61: error: value of type '_' expected to be instance of class or class-constrained type
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: value of type '_' expected to be instance of class or class-constrained type
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:28:62: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
26 | }
27 |
28 | static func accessToken(providedToken: String?, session: URLSession) async -> String? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
29 | if let providedToken {
30 | return providedToken
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:35:66: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
33 | }
34 |
35 | static func data(at url: URL, accessToken: String?, session: URLSession) async throws -> Data {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
36 | try await responseData(at: url, accessToken: accessToken, session: session).value
37 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:39:75: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 | }
38 |
39 | static func dataIfPresent(at url: URL, accessToken: String?, session: URLSession) async throws -> Data? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
40 | try await response(
41 | at: url,
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:51:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
49 | at url: URL,
50 | accessToken: String?,
51 | session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
52 | ) async throws -> BibleContentResponse<Data> {
53 | let response = try await response(
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:72:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
70 | at url: URL,
71 | accessToken: String?,
72 | session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
73 | allowsNoContent: Bool
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:74:51: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
72 | session: URLSession,
73 | allowsNoContent: Bool
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:105:41: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 | /// - Returns: `YouVersionAPIError.notPermitted` for `401` and `403`, and
104 | /// `YouVersionAPIError.cannotDownload` for any other status.
105 | static func error(for httpResponse: HTTPURLResponse, data: Data) -> any Error {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 | switch httpResponse.statusCode {
107 | case 401, 403:
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:121:49: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
119 | /// - data: The response body, which can carry a message from the server.
120 | /// - Returns: A ``YouVersionAPIResponseError`` for `4xx` and `5xx` statuses other than `401` and `403`, or `nil`.
121 | static func responseError(for httpResponse: HTTPURLResponse, data: Data) -> YouVersionAPIResponseError? {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
122 | let code: YouVersionAPIResponseError.Code
123 | switch httpResponse.statusCode {
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:174:10: error: cannot find type 'URLRequest' in scope
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:172:22: error: cannot find type 'URLRequest' in scope
170 | accessToken: String?,
171 | session: URLSession,
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
| `- error: cannot find type 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:171:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
169 | with url: URL,
170 | accessToken: String?,
171 | session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:259:31: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
257 | private var refreshTask: Task<String?, Never>?
258 |
259 | func accessToken(session: URLSession) async -> String? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
260 | guard let authData = YouVersionPlatformConfiguration.authData,
261 | let accessToken = authData.accessToken else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:309:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
307 | refreshToken: String,
308 | idToken: String?,
309 | session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
310 | ) async -> String? {
311 | guard let result = try? await YouVersionAPI.Users.refreshSignIn(
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:64:51: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
62 | return BibleContentResponse(
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
65 | isCacheable: response.httpResponse.allowsCaching
66 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:65:48: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
65 | isCacheable: response.httpResponse.allowsCaching
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
66 | )
67 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:70: error: extra argument 'for' in call
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: extra argument 'for' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:64: error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
67 | }
68 |
69 | private static func response(
| `- note: 'response(at:accessToken:session:allowsNoContent:)' declared here
70 | at url: URL,
71 | accessToken: String?,
:
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:106:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
104 | /// `YouVersionAPIError.cannotDownload` for any other status.
105 | static func error(for httpResponse: HTTPURLResponse, data: Data) -> any Error {
106 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:108:60: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
106 | switch httpResponse.statusCode {
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
109 | return YouVersionAPIError.notPermitted
110 | default:
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:123:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
121 | static func responseError(for httpResponse: HTTPURLResponse, data: Data) -> YouVersionAPIResponseError? {
122 | let code: YouVersionAPIResponseError.Code
123 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
124 | case 401, 403:
125 | return nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:136:76: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
134 | }
135 |
136 | let body = ResponseErrorBody(data: data, contentType: httpResponse.value(forHTTPHeaderField: "Content-Type"))
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
137 | return YouVersionAPIResponseError(
138 | code: code,
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:139:38: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
137 | return YouVersionAPIResponseError(
138 | code: code,
139 | statusCode: httpResponse.statusCode,
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:141:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
139 | statusCode: httpResponse.statusCode,
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
142 | validationIssues: body.validationIssues
143 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:175:23: error: cannot find 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
| `- error: cannot find 'URLRequest' in scope
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:177:44: error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
178 | for (key, value) in additionalHeaders {
179 | guard let headerField = key as? String else { continue }
[493/505] Compiling YouVersionPlatformCore YouVersionAPI.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:109: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:123: error: value of type '_' expected to be instance of class or class-constrained type
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: value of type '_' expected to be instance of class or class-constrained type
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:123: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:22: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:36: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:36: error: value of type '_' expected to be instance of class or class-constrained type
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:22: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:36: error: value of type '_' expected to be instance of class or class-constrained type
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:36: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:47: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:61: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:61: error: value of type '_' expected to be instance of class or class-constrained type
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: value of type '_' expected to be instance of class or class-constrained type
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:28:62: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
26 | }
27 |
28 | static func accessToken(providedToken: String?, session: URLSession) async -> String? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
29 | if let providedToken {
30 | return providedToken
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:35:66: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
33 | }
34 |
35 | static func data(at url: URL, accessToken: String?, session: URLSession) async throws -> Data {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
36 | try await responseData(at: url, accessToken: accessToken, session: session).value
37 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:39:75: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 | }
38 |
39 | static func dataIfPresent(at url: URL, accessToken: String?, session: URLSession) async throws -> Data? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
40 | try await response(
41 | at: url,
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:51:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
49 | at url: URL,
50 | accessToken: String?,
51 | session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
52 | ) async throws -> BibleContentResponse<Data> {
53 | let response = try await response(
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:72:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
70 | at url: URL,
71 | accessToken: String?,
72 | session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
73 | allowsNoContent: Bool
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:74:51: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
72 | session: URLSession,
73 | allowsNoContent: Bool
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:105:41: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 | /// - Returns: `YouVersionAPIError.notPermitted` for `401` and `403`, and
104 | /// `YouVersionAPIError.cannotDownload` for any other status.
105 | static func error(for httpResponse: HTTPURLResponse, data: Data) -> any Error {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 | switch httpResponse.statusCode {
107 | case 401, 403:
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:121:49: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
119 | /// - data: The response body, which can carry a message from the server.
120 | /// - Returns: A ``YouVersionAPIResponseError`` for `4xx` and `5xx` statuses other than `401` and `403`, or `nil`.
121 | static func responseError(for httpResponse: HTTPURLResponse, data: Data) -> YouVersionAPIResponseError? {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
122 | let code: YouVersionAPIResponseError.Code
123 | switch httpResponse.statusCode {
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:174:10: error: cannot find type 'URLRequest' in scope
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:172:22: error: cannot find type 'URLRequest' in scope
170 | accessToken: String?,
171 | session: URLSession,
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
| `- error: cannot find type 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:171:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
169 | with url: URL,
170 | accessToken: String?,
171 | session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:259:31: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
257 | private var refreshTask: Task<String?, Never>?
258 |
259 | func accessToken(session: URLSession) async -> String? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
260 | guard let authData = YouVersionPlatformConfiguration.authData,
261 | let accessToken = authData.accessToken else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:309:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
307 | refreshToken: String,
308 | idToken: String?,
309 | session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
310 | ) async -> String? {
311 | guard let result = try? await YouVersionAPI.Users.refreshSignIn(
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:64:51: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
62 | return BibleContentResponse(
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
65 | isCacheable: response.httpResponse.allowsCaching
66 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:65:48: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
65 | isCacheable: response.httpResponse.allowsCaching
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
66 | )
67 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:70: error: extra argument 'for' in call
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: extra argument 'for' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:64: error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
67 | }
68 |
69 | private static func response(
| `- note: 'response(at:accessToken:session:allowsNoContent:)' declared here
70 | at url: URL,
71 | accessToken: String?,
:
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:106:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
104 | /// `YouVersionAPIError.cannotDownload` for any other status.
105 | static func error(for httpResponse: HTTPURLResponse, data: Data) -> any Error {
106 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:108:60: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
106 | switch httpResponse.statusCode {
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
109 | return YouVersionAPIError.notPermitted
110 | default:
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:123:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
121 | static func responseError(for httpResponse: HTTPURLResponse, data: Data) -> YouVersionAPIResponseError? {
122 | let code: YouVersionAPIResponseError.Code
123 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
124 | case 401, 403:
125 | return nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:136:76: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
134 | }
135 |
136 | let body = ResponseErrorBody(data: data, contentType: httpResponse.value(forHTTPHeaderField: "Content-Type"))
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
137 | return YouVersionAPIResponseError(
138 | code: code,
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:139:38: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
137 | return YouVersionAPIResponseError(
138 | code: code,
139 | statusCode: httpResponse.statusCode,
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:141:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
139 | statusCode: httpResponse.statusCode,
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
142 | validationIssues: body.validationIssues
143 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:175:23: error: cannot find 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
| `- error: cannot find 'URLRequest' in scope
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:177:44: error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
178 | for (key, value) in additionalHeaders {
179 | guard let headerField = key as? String else { continue }
[494/505] Compiling YouVersionPlatformCore BibleBook.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:109: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:123: error: value of type '_' expected to be instance of class or class-constrained type
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: value of type '_' expected to be instance of class or class-constrained type
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:123: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:22: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:36: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:36: error: value of type '_' expected to be instance of class or class-constrained type
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:22: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:36: error: value of type '_' expected to be instance of class or class-constrained type
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:36: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:47: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:61: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:61: error: value of type '_' expected to be instance of class or class-constrained type
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: value of type '_' expected to be instance of class or class-constrained type
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:28:62: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
26 | }
27 |
28 | static func accessToken(providedToken: String?, session: URLSession) async -> String? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
29 | if let providedToken {
30 | return providedToken
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:35:66: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
33 | }
34 |
35 | static func data(at url: URL, accessToken: String?, session: URLSession) async throws -> Data {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
36 | try await responseData(at: url, accessToken: accessToken, session: session).value
37 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:39:75: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 | }
38 |
39 | static func dataIfPresent(at url: URL, accessToken: String?, session: URLSession) async throws -> Data? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
40 | try await response(
41 | at: url,
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:51:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
49 | at url: URL,
50 | accessToken: String?,
51 | session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
52 | ) async throws -> BibleContentResponse<Data> {
53 | let response = try await response(
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:72:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
70 | at url: URL,
71 | accessToken: String?,
72 | session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
73 | allowsNoContent: Bool
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:74:51: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
72 | session: URLSession,
73 | allowsNoContent: Bool
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:105:41: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 | /// - Returns: `YouVersionAPIError.notPermitted` for `401` and `403`, and
104 | /// `YouVersionAPIError.cannotDownload` for any other status.
105 | static func error(for httpResponse: HTTPURLResponse, data: Data) -> any Error {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 | switch httpResponse.statusCode {
107 | case 401, 403:
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:121:49: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
119 | /// - data: The response body, which can carry a message from the server.
120 | /// - Returns: A ``YouVersionAPIResponseError`` for `4xx` and `5xx` statuses other than `401` and `403`, or `nil`.
121 | static func responseError(for httpResponse: HTTPURLResponse, data: Data) -> YouVersionAPIResponseError? {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
122 | let code: YouVersionAPIResponseError.Code
123 | switch httpResponse.statusCode {
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:174:10: error: cannot find type 'URLRequest' in scope
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:172:22: error: cannot find type 'URLRequest' in scope
170 | accessToken: String?,
171 | session: URLSession,
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
| `- error: cannot find type 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:171:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
169 | with url: URL,
170 | accessToken: String?,
171 | session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:259:31: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
257 | private var refreshTask: Task<String?, Never>?
258 |
259 | func accessToken(session: URLSession) async -> String? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
260 | guard let authData = YouVersionPlatformConfiguration.authData,
261 | let accessToken = authData.accessToken else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:309:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
307 | refreshToken: String,
308 | idToken: String?,
309 | session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
310 | ) async -> String? {
311 | guard let result = try? await YouVersionAPI.Users.refreshSignIn(
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:64:51: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
62 | return BibleContentResponse(
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
65 | isCacheable: response.httpResponse.allowsCaching
66 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:65:48: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
65 | isCacheable: response.httpResponse.allowsCaching
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
66 | )
67 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:70: error: extra argument 'for' in call
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: extra argument 'for' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:64: error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
67 | }
68 |
69 | private static func response(
| `- note: 'response(at:accessToken:session:allowsNoContent:)' declared here
70 | at url: URL,
71 | accessToken: String?,
:
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:106:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
104 | /// `YouVersionAPIError.cannotDownload` for any other status.
105 | static func error(for httpResponse: HTTPURLResponse, data: Data) -> any Error {
106 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:108:60: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
106 | switch httpResponse.statusCode {
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
109 | return YouVersionAPIError.notPermitted
110 | default:
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:123:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
121 | static func responseError(for httpResponse: HTTPURLResponse, data: Data) -> YouVersionAPIResponseError? {
122 | let code: YouVersionAPIResponseError.Code
123 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
124 | case 401, 403:
125 | return nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:136:76: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
134 | }
135 |
136 | let body = ResponseErrorBody(data: data, contentType: httpResponse.value(forHTTPHeaderField: "Content-Type"))
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
137 | return YouVersionAPIResponseError(
138 | code: code,
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:139:38: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
137 | return YouVersionAPIResponseError(
138 | code: code,
139 | statusCode: httpResponse.statusCode,
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:141:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
139 | statusCode: httpResponse.statusCode,
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
142 | validationIssues: body.validationIssues
143 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:175:23: error: cannot find 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
| `- error: cannot find 'URLRequest' in scope
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:177:44: error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
178 | for (key, value) in additionalHeaders {
179 | guard let headerField = key as? String else { continue }
[495/505] Compiling YouVersionPlatformCore BibleBookIntro.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:109: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:123: error: value of type '_' expected to be instance of class or class-constrained type
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: value of type '_' expected to be instance of class or class-constrained type
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:21:123: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
19 | /// - `URLError.badServerResponse` if the server response could not be decoded.
20 | /// - `YouVersionAPIError.notPermitted` if the request is unauthorized or forbidden.
21 | public static func verseOfTheDay(dayOfYear: Int, accessToken providedToken: String? = nil, session: URLSession = .shared) async throws -> YouVersionVerseOfTheDay {
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
22 | try await verseOfTheDay(dayOfYear: dayOfYear, languageRanges: [], accessToken: providedToken, session: session)
23 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:22: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:36: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:43:36: error: value of type '_' expected to be instance of class or class-constrained type
41 | languageRanges: [String],
42 | accessToken providedToken: String? = nil,
43 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
44 | ) async throws -> YouVersionVerseOfTheDay {
45 | guard let url = URLBuilder.votdURL(dayOfYear: dayOfYear, languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:22: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:36: error: value of type '_' expected to be instance of class or class-constrained type
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/VOTD/VOTD.swift:75:36: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
73 | languageRanges: [String] = [],
74 | accessToken providedToken: String? = nil,
75 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
76 | ) async throws -> [YouVersionVerseOfTheDay] {
77 | guard let url = URLBuilder.votdCollectionURL(languageRanges: languageRanges) else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:47: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:61: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:24:61: error: value of type '_' expected to be instance of class or class-constrained type
22 |
23 | /// This can cause a token refresh if an access token is present but is old.
24 | public static func hasValidToken(session: URLSession = .shared) async -> Bool {
| `- error: value of type '_' expected to be instance of class or class-constrained type
25 | await accessTokenProvider.accessToken(session: session) != nil
26 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:28:62: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
26 | }
27 |
28 | static func accessToken(providedToken: String?, session: URLSession) async -> String? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
29 | if let providedToken {
30 | return providedToken
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:35:66: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
33 | }
34 |
35 | static func data(at url: URL, accessToken: String?, session: URLSession) async throws -> Data {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
36 | try await responseData(at: url, accessToken: accessToken, session: session).value
37 | }
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:39:75: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
37 | }
38 |
39 | static func dataIfPresent(at url: URL, accessToken: String?, session: URLSession) async throws -> Data? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
40 | try await response(
41 | at: url,
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:51:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
49 | at url: URL,
50 | accessToken: String?,
51 | session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
52 | ) async throws -> BibleContentResponse<Data> {
53 | let response = try await response(
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:72:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
70 | at url: URL,
71 | accessToken: String?,
72 | session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
73 | allowsNoContent: Bool
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:74:51: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
72 | session: URLSession,
73 | allowsNoContent: Bool
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:105:41: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
103 | /// - Returns: `YouVersionAPIError.notPermitted` for `401` and `403`, and
104 | /// `YouVersionAPIError.cannotDownload` for any other status.
105 | static func error(for httpResponse: HTTPURLResponse, data: Data) -> any Error {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
106 | switch httpResponse.statusCode {
107 | case 401, 403:
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:121:49: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
119 | /// - data: The response body, which can carry a message from the server.
120 | /// - Returns: A ``YouVersionAPIResponseError`` for `4xx` and `5xx` statuses other than `401` and `403`, or `nil`.
121 | static func responseError(for httpResponse: HTTPURLResponse, data: Data) -> YouVersionAPIResponseError? {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
122 | let code: YouVersionAPIResponseError.Code
123 | switch httpResponse.statusCode {
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:174:10: error: cannot find type 'URLRequest' in scope
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:172:22: error: cannot find type 'URLRequest' in scope
170 | accessToken: String?,
171 | session: URLSession,
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
| `- error: cannot find type 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:171:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
169 | with url: URL,
170 | accessToken: String?,
171 | session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
172 | cachePolicy: URLRequest.CachePolicy = .useProtocolCachePolicy,
173 | omitAccessToken: Bool = false
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:259:31: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
257 | private var refreshTask: Task<String?, Never>?
258 |
259 | func accessToken(session: URLSession) async -> String? {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
260 | guard let authData = YouVersionPlatformConfiguration.authData,
261 | let accessToken = authData.accessToken else {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:309:18: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
307 | refreshToken: String,
308 | idToken: String?,
309 | session: URLSession
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
310 | ) async -> String? {
311 | guard let result = try? await YouVersionAPI.Users.refreshSignIn(
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:64:51: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
62 | return BibleContentResponse(
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'cacheExpirationDate'
65 | isCacheable: response.httpResponse.allowsCaching
66 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:65:48: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
63 | value: data,
64 | expirationDate: response.httpResponse.cacheExpirationDate(),
65 | isCacheable: response.httpResponse.allowsCaching
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allowsCaching'
66 | )
67 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:70: error: extra argument 'for' in call
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: extra argument 'for' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:76:64: error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
67 | }
68 |
69 | private static func response(
| `- note: 'response(at:accessToken:session:allowsNoContent:)' declared here
70 | at url: URL,
71 | accessToken: String?,
:
74 | ) async throws -> (data: Data?, httpResponse: HTTPURLResponse) {
75 | let request = urlRequest(with: url, accessToken: accessToken, session: session)
76 | let (data, response) = try await YouVersionAPI.response(for: request, session: session)
| `- error: missing arguments for parameters 'at', 'accessToken', 'allowsNoContent' in call
77 |
78 | guard let httpResponse = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:106:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
104 | /// `YouVersionAPIError.cannotDownload` for any other status.
105 | static func error(for httpResponse: HTTPURLResponse, data: Data) -> any Error {
106 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:108:60: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
106 | switch httpResponse.statusCode {
107 | case 401, 403:
108 | YouVersionPlatformLogger.error("\(httpResponse.statusCode): not permitted; check your appKey and its entitlements.", category: "API")
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
109 | return YouVersionAPIError.notPermitted
110 | default:
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:123:29: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
121 | static func responseError(for httpResponse: HTTPURLResponse, data: Data) -> YouVersionAPIResponseError? {
122 | let code: YouVersionAPIResponseError.Code
123 | switch httpResponse.statusCode {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
124 | case 401, 403:
125 | return nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:136:76: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
134 | }
135 |
136 | let body = ResponseErrorBody(data: data, contentType: httpResponse.value(forHTTPHeaderField: "Content-Type"))
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
137 | return YouVersionAPIResponseError(
138 | code: code,
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:139:38: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
137 | return YouVersionAPIResponseError(
138 | code: code,
139 | statusCode: httpResponse.statusCode,
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:141:69: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
139 | statusCode: httpResponse.statusCode,
140 | message: body.message,
141 | retryAfterSeconds: retryAfterSeconds(from: httpResponse.value(forHTTPHeaderField: "Retry-After")),
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
142 | validationIssues: body.validationIssues
143 | )
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:175:23: error: cannot find 'URLRequest' in scope
173 | omitAccessToken: Bool = false
174 | ) -> URLRequest {
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
| `- error: cannot find 'URLRequest' in scope
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/YouVersionAPI.swift:177:44: error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
175 | var request = URLRequest.youVersion(url, accessToken: accessToken, cachePolicy: cachePolicy, omitAccessToken: omitAccessToken)
176 |
177 | if let additionalHeaders = session.configuration.httpAdditionalHeaders {
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'configuration'
178 | for (key, value) in additionalHeaders {
179 | guard let headerField = key as? String else { continue }
[496/505] Compiling YouVersionPlatformCore BibleChapter.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: value of type '_' expected to be instance of class or class-constrained type
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Bible/BibleContentStorage.swift:152:58: error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
150 | }
151 |
152 | try data.write(to: url(for: resource), options: .atomic)
| `- error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
153 | }
154 |
FoundationEssentials.Data.WritingOptions.atomic:4:23: note: 'atomic' has been explicitly marked unavailable here
2 | struct WritingOptions {
3 | @available(*, unavailable, message: "atomic writing is unavailable in WASI because temporary files are not supported")
4 | public static let atomic: Data.WritingOptions }
| `- note: 'atomic' has been explicitly marked unavailable here
5 | }
6 |
[497/505] Compiling YouVersionPlatformCore BibleChapterRepository.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: value of type '_' expected to be instance of class or class-constrained type
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Bible/BibleContentStorage.swift:152:58: error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
150 | }
151 |
152 | try data.write(to: url(for: resource), options: .atomic)
| `- error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
153 | }
154 |
FoundationEssentials.Data.WritingOptions.atomic:4:23: note: 'atomic' has been explicitly marked unavailable here
2 | struct WritingOptions {
3 | @available(*, unavailable, message: "atomic writing is unavailable in WASI because temporary files are not supported")
4 | public static let atomic: Data.WritingOptions }
| `- note: 'atomic' has been explicitly marked unavailable here
5 | }
6 |
[498/505] Compiling YouVersionPlatformCore BibleContentStorage.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: value of type '_' expected to be instance of class or class-constrained type
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Bible/BibleContentStorage.swift:152:58: error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
150 | }
151 |
152 | try data.write(to: url(for: resource), options: .atomic)
| `- error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
153 | }
154 |
FoundationEssentials.Data.WritingOptions.atomic:4:23: note: 'atomic' has been explicitly marked unavailable here
2 | struct WritingOptions {
3 | @available(*, unavailable, message: "atomic writing is unavailable in WASI because temporary files are not supported")
4 | public static let atomic: Data.WritingOptions }
| `- note: 'atomic' has been explicitly marked unavailable here
5 | }
6 |
[499/505] Compiling YouVersionPlatformCore BibleHighlight.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: value of type '_' expected to be instance of class or class-constrained type
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Bible/BibleContentStorage.swift:152:58: error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
150 | }
151 |
152 | try data.write(to: url(for: resource), options: .atomic)
| `- error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
153 | }
154 |
FoundationEssentials.Data.WritingOptions.atomic:4:23: note: 'atomic' has been explicitly marked unavailable here
2 | struct WritingOptions {
3 | @available(*, unavailable, message: "atomic writing is unavailable in WASI because temporary files are not supported")
4 | public static let atomic: Data.WritingOptions }
| `- note: 'atomic' has been explicitly marked unavailable here
5 | }
6 |
[500/505] Compiling YouVersionPlatformCore BibleHighlightsCache.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: value of type '_' expected to be instance of class or class-constrained type
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: value of type '_' expected to be instance of class or class-constrained type
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/APIs/Bible/BibleVersionAPI.swift:135:32: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
133 | reference: BibleReference,
134 | accessToken providedToken: String? = nil,
135 | session: URLSession = .shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
136 | ) async throws -> BibleContentResponse<String> {
137 | let accessToken = providedToken ?? YouVersionPlatformConfiguration.accessToken
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Bible/BibleContentStorage.swift:152:58: error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
150 | }
151 |
152 | try data.write(to: url(for: resource), options: .atomic)
| `- error: 'atomic' is unavailable: atomic writing is unavailable in WASI because temporary files are not supported
153 | }
154 |
FoundationEssentials.Data.WritingOptions.atomic:4:23: note: 'atomic' has been explicitly marked unavailable here
2 | struct WritingOptions {
3 | @available(*, unavailable, message: "atomic writing is unavailable in WASI because temporary files are not supported")
4 | public static let atomic: Data.WritingOptions }
| `- note: 'atomic' has been explicitly marked unavailable here
5 | }
6 |
[501/505] Compiling YouVersionPlatformCore APIRequestDiagnostics.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:60: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:95: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:23:43: error: cannot find type 'URLRequest' in scope
21 | struct APIRequestDiagnostics {
22 | /// Identifies the request without exposing credentials in its URL or headers.
23 | static func requestSummary(_ request: URLRequest) -> String {
| `- error: cannot find type 'URLRequest' in scope
24 | var components = request.url.flatMap { URLComponents(url: $0, resolvingAgainstBaseURL: false) }
25 | components?.user = nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:44: error: cannot find type 'URLRequest' in scope
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: cannot find type 'URLRequest' in scope
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:78: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:11:54: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
11 | let (data, response) = try await session.data(for: request)
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
12 | YouVersionPlatformLogger.debug(APIRequestDiagnostics.responseSummary(request, data: data, response: response), category: "API")
13 | return (data, response)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:39: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:43: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:54:49: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:56:37: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
57 | message += " \(field)=\(value)"
58 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:60:43: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
58 | }
59 | }
60 | if !(200..<300).contains(response.statusCode) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
62 | let parts = value.split(separator: " ", maxSplits: 1)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:61:17: error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
59 | }
60 | if !(200..<300).contains(response.statusCode) {
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
| `- error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
62 | let parts = value.split(separator: " ", maxSplits: 1)
63 | return parts.count == 2 && ["bearer", "basic"].contains(parts[0].lowercased()) ? [value, String(parts[1])] : [value]
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:9: error: cannot find 'NotificationCenter' in scope
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: cannot find 'NotificationCenter' in scope
167 | }
168 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:87: error: 'nil' requires a contextual type
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: 'nil' requires a contextual type
167 | }
168 |
[502/505] Compiling YouVersionPlatformCore YouVersionPlatformLogger.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:60: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:95: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:23:43: error: cannot find type 'URLRequest' in scope
21 | struct APIRequestDiagnostics {
22 | /// Identifies the request without exposing credentials in its URL or headers.
23 | static func requestSummary(_ request: URLRequest) -> String {
| `- error: cannot find type 'URLRequest' in scope
24 | var components = request.url.flatMap { URLComponents(url: $0, resolvingAgainstBaseURL: false) }
25 | components?.user = nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:44: error: cannot find type 'URLRequest' in scope
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: cannot find type 'URLRequest' in scope
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:78: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:11:54: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
11 | let (data, response) = try await session.data(for: request)
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
12 | YouVersionPlatformLogger.debug(APIRequestDiagnostics.responseSummary(request, data: data, response: response), category: "API")
13 | return (data, response)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:39: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:43: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:54:49: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:56:37: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
57 | message += " \(field)=\(value)"
58 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:60:43: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
58 | }
59 | }
60 | if !(200..<300).contains(response.statusCode) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
62 | let parts = value.split(separator: " ", maxSplits: 1)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:61:17: error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
59 | }
60 | if !(200..<300).contains(response.statusCode) {
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
| `- error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
62 | let parts = value.split(separator: " ", maxSplits: 1)
63 | return parts.count == 2 && ["bearer", "basic"].contains(parts[0].lowercased()) ? [value, String(parts[1])] : [value]
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:9: error: cannot find 'NotificationCenter' in scope
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: cannot find 'NotificationCenter' in scope
167 | }
168 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:87: error: 'nil' requires a contextual type
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: 'nil' requires a contextual type
167 | }
168 |
[503/505] Compiling YouVersionPlatformCore SDKVersion.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:60: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:95: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:23:43: error: cannot find type 'URLRequest' in scope
21 | struct APIRequestDiagnostics {
22 | /// Identifies the request without exposing credentials in its URL or headers.
23 | static func requestSummary(_ request: URLRequest) -> String {
| `- error: cannot find type 'URLRequest' in scope
24 | var components = request.url.flatMap { URLComponents(url: $0, resolvingAgainstBaseURL: false) }
25 | components?.user = nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:44: error: cannot find type 'URLRequest' in scope
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: cannot find type 'URLRequest' in scope
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:78: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:11:54: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
11 | let (data, response) = try await session.data(for: request)
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
12 | YouVersionPlatformLogger.debug(APIRequestDiagnostics.responseSummary(request, data: data, response: response), category: "API")
13 | return (data, response)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:39: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:43: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:54:49: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:56:37: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
57 | message += " \(field)=\(value)"
58 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:60:43: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
58 | }
59 | }
60 | if !(200..<300).contains(response.statusCode) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
62 | let parts = value.split(separator: " ", maxSplits: 1)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:61:17: error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
59 | }
60 | if !(200..<300).contains(response.statusCode) {
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
| `- error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
62 | let parts = value.split(separator: " ", maxSplits: 1)
63 | return parts.count == 2 && ["bearer", "basic"].contains(parts[0].lowercased()) ? [value, String(parts[1])] : [value]
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:9: error: cannot find 'NotificationCenter' in scope
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: cannot find 'NotificationCenter' in scope
167 | }
168 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:87: error: 'nil' requires a contextual type
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: 'nil' requires a contextual type
167 | }
168 |
[504/505] Compiling YouVersionPlatformCore AbbreviationSplitting.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:60: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:95: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:23:43: error: cannot find type 'URLRequest' in scope
21 | struct APIRequestDiagnostics {
22 | /// Identifies the request without exposing credentials in its URL or headers.
23 | static func requestSummary(_ request: URLRequest) -> String {
| `- error: cannot find type 'URLRequest' in scope
24 | var components = request.url.flatMap { URLComponents(url: $0, resolvingAgainstBaseURL: false) }
25 | components?.user = nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:44: error: cannot find type 'URLRequest' in scope
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: cannot find type 'URLRequest' in scope
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:78: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:11:54: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
11 | let (data, response) = try await session.data(for: request)
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
12 | YouVersionPlatformLogger.debug(APIRequestDiagnostics.responseSummary(request, data: data, response: response), category: "API")
13 | return (data, response)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:39: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:43: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:54:49: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:56:37: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
57 | message += " \(field)=\(value)"
58 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:60:43: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
58 | }
59 | }
60 | if !(200..<300).contains(response.statusCode) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
62 | let parts = value.split(separator: " ", maxSplits: 1)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:61:17: error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
59 | }
60 | if !(200..<300).contains(response.statusCode) {
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
| `- error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
62 | let parts = value.split(separator: " ", maxSplits: 1)
63 | return parts.count == 2 && ["bearer", "basic"].contains(parts[0].lowercased()) ? [value, String(parts[1])] : [value]
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:9: error: cannot find 'NotificationCenter' in scope
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: cannot find 'NotificationCenter' in scope
167 | }
168 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:87: error: 'nil' requires a contextual type
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: 'nil' requires a contextual type
167 | }
168 |
[505/505] Compiling YouVersionPlatformCore YouVersionPlatformConfiguration.swift
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:39: error: cannot find type 'URLRequest' in scope
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: cannot find type 'URLRequest' in scope
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:60: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
| `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:8:95: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
6 | extension YouVersionAPI {
7 | /// Performs an SDK request with debug-only diagnostics, preserving responses and thrown errors.
8 | static func response(for request: URLRequest, session: URLSession) async throws -> (Data, URLResponse) {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:23:43: error: cannot find type 'URLRequest' in scope
21 | struct APIRequestDiagnostics {
22 | /// Identifies the request without exposing credentials in its URL or headers.
23 | static func requestSummary(_ request: URLRequest) -> String {
| `- error: cannot find type 'URLRequest' in scope
24 | var components = request.url.flatMap { URLComponents(url: $0, resolvingAgainstBaseURL: false) }
25 | components?.user = nil
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:44: error: cannot find type 'URLRequest' in scope
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: cannot find type 'URLRequest' in scope
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:49:78: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
47 |
48 | /// Includes redacted error bodies and correlation IDs, but never successful response bodies.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLResponse = AnyObject
| `- note: 'URLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:11:54: error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
9 | YouVersionPlatformLogger.debug("Sending \(APIRequestDiagnostics.requestSummary(request))", category: "API")
10 | do {
11 | let (data, response) = try await session.data(for: request)
| `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'data'
12 | YouVersionPlatformLogger.debug(APIRequestDiagnostics.responseSummary(request, data: data, response: response), category: "API")
13 | return (data, response)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:39: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:51:43: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
49 | static func responseSummary(_ request: URLRequest, data: Data, response: URLResponse) -> String {
50 | let summary = requestSummary(request)
51 | guard let response = response as? HTTPURLResponse else {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
Foundation.HTTPURLResponse:2:18: note: 'HTTPURLResponse' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias HTTPURLResponse = AnyObject
| `- note: 'HTTPURLResponse' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:54:49: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
52 | return "Received non-HTTP response for \(summary): \(type(of: response))"
53 | }
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:56:37: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
54 | var message = "Received HTTP \(response.statusCode) for \(summary) (\(data.count) bytes)"
55 | for field in ["content-type", "x-request-id", "x-correlation-id", "x-cloud-trace-context", "traceparent"] {
56 | if let value = response.value(forHTTPHeaderField: field) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'value'
57 | message += " \(field)=\(value)"
58 | }
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:60:43: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
58 | }
59 | }
60 | if !(200..<300).contains(response.statusCode) {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
62 | let parts = value.split(separator: " ", maxSplits: 1)
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/Logging/APIRequestDiagnostics.swift:61:17: error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
59 | }
60 | if !(200..<300).contains(response.statusCode) {
61 | let secrets = (request.allHTTPHeaderFields ?? [:]).filter { isSensitive($0.key) }.values.flatMap { value in
| `- error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
62 | let parts = value.split(separator: " ", maxSplits: 1)
63 | return parts.count == 2 && ["bearer", "basic"].contains(parts[0].lowercased()) ? [value, String(parts[1])] : [value]
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:9: error: cannot find 'NotificationCenter' in scope
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: cannot find 'NotificationCenter' in scope
167 | }
168 |
/host/spi-builder-workspace/Sources/YouVersionPlatformCore/YouVersionPlatformConfiguration.swift:166:87: error: 'nil' requires a contextual type
164 | return
165 | }
166 | NotificationCenter.default.post(name: authStateDidChangeNotification, object: nil)
| `- error: 'nil' requires a contextual type
167 | }
168 |
BUILD FAILURE 6.2 wasm