Build Information
Failed to build Replay, reference main (90f2d5), with Swift 6.1 for Wasm on 27 Nov 2026 05:09:35 UTC.
Build Command
bash -c docker run --pull=always --rm -v "checkouts-53886768-0":/host -w "$PWD" -e JAVA_HOME="/root/.sdkman/candidates/java/current" -e SPI_BUILD="1" -e SPI_PROCESSING="1" registry.gitlab.com/saguaro1/spi-images:wasm-6.1-latest swift build --swift-sdk wasm32-unknown-wasi 2>&1Build Log
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLProtocol = AnyObject
| `- note: 'URLProtocol' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:520:42: error: cannot find type 'URLSessionDataDelegate' in scope
518 |
519 | /// A delegate that bridges URLSession callbacks to async streams for SSE support.
520 | final class StreamingDelegate: NSObject, URLSessionDataDelegate, @unchecked Sendable {
| `- error: cannot find type 'URLSessionDataDelegate' in scope
521 | /// The response hand-off between URLSession's delegate queue and `waitForResponse()`.
522 | /// URLSession can deliver the response, or fail, before the caller starts to wait.
/host/spi-builder-workspace/Sources/Replay/Playback.swift:525:42: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
523 | private enum ResponseState {
524 | case pending
525 | case waiting(CheckedContinuation<HTTPURLResponse, Error>)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
526 | case ready(Result<HTTPURLResponse, Error>)
527 | case delivered
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/Replay/Playback.swift:526:27: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
524 | case pending
525 | case waiting(CheckedContinuation<HTTPURLResponse, Error>)
526 | case ready(Result<HTTPURLResponse, Error>)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
527 | case delivered
528 | }
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/Replay/Playback.swift:551:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
549 | ///
550 | /// Call this method at most once.
551 | func waitForResponse() async throws -> HTTPURLResponse {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
552 | try await withCheckedThrowingContinuation { continuation in
553 | lock.lock()
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/Replay/Playback.swift:570:50: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
568 |
569 | /// Settles the response with the first result; later results are ignored.
570 | private func settleResponse(_ result: Result<HTTPURLResponse, Error>) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
571 | lock.lock()
572 | switch responseState {
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/Replay/Playback.swift:587:50: error: 'ResponseDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
585 | func urlSession(
586 | _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse,
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
| `- error: 'ResponseDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
588 | ) {
589 | if let httpResponse = response as? HTTPURLResponse {
/host/spi-builder-workspace/Sources/Replay/Playback.swift:586:20: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
584 |
585 | func urlSession(
586 | _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
588 | ) {
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/Replay/Playback.swift:586:42: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
584 |
585 | func urlSession(
586 | _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse,
| `- error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
588 | ) {
Foundation.URLSessionDataTask:2:18: note: 'URLSessionDataTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionDataTask = AnyObject
| `- note: 'URLSessionDataTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:586:83: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
584 |
585 | func urlSession(
586 | _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse,
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
588 | ) {
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/Replay/Playback.swift:595:32: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
593 | }
594 |
595 | func urlSession(_ session: URLSession, dataTask: URLSessionDataTask, didReceive data: Data) {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
596 | dataContinuation.yield(data)
597 | }
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/Replay/Playback.swift:595:54: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
593 | }
594 |
595 | func urlSession(_ session: URLSession, dataTask: URLSessionDataTask, didReceive data: Data) {
| `- error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
596 | dataContinuation.yield(data)
597 | }
Foundation.URLSessionDataTask:2:18: note: 'URLSessionDataTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionDataTask = AnyObject
| `- note: 'URLSessionDataTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:605:50: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
603 | _ session: URLSession,
604 | didReceive challenge: URLAuthenticationChallenge,
605 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
606 | ) {
607 | forward(challenge, completionHandler: completionHandler)
/host/spi-builder-workspace/Sources/Replay/Playback.swift:603:20: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
601 | // forwarded, otherwise trust decisions silently fall back to default handling.
602 | func urlSession(
603 | _ session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
604 | didReceive challenge: URLAuthenticationChallenge,
605 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
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/Replay/Playback.swift:604:31: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
602 | func urlSession(
603 | _ session: URLSession,
604 | didReceive challenge: URLAuthenticationChallenge,
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
605 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
606 | ) {
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:614:50: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
612 | task: URLSessionTask,
613 | didReceive challenge: URLAuthenticationChallenge,
614 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
615 | ) {
616 | forward(challenge, completionHandler: completionHandler)
/host/spi-builder-workspace/Sources/Replay/Playback.swift:611:20: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
609 |
610 | func urlSession(
611 | _ session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
612 | task: URLSessionTask,
613 | didReceive challenge: URLAuthenticationChallenge,
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/Replay/Playback.swift:612:15: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
610 | func urlSession(
611 | _ session: URLSession,
612 | task: URLSessionTask,
| `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
613 | didReceive challenge: URLAuthenticationChallenge,
614 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
Foundation.URLSessionTask:2:18: note: 'URLSessionTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionTask = AnyObject
| `- note: 'URLSessionTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:613:31: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
611 | _ session: URLSession,
612 | task: URLSessionTask,
613 | didReceive challenge: URLAuthenticationChallenge,
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
614 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
615 | ) {
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:621:50: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
619 | private func forward(
620 | _ challenge: URLAuthenticationChallenge,
621 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
622 | ) {
623 | guard let urlProtocol, let client = urlProtocol.client else {
/host/spi-builder-workspace/Sources/Replay/Playback.swift:620:22: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
618 |
619 | private func forward(
620 | _ challenge: URLAuthenticationChallenge,
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
621 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
622 | ) {
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:642:32: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
640 | }
641 |
642 | func urlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?) {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
643 | if let error = error {
644 | settleResponse(.failure(error))
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/Replay/Playback.swift:642:50: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
640 | }
641 |
642 | func urlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?) {
| `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
643 | if let error = error {
644 | settleResponse(.failure(error))
Foundation.URLSessionTask:2:18: note: 'URLSessionTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionTask = AnyObject
| `- note: 'URLSessionTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:659:51: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
657 | private var completionHandler: ((URLSession.AuthChallengeDisposition, URLCredential?) -> Void)?
658 |
659 | init(completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) {
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
660 | self.completionHandler = completionHandler
661 | }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:655:59: error: cannot find type 'URLAuthenticationChallengeSender' in scope
653 |
654 | /// Bridges URLProtocolClient challenge decisions back into URLSession's challenge completion handler.
655 | private final class PlaybackChallengeForwarder: NSObject, URLAuthenticationChallengeSender, @unchecked Sendable {
| `- error: cannot find type 'URLAuthenticationChallengeSender' in scope
656 | private let lock = NSLock()
657 | private var completionHandler: ((URLSession.AuthChallengeDisposition, URLCredential?) -> Void)?
/host/spi-builder-workspace/Sources/Replay/Playback.swift:657:49: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
655 | private final class PlaybackChallengeForwarder: NSObject, URLAuthenticationChallengeSender, @unchecked Sendable {
656 | private let lock = NSLock()
657 | private var completionHandler: ((URLSession.AuthChallengeDisposition, URLCredential?) -> Void)?
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
658 |
659 | init(completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) {
/host/spi-builder-workspace/Sources/Replay/Playback.swift:663:28: error: 'URLCredential' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
661 | }
662 |
663 | func use(_ credential: URLCredential, for challenge: URLAuthenticationChallenge) {
| `- error: 'URLCredential' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
664 | complete(.useCredential, credential)
665 | }
Foundation.URLCredential:2:18: note: 'URLCredential' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLCredential = AnyObject
| `- note: 'URLCredential' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:663:58: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
661 | }
662 |
663 | func use(_ credential: URLCredential, for challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
664 | complete(.useCredential, credential)
665 | }
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:667:51: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
665 | }
666 |
667 | func continueWithoutCredential(for challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
668 | // "Continue without a credential" maps to URLSession's default handling,
669 | // not to `.useCredential` with a nil credential.
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:673:30: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
671 | }
672 |
673 | func cancel(_ challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
674 | complete(.cancelAuthenticationChallenge, nil)
675 | }
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:677:48: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
675 | }
676 |
677 | func performDefaultHandling(for challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
678 | complete(.performDefaultHandling, nil)
679 | }
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:681:59: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
679 | }
680 |
681 | func rejectProtectionSpaceAndContinue(with challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
682 | complete(.rejectProtectionSpace, nil)
683 | }
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:685:53: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
683 | }
684 |
685 | private func complete(_ disposition: URLSession.AuthChallengeDisposition, _ credential: URLCredential?) {
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
686 | // A challenge sender may receive more than one callback from a defensive client;
687 | // URLSession completion handlers must only be invoked once.
/host/spi-builder-workspace/Sources/Replay/Playback.swift:685:93: error: 'URLCredential' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
683 | }
684 |
685 | private func complete(_ disposition: URLSession.AuthChallengeDisposition, _ credential: URLCredential?) {
| `- error: 'URLCredential' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
686 | // A challenge sender may receive more than one callback from a defensive client;
687 | // URLSession completion handlers must only be invoked once.
Foundation.URLCredential:2:18: note: 'URLCredential' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLCredential = AnyObject
| `- note: 'URLCredential' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:804:23: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
802 | public enum RequestDisposition: Sendable {
803 | /// Use the recorded entry's response.
804 | case recorded(HTTPURLResponse, Data)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
805 | /// No match found; go to the network (with optional recording).
806 | case network(shouldRecord: Bool)
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/Replay/Playback.swift:804:14: error: associated value 'recorded' of 'Sendable'-conforming enum 'RequestDisposition' has non-sendable type 'HTTPURLResponse' (aka 'AnyObject')
802 | public enum RequestDisposition: Sendable {
803 | /// Use the recorded entry's response.
804 | case recorded(HTTPURLResponse, Data)
| `- error: associated value 'recorded' of 'Sendable'-conforming enum 'RequestDisposition' has non-sendable type 'HTTPURLResponse' (aka 'AnyObject')
805 | /// No match found; go to the network (with optional recording).
806 | case network(shouldRecord: Bool)
/host/spi-builder-workspace/Sources/Replay/Playback.swift:818:41: error: cannot find type 'URLRequest' in scope
816 | /// - Parameter request: The request to check.
817 | /// - Returns: A disposition indicating how to handle the request.
818 | public func checkRequest(_ request: URLRequest) throws -> RequestDisposition {
| `- error: cannot find type 'URLRequest' in scope
819 | guard let config = configuration else {
820 | throw ReplayError.notConfigured
/host/spi-builder-workspace/Sources/Replay/Playback.swift:869:18: error: cannot find type 'URLRequest' in scope
867 | /// - duration: How long the request took.
868 | public func recordResponse(
869 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
870 | response: HTTPURLResponse,
871 | data: Data,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:870:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
868 | public func recordResponse(
869 | request: URLRequest,
870 | response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
871 | data: Data,
872 | duration: TimeInterval,
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/Replay/Playback.swift:932:42: error: cannot find type 'URLRequest' in scope
930 | /// responses like Server-Sent Events. For streaming support, use `checkRequest(_:)`
931 | /// and handle network requests with `URLSession.bytes(for:)`.
932 | public func handleRequest(_ request: URLRequest) async throws -> (HTTPURLResponse, Data) {
| `- error: cannot find type 'URLRequest' in scope
933 | switch try checkRequest(request) {
934 | case .recorded(let response, let data):
/host/spi-builder-workspace/Sources/Replay/Playback.swift:932:71: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
930 | /// responses like Server-Sent Events. For streaming support, use `checkRequest(_:)`
931 | /// and handle network requests with `URLSession.bytes(for:)`.
932 | public func handleRequest(_ request: URLRequest) async throws -> (HTTPURLResponse, Data) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
933 | switch try checkRequest(request) {
934 | case .recorded(let response, let data):
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/Replay/Playback.swift:20:32: error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
18 | ) async throws -> URLSession {
19 | let config = baseConfiguration
20 | var protocols = config.protocolClasses ?? []
| `- error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
21 | protocols.insert(PlaybackURLProtocol.self, at: 0)
22 | config.protocolClasses = protocols
/host/spi-builder-workspace/Sources/Replay/Playback.swift:22:16: error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
20 | var protocols = config.protocolClasses ?? []
21 | protocols.insert(PlaybackURLProtocol.self, at: 0)
22 | config.protocolClasses = protocols
| `- error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
23 |
24 | // Prefer isolation: configure a dedicated store and route requests to it via header.
/host/spi-builder-workspace/Sources/Replay/Playback.swift:30:30: error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'httpAdditionalHeaders'
28 | let key = PlaybackStoreRegistry.shared.register(store)
29 |
30 | var headers = config.httpAdditionalHeaders ?? [:]
| `- error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'httpAdditionalHeaders'
31 | headers[ReplayProtocolContext.headerName] = key
32 | config.httpAdditionalHeaders = headers
/host/spi-builder-workspace/Sources/Replay/Playback.swift:32:16: error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'httpAdditionalHeaders'
30 | var headers = config.httpAdditionalHeaders ?? [:]
31 | headers[ReplayProtocolContext.headerName] = key
32 | config.httpAdditionalHeaders = headers
| `- error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'httpAdditionalHeaders'
33 |
34 | return URLSession(configuration: config)
/host/spi-builder-workspace/Sources/Replay/Playback.swift:34:16: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
32 | config.httpAdditionalHeaders = headers
33 |
34 | return URLSession(configuration: config)
| `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
35 | }
36 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:286:27: error: type 'URLProtocol' (aka 'AnyObject') has no member 'property'
284 |
285 | public override class func canInit(with request: URLRequest) -> Bool {
286 | guard URLProtocol.property(forKey: handledKey, in: request) == nil else {
| `- error: type 'URLProtocol' (aka 'AnyObject') has no member 'property'
287 | return false
288 | }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:297:31: error: cannot find 'request' in scope
295 |
296 | public override func startLoading() {
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find 'request' in scope
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
299 | let markedRequest = mutableRequest as URLRequest
/host/spi-builder-workspace/Sources/Replay/Playback.swift:297:42: error: cannot find type 'NSURLRequest' in scope
295 |
296 | public override func startLoading() {
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find type 'NSURLRequest' in scope
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
299 | let markedRequest = mutableRequest as URLRequest
/host/spi-builder-workspace/Sources/Replay/Playback.swift:297:74: error: cannot find type 'NSMutableURLRequest' in scope
295 |
296 | public override func startLoading() {
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find type 'NSMutableURLRequest' in scope
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
299 | let markedRequest = mutableRequest as URLRequest
/host/spi-builder-workspace/Sources/Replay/Playback.swift:298:21: error: type 'URLProtocol' (aka 'AnyObject') has no member 'setProperty'
296 | public override func startLoading() {
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
| `- error: type 'URLProtocol' (aka 'AnyObject') has no member 'setProperty'
299 | let markedRequest = mutableRequest as URLRequest
300 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:299:47: error: cannot find type 'URLRequest' in scope
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
299 | let markedRequest = mutableRequest as URLRequest
| `- error: cannot find type 'URLRequest' in scope
300 |
301 | // URLProtocol predates Swift concurrency; wrap self to cross isolation boundary
/host/spi-builder-workspace/Sources/Replay/Playback.swift:512:25: error: value of type 'URLSessionTask' (aka 'AnyObject') has no member 'cancel'
510 | lock.unlock()
511 |
512 | urlSessionTask?.cancel()
| `- error: value of type 'URLSessionTask' (aka 'AnyObject') has no member 'cancel'
513 | streamTask?.cancel()
514 | }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:589:40: warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
588 | ) {
589 | if let httpResponse = response as? HTTPURLResponse {
| `- warning: conditional cast from 'URLResponse' (aka 'AnyObject') to 'HTTPURLResponse' (aka 'AnyObject') always succeeds
590 | settleResponse(.success(httpResponse))
591 | }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:589:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
588 | ) {
589 | if let httpResponse = response as? HTTPURLResponse {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
590 | settleResponse(.success(httpResponse))
591 | }
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/Replay/Playback.swift:592:28: error: cannot infer contextual base in reference to member 'allow'
590 | settleResponse(.success(httpResponse))
591 | }
592 | completionHandler(.allow)
| `- error: cannot infer contextual base in reference to member 'allow'
593 | }
594 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:623:57: error: value of type 'PlaybackURLProtocol' has no member 'client'
621 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
622 | ) {
623 | guard let urlProtocol, let client = urlProtocol.client else {
| `- error: value of type 'PlaybackURLProtocol' has no member 'client'
624 | completionHandler(.performDefaultHandling, nil)
625 | return
/host/spi-builder-workspace/Sources/Replay/Playback.swift:624:32: error: cannot infer contextual base in reference to member 'performDefaultHandling'
622 | ) {
623 | guard let urlProtocol, let client = urlProtocol.client else {
624 | completionHandler(.performDefaultHandling, nil)
| `- error: cannot infer contextual base in reference to member 'performDefaultHandling'
625 | return
626 | }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:624:56: error: 'nil' requires a contextual type
622 | ) {
623 | guard let urlProtocol, let client = urlProtocol.client else {
624 | completionHandler(.performDefaultHandling, nil)
| `- error: 'nil' requires a contextual type
625 | return
626 | }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:631:34: error: 'URLAuthenticationChallenge' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
629 | // while URLSession expects a completion handler.
630 | // Rebuild the challenge with a sender that bridges the client's eventual decision back to URLSession.
631 | let forwardedChallenge = URLAuthenticationChallenge(
| `- error: 'URLAuthenticationChallenge' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
632 | protectionSpace: challenge.protectionSpace,
633 | proposedCredential: challenge.proposedCredential,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:632:40: error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'protectionSpace'
630 | // Rebuild the challenge with a sender that bridges the client's eventual decision back to URLSession.
631 | let forwardedChallenge = URLAuthenticationChallenge(
632 | protectionSpace: challenge.protectionSpace,
| `- error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'protectionSpace'
633 | proposedCredential: challenge.proposedCredential,
634 | previousFailureCount: challenge.previousFailureCount,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:633:43: error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'proposedCredential'
631 | let forwardedChallenge = URLAuthenticationChallenge(
632 | protectionSpace: challenge.protectionSpace,
633 | proposedCredential: challenge.proposedCredential,
| `- error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'proposedCredential'
634 | previousFailureCount: challenge.previousFailureCount,
635 | failureResponse: challenge.failureResponse,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:634:45: error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'previousFailureCount'
632 | protectionSpace: challenge.protectionSpace,
633 | proposedCredential: challenge.proposedCredential,
634 | previousFailureCount: challenge.previousFailureCount,
| `- error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'previousFailureCount'
635 | failureResponse: challenge.failureResponse,
636 | error: challenge.error,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:635:40: error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'failureResponse'
633 | proposedCredential: challenge.proposedCredential,
634 | previousFailureCount: challenge.previousFailureCount,
635 | failureResponse: challenge.failureResponse,
| `- error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'failureResponse'
636 | error: challenge.error,
637 | sender: PlaybackChallengeForwarder(completionHandler: completionHandler)
/host/spi-builder-workspace/Sources/Replay/Playback.swift:636:30: error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'error'
634 | previousFailureCount: challenge.previousFailureCount,
635 | failureResponse: challenge.failureResponse,
636 | error: challenge.error,
| `- error: value of type 'URLAuthenticationChallenge' (aka 'AnyObject') has no member 'error'
637 | sender: PlaybackChallengeForwarder(completionHandler: completionHandler)
638 | )
/host/spi-builder-workspace/Sources/Replay/Playback.swift:664:19: error: cannot infer contextual base in reference to member 'useCredential'
662 |
663 | func use(_ credential: URLCredential, for challenge: URLAuthenticationChallenge) {
664 | complete(.useCredential, credential)
| `- error: cannot infer contextual base in reference to member 'useCredential'
665 | }
666 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:670:19: error: cannot infer contextual base in reference to member 'performDefaultHandling'
668 | // "Continue without a credential" maps to URLSession's default handling,
669 | // not to `.useCredential` with a nil credential.
670 | complete(.performDefaultHandling, nil)
| `- error: cannot infer contextual base in reference to member 'performDefaultHandling'
671 | }
672 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:670:43: error: 'nil' requires a contextual type
668 | // "Continue without a credential" maps to URLSession's default handling,
669 | // not to `.useCredential` with a nil credential.
670 | complete(.performDefaultHandling, nil)
| `- error: 'nil' requires a contextual type
671 | }
672 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:674:19: error: cannot infer contextual base in reference to member 'cancelAuthenticationChallenge'
672 |
673 | func cancel(_ challenge: URLAuthenticationChallenge) {
674 | complete(.cancelAuthenticationChallenge, nil)
| `- error: cannot infer contextual base in reference to member 'cancelAuthenticationChallenge'
675 | }
676 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:674:50: error: 'nil' requires a contextual type
672 |
673 | func cancel(_ challenge: URLAuthenticationChallenge) {
674 | complete(.cancelAuthenticationChallenge, nil)
| `- error: 'nil' requires a contextual type
675 | }
676 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:678:19: error: cannot infer contextual base in reference to member 'performDefaultHandling'
676 |
677 | func performDefaultHandling(for challenge: URLAuthenticationChallenge) {
678 | complete(.performDefaultHandling, nil)
| `- error: cannot infer contextual base in reference to member 'performDefaultHandling'
679 | }
680 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:678:43: error: 'nil' requires a contextual type
676 |
677 | func performDefaultHandling(for challenge: URLAuthenticationChallenge) {
678 | complete(.performDefaultHandling, nil)
| `- error: 'nil' requires a contextual type
679 | }
680 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:682:19: error: cannot infer contextual base in reference to member 'rejectProtectionSpace'
680 |
681 | func rejectProtectionSpaceAndContinue(with challenge: URLAuthenticationChallenge) {
682 | complete(.rejectProtectionSpace, nil)
| `- error: cannot infer contextual base in reference to member 'rejectProtectionSpace'
683 | }
684 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:682:42: error: 'nil' requires a contextual type
680 |
681 | func rejectProtectionSpaceAndContinue(with challenge: URLAuthenticationChallenge) {
682 | complete(.rejectProtectionSpace, nil)
| `- error: 'nil' requires a contextual type
683 | }
684 |
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:166:41: error: cannot find type 'URLRequest' in scope
164 |
165 | /// Finds the first entry whose request matches according to all matchers.
166 | public func firstMatch(for request: URLRequest, in entries: [HAR.Entry]) -> HAR.Entry? {
| `- error: cannot find type 'URLRequest' in scope
167 | firstMatch(for: request, in: entries, filters: [])
168 | }
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:170:34: error: cannot find type 'URLRequest' in scope
168 | }
169 |
170 | func firstMatch(for request: URLRequest, in entries: [HAR.Entry], filters: [Filter]) -> HAR.Entry? {
| `- error: cannot find type 'URLRequest' in scope
171 | for entry in entries {
172 | guard let entryURL = URL(string: entry.request.url) else { continue }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:825:41: error: referencing instance method 'firstMatch(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
823 | // `.live` ignores any recorded entries and always hits the network.
824 | if effectivePlaybackMode != .live,
825 | let entry = config.matchers.firstMatch(for: request, in: entries, filters: config.filters)
| `- error: referencing instance method 'firstMatch(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
826 | {
827 | let (response, data) = try entry.toURLResponse()
_StringProcessing.BidirectionalCollection:1:11: note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
1 | extension BidirectionalCollection where Self.SubSequence == Substring {
| `- note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | @inlinable public func firstMatch<Output>(of r: some RegexComponent) -> Regex<Output>.Match?
/host/spi-builder-workspace/Sources/Replay/Playback.swift:825:51: error: extra arguments at positions #1, #2, #3 in call
823 | // `.live` ignores any recorded entries and always hits the network.
824 | if effectivePlaybackMode != .live,
825 | let entry = config.matchers.firstMatch(for: request, in: entries, filters: config.filters)
| `- error: extra arguments at positions #1, #2, #3 in call
826 | {
827 | let (response, data) = try entry.toURLResponse()
_StringProcessing.BidirectionalCollection.firstMatch:3:26: note: 'firstMatch(of:)' declared here
1 | protocol BidirectionalCollection {
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | @inlinable public func firstMatch<Output>(of r: some RegexComponent) -> Regex<Output>.Match?}
| `- note: 'firstMatch(of:)' declared here
4 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:825:52: error: missing argument for parameter 'of' in call
823 | // `.live` ignores any recorded entries and always hits the network.
824 | if effectivePlaybackMode != .live,
825 | let entry = config.matchers.firstMatch(for: request, in: entries, filters: config.filters)
| `- error: missing argument for parameter 'of' in call
826 | {
827 | let (response, data) = try entry.toURLResponse()
_StringProcessing.BidirectionalCollection.firstMatch:3:26: note: 'firstMatch(of:)' declared here
1 | protocol BidirectionalCollection {
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | @inlinable public func firstMatch<Output>(of r: some RegexComponent) -> Regex<Output>.Match?}
| `- note: 'firstMatch(of:)' declared here
4 |
/host/spi-builder-workspace/Sources/Replay/HAR.swift:848:18: error: cannot find type 'URLRequest' in scope
846 | /// Create an entry from a `URLRequest` and `HTTPURLResponse`.
847 | public init(
848 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
849 | response: HTTPURLResponse,
850 | data: Data,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:879:34: error: extra arguments at positions #3, #4, #5 in call
877 | }
878 |
879 | var entry = try HAR.Entry(
| `- error: extra arguments at positions #3, #4, #5 in call
880 | request: request,
881 | response: response,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:212:16: note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
210 | public var comment: String?
211 |
212 | public init(
| `- note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
213 | startedDateTime: Date,
214 | time: Int,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:879:34: error: missing arguments for parameters 'startedDateTime', 'time', 'timings' in call
877 | }
878 |
879 | var entry = try HAR.Entry(
| `- error: missing arguments for parameters 'startedDateTime', 'time', 'timings' in call
880 | request: request,
881 | response: response,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:212:16: note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
210 | public var comment: String?
211 |
212 | public init(
| `- note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
213 | startedDateTime: Date,
214 | time: Int,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:881:23: error: cannot convert value of type 'HTTPURLResponse' (aka 'AnyObject') to expected argument type 'HAR.Response'
879 | var entry = try HAR.Entry(
880 | request: request,
881 | response: response,
| `- error: cannot convert value of type 'HTTPURLResponse' (aka 'AnyObject') to expected argument type 'HAR.Response'
882 | data: data,
883 | startTime: startTime,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:940:57: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
938 | case .network(let shouldRecord):
939 | let startTime = Date()
940 | let (data, response) = try await URLSession.shared.data(for: request)
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
941 | guard let httpResponse = response as? HTTPURLResponse else {
942 | throw ReplayError.invalidResponse
/host/spi-builder-workspace/Sources/Replay/Playback.swift:978:23: error: cannot find 'URLRequest' in scope
976 |
977 | private func makeEntry(from stub: Stub) throws -> HAR.Entry {
978 | var request = URLRequest(url: stub.url)
| `- error: cannot find 'URLRequest' in scope
979 | request.httpMethod = stub.method.rawValue
980 | if !stub.requestHeaders.isEmpty {
/host/spi-builder-workspace/Sources/Replay/Playback.swift:985:28: error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
983 |
984 | guard
985 | let response = HTTPURLResponse(
| `- error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
986 | url: stub.url,
987 | statusCode: stub.status,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:995:29: error: extra arguments at positions #3, #4, #5 in call
993 | }
994 |
995 | return try HAR.Entry(
| `- error: extra arguments at positions #3, #4, #5 in call
996 | request: request,
997 | response: response,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:212:16: note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
210 | public var comment: String?
211 |
212 | public init(
| `- note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
213 | startedDateTime: Date,
214 | time: Int,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:995:29: error: missing arguments for parameters 'startedDateTime', 'time', 'timings' in call
993 | }
994 |
995 | return try HAR.Entry(
| `- error: missing arguments for parameters 'startedDateTime', 'time', 'timings' in call
996 | request: request,
997 | response: response,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:212:16: note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
210 | public var comment: String?
211 |
212 | public init(
| `- note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
213 | startedDateTime: Date,
214 | time: Int,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:216:17: error: cannot find type 'URLRequest' in scope
214 | limit: Int,
215 | isCancelled: () -> Bool = { false }
216 | ) throws -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
217 | precondition(limit >= 0, "limit must be zero or more")
218 | guard httpBody == nil, let stream = httpBodyStream else { return self }
[11/42] Compiling Replay Matcher.swift
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:59:39: error: cannot find type 'URLRequest' in scope
57 | /// Escape hatch for custom matching logic.
58 | /// Compares an incoming request against a candidate request (typically from a recorded entry).
59 | case custom(@Sendable (_ request: URLRequest, _ candidate: URLRequest) -> Bool)
| `- error: cannot find type 'URLRequest' in scope
60 |
61 | /// Whether this matcher can read the request body.
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:59:64: error: cannot find type 'URLRequest' in scope
57 | /// Escape hatch for custom matching logic.
58 | /// Compares an incoming request against a candidate request (typically from a recorded entry).
59 | case custom(@Sendable (_ request: URLRequest, _ candidate: URLRequest) -> Bool)
| `- error: cannot find type 'URLRequest' in scope
60 |
61 | /// Whether this matcher can read the request body.
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:72:26: error: cannot find type 'URLRequest' in scope
70 | }
71 |
72 | func test(_ request: URLRequest, _ candidate: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
73 | switch self {
74 | case .method:
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:72:51: error: cannot find type 'URLRequest' in scope
70 | }
71 |
72 | func test(_ request: URLRequest, _ candidate: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
73 | switch self {
74 | case .method:
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:156:36: error: cannot find type 'URLRequest' in scope
154 | ///
155 | /// This is used by capture as an opt-in filter.
156 | public func matches(_ request: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
157 | for matcher in self {
158 | if !matcher.test(request, request) {
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:166:41: error: cannot find type 'URLRequest' in scope
164 |
165 | /// Finds the first entry whose request matches according to all matchers.
166 | public func firstMatch(for request: URLRequest, in entries: [HAR.Entry]) -> HAR.Entry? {
| `- error: cannot find type 'URLRequest' in scope
167 | firstMatch(for: request, in: entries, filters: [])
168 | }
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:170:34: error: cannot find type 'URLRequest' in scope
168 | }
169 |
170 | func firstMatch(for request: URLRequest, in entries: [HAR.Entry], filters: [Filter]) -> HAR.Entry? {
| `- error: cannot find type 'URLRequest' in scope
171 | for entry in entries {
172 | guard let entryURL = URL(string: entry.request.url) else { continue }
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:197:20: error: cannot find type 'URLRequest' in scope
195 |
196 | private func matches(
197 | _ request: URLRequest, _ candidate: URLRequest, candidateURL: String, filters: [Filter]
| `- error: cannot find type 'URLRequest' in scope
198 | ) -> Bool {
199 | for matcher in self {
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:197:45: error: cannot find type 'URLRequest' in scope
195 |
196 | private func matches(
197 | _ request: URLRequest, _ candidate: URLRequest, candidateURL: String, filters: [Filter]
| `- error: cannot find type 'URLRequest' in scope
198 | ) -> Bool {
199 | for matcher in self {
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:167:19: error: extra arguments at positions #1, #2, #3 in call
165 | /// Finds the first entry whose request matches according to all matchers.
166 | public func firstMatch(for request: URLRequest, in entries: [HAR.Entry]) -> HAR.Entry? {
167 | firstMatch(for: request, in: entries, filters: [])
| `- error: extra arguments at positions #1, #2, #3 in call
168 | }
169 |
_StringProcessing.BidirectionalCollection.firstMatch:3:26: note: 'firstMatch(of:)' declared here
1 | protocol BidirectionalCollection {
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | @inlinable public func firstMatch<Output>(of r: some RegexComponent) -> Regex<Output>.Match?}
| `- note: 'firstMatch(of:)' declared here
4 |
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:167:20: error: missing argument for parameter 'of' in call
165 | /// Finds the first entry whose request matches according to all matchers.
166 | public func firstMatch(for request: URLRequest, in entries: [HAR.Entry]) -> HAR.Entry? {
167 | firstMatch(for: request, in: entries, filters: [])
| `- error: missing argument for parameter 'of' in call
168 | }
169 |
_StringProcessing.BidirectionalCollection.firstMatch:3:26: note: 'firstMatch(of:)' declared here
1 | protocol BidirectionalCollection {
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | @inlinable public func firstMatch<Output>(of r: some RegexComponent) -> Regex<Output>.Match?}
| `- note: 'firstMatch(of:)' declared here
4 |
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:167:9: error: cannot convert return expression of type 'Regex<Output>.Match?' to return type 'HAR.Entry?'
165 | /// Finds the first entry whose request matches according to all matchers.
166 | public func firstMatch(for request: URLRequest, in entries: [HAR.Entry]) -> HAR.Entry? {
167 | firstMatch(for: request, in: entries, filters: [])
| `- error: cannot convert return expression of type 'Regex<Output>.Match?' to return type 'HAR.Entry?'
168 | }
169 |
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:167:9: error: referencing instance method 'firstMatch(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
165 | /// Finds the first entry whose request matches according to all matchers.
166 | public func firstMatch(for request: URLRequest, in entries: [HAR.Entry]) -> HAR.Entry? {
167 | firstMatch(for: request, in: entries, filters: [])
| `- error: referencing instance method 'firstMatch(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
168 | }
169 |
_StringProcessing.BidirectionalCollection:1:11: note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
1 | extension BidirectionalCollection where Self.SubSequence == Substring {
| `- note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | @inlinable public func firstMatch<Output>(of r: some RegexComponent) -> Regex<Output>.Match?
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:174:32: error: cannot find 'URLRequest' in scope
172 | guard let entryURL = URL(string: entry.request.url) else { continue }
173 |
174 | var entryRequest = URLRequest(url: entryURL)
| `- error: cannot find 'URLRequest' in scope
175 | entryRequest.httpMethod = entry.request.method
176 | for header in entry.request.headers {
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:188:16: error: referencing instance method 'matches(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
186 | }
187 |
188 | if matches(request, entryRequest, candidateURL: entry.request.url, filters: filters) {
| `- error: referencing instance method 'matches(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
189 | return entry
190 | }
_StringProcessing.BidirectionalCollection:1:11: note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
1 | extension BidirectionalCollection where Self.SubSequence == Substring {
| `- note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | public func matches<Output>(of r: some RegexComponent) -> [Regex<Output>.Match]
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:188:23: error: extra arguments at positions #2, #3, #4 in call
186 | }
187 |
188 | if matches(request, entryRequest, candidateURL: entry.request.url, filters: filters) {
| `- error: extra arguments at positions #2, #3, #4 in call
189 | return entry
190 | }
_StringProcessing.BidirectionalCollection.matches:3:15: note: 'matches(of:)' declared here
1 | protocol BidirectionalCollection {
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | public func matches<Output>(of r: some RegexComponent) -> [Regex<Output>.Match]}
| `- note: 'matches(of:)' declared here
4 |
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:188:16: error: cannot convert value of type '[Regex<Output>.Match]' to expected condition type 'Bool'
186 | }
187 |
188 | if matches(request, entryRequest, candidateURL: entry.request.url, filters: filters) {
| `- error: cannot convert value of type '[Regex<Output>.Match]' to expected condition type 'Bool'
189 | return entry
190 | }
[12/42] Emitting module Replay
[13/42] Compiling Replay Traits.swift
[14/42] Compiling Replay Replay.swift
[15/42] Compiling Replay Stub.swift
[16/42] Emitting module ArgumentParserToolInfo
[17/42] Compiling ArgumentParserToolInfo ToolInfo.swift
[20/43] Emitting module ArgumentParserToolInfo
error: emit-module command failed with exit code 1 (use -v to see invocation)
[21/43] Compiling Replay Filter.swift
/host/spi-builder-workspace/Sources/Replay/HAR.swift:884:34: error: cannot find type 'URLRequest' in scope
882 | /// - Parameter urlRequest: The request to convert.
883 | /// - Throws: `ReplayError.invalidRequest` if the request is missing a URL.
884 | public init(from urlRequest: URLRequest) throws {
| `- error: cannot find type 'URLRequest' in scope
885 | guard let url = urlRequest.url else {
886 | throw ReplayError.invalidRequest("Missing URL")
/host/spi-builder-workspace/Sources/Replay/HAR.swift:848:18: error: cannot find type 'URLRequest' in scope
846 | /// Create an entry from a `URLRequest` and `HTTPURLResponse`.
847 | public init(
848 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
849 | response: HTTPURLResponse,
850 | data: Data,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:849:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
847 | public init(
848 | request: URLRequest,
849 | response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
850 | data: Data,
851 | startTime: Date,
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/Replay/HAR.swift:956:36: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
954 | /// - httpResponse: The response to convert.
955 | /// - data: The response body data.
956 | public init(from httpResponse: HTTPURLResponse, data: Data) throws {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
957 | self.status = httpResponse.statusCode
958 | self.statusText = HTTPURLResponse.localizedString(forStatusCode: 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/Replay/HAR.swift:1010:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
1008 | extension HAR.Entry {
1009 | /// Convert an entry back into `HTTPURLResponse` and body `Data` for playback.
1010 | public func toURLResponse() throws -> (HTTPURLResponse, Data) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
1011 | guard let url = URL(string: request.url) else {
1012 | throw ReplayError.invalidURL(request.url)
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/Replay/HAR.swift:930:64: error: cannot infer contextual base in reference to member 'whitespacesAndNewlines'
928 | .split(separator: ";")
929 | .compactMap { pair in
930 | let trimmed = pair.trimmingCharacters(in: .whitespacesAndNewlines)
| `- error: cannot infer contextual base in reference to member 'whitespacesAndNewlines'
931 | let parts = trimmed.split(separator: "=", maxSplits: 1)
932 | guard parts.count == 2 else { return nil }
/host/spi-builder-workspace/Sources/Replay/HAR.swift:957:36: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
955 | /// - data: The response body data.
956 | public init(from httpResponse: HTTPURLResponse, data: Data) throws {
957 | self.status = httpResponse.statusCode
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
958 | self.statusText = HTTPURLResponse.localizedString(forStatusCode: httpResponse.statusCode)
959 | self.httpVersion = "HTTP/1.1"
/host/spi-builder-workspace/Sources/Replay/HAR.swift:958:43: error: type 'HTTPURLResponse' (aka 'AnyObject') has no member 'localizedString'
956 | public init(from httpResponse: HTTPURLResponse, data: Data) throws {
957 | self.status = httpResponse.statusCode
958 | self.statusText = HTTPURLResponse.localizedString(forStatusCode: httpResponse.statusCode)
| `- error: type 'HTTPURLResponse' (aka 'AnyObject') has no member 'localizedString'
959 | self.httpVersion = "HTTP/1.1"
960 |
/host/spi-builder-workspace/Sources/Replay/HAR.swift:958:87: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
956 | public init(from httpResponse: HTTPURLResponse, data: Data) throws {
957 | self.status = httpResponse.statusCode
958 | self.statusText = HTTPURLResponse.localizedString(forStatusCode: httpResponse.statusCode)
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
959 | self.httpVersion = "HTTP/1.1"
960 |
/host/spi-builder-workspace/Sources/Replay/HAR.swift:961:37: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
959 | self.httpVersion = "HTTP/1.1"
960 |
961 | self.headers = httpResponse.allHeaderFields
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
962 | .sorted { String(describing: $0.key) < String(describing: $1.key) }
963 | .map { key, value in
/host/spi-builder-workspace/Sources/Replay/HAR.swift:967:37: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'mimeType'
965 | }
966 |
967 | let mimeType = httpResponse.mimeType ?? "application/octet-stream"
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'mimeType'
968 | let utf8Text = String(data: data, encoding: .utf8)
969 | let encoding = utf8Text == nil && !data.isEmpty ? "base64" : nil
/host/spi-builder-workspace/Sources/Replay/HAR.swift:979:35: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'url'
977 | )
978 |
979 | if let url = httpResponse.url {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'url'
980 | var headerFields: [String: String] = [:]
981 | for (key, value) in httpResponse.allHeaderFields {
/host/spi-builder-workspace/Sources/Replay/HAR.swift:981:46: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
979 | if let url = httpResponse.url {
980 | var headerFields: [String: String] = [:]
981 | for (key, value) in httpResponse.allHeaderFields {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
982 | headerFields[String(describing: key)] = String(describing: value)
983 | }
/host/spi-builder-workspace/Sources/Replay/HAR.swift:985:38: error: type 'HTTPCookie' (aka 'AnyObject') has no member 'cookies'
983 | }
984 |
985 | let cookies = HTTPCookie.cookies(withResponseHeaderFields: headerFields, for: url)
| `- error: type 'HTTPCookie' (aka 'AnyObject') has no member 'cookies'
986 | self.cookies = cookies.map { cookie in
987 | HAR.Cookie(
/host/spi-builder-workspace/Sources/Replay/HAR.swift:1021:32: error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
1019 |
1020 | guard
1021 | let httpResponse = HTTPURLResponse(
| `- error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
1022 | url: url,
1023 | statusCode: response.status,
[22/43] Compiling Replay HAR.swift
/host/spi-builder-workspace/Sources/Replay/HAR.swift:884:34: error: cannot find type 'URLRequest' in scope
882 | /// - Parameter urlRequest: The request to convert.
883 | /// - Throws: `ReplayError.invalidRequest` if the request is missing a URL.
884 | public init(from urlRequest: URLRequest) throws {
| `- error: cannot find type 'URLRequest' in scope
885 | guard let url = urlRequest.url else {
886 | throw ReplayError.invalidRequest("Missing URL")
/host/spi-builder-workspace/Sources/Replay/HAR.swift:848:18: error: cannot find type 'URLRequest' in scope
846 | /// Create an entry from a `URLRequest` and `HTTPURLResponse`.
847 | public init(
848 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
849 | response: HTTPURLResponse,
850 | data: Data,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:849:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
847 | public init(
848 | request: URLRequest,
849 | response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
850 | data: Data,
851 | startTime: Date,
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/Replay/HAR.swift:956:36: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
954 | /// - httpResponse: The response to convert.
955 | /// - data: The response body data.
956 | public init(from httpResponse: HTTPURLResponse, data: Data) throws {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
957 | self.status = httpResponse.statusCode
958 | self.statusText = HTTPURLResponse.localizedString(forStatusCode: 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/Replay/HAR.swift:1010:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
1008 | extension HAR.Entry {
1009 | /// Convert an entry back into `HTTPURLResponse` and body `Data` for playback.
1010 | public func toURLResponse() throws -> (HTTPURLResponse, Data) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
1011 | guard let url = URL(string: request.url) else {
1012 | throw ReplayError.invalidURL(request.url)
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/Replay/HAR.swift:930:64: error: cannot infer contextual base in reference to member 'whitespacesAndNewlines'
928 | .split(separator: ";")
929 | .compactMap { pair in
930 | let trimmed = pair.trimmingCharacters(in: .whitespacesAndNewlines)
| `- error: cannot infer contextual base in reference to member 'whitespacesAndNewlines'
931 | let parts = trimmed.split(separator: "=", maxSplits: 1)
932 | guard parts.count == 2 else { return nil }
/host/spi-builder-workspace/Sources/Replay/HAR.swift:957:36: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
955 | /// - data: The response body data.
956 | public init(from httpResponse: HTTPURLResponse, data: Data) throws {
957 | self.status = httpResponse.statusCode
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
958 | self.statusText = HTTPURLResponse.localizedString(forStatusCode: httpResponse.statusCode)
959 | self.httpVersion = "HTTP/1.1"
/host/spi-builder-workspace/Sources/Replay/HAR.swift:958:43: error: type 'HTTPURLResponse' (aka 'AnyObject') has no member 'localizedString'
956 | public init(from httpResponse: HTTPURLResponse, data: Data) throws {
957 | self.status = httpResponse.statusCode
958 | self.statusText = HTTPURLResponse.localizedString(forStatusCode: httpResponse.statusCode)
| `- error: type 'HTTPURLResponse' (aka 'AnyObject') has no member 'localizedString'
959 | self.httpVersion = "HTTP/1.1"
960 |
/host/spi-builder-workspace/Sources/Replay/HAR.swift:958:87: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
956 | public init(from httpResponse: HTTPURLResponse, data: Data) throws {
957 | self.status = httpResponse.statusCode
958 | self.statusText = HTTPURLResponse.localizedString(forStatusCode: httpResponse.statusCode)
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
959 | self.httpVersion = "HTTP/1.1"
960 |
/host/spi-builder-workspace/Sources/Replay/HAR.swift:961:37: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
959 | self.httpVersion = "HTTP/1.1"
960 |
961 | self.headers = httpResponse.allHeaderFields
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
962 | .sorted { String(describing: $0.key) < String(describing: $1.key) }
963 | .map { key, value in
/host/spi-builder-workspace/Sources/Replay/HAR.swift:967:37: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'mimeType'
965 | }
966 |
967 | let mimeType = httpResponse.mimeType ?? "application/octet-stream"
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'mimeType'
968 | let utf8Text = String(data: data, encoding: .utf8)
969 | let encoding = utf8Text == nil && !data.isEmpty ? "base64" : nil
/host/spi-builder-workspace/Sources/Replay/HAR.swift:979:35: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'url'
977 | )
978 |
979 | if let url = httpResponse.url {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'url'
980 | var headerFields: [String: String] = [:]
981 | for (key, value) in httpResponse.allHeaderFields {
/host/spi-builder-workspace/Sources/Replay/HAR.swift:981:46: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
979 | if let url = httpResponse.url {
980 | var headerFields: [String: String] = [:]
981 | for (key, value) in httpResponse.allHeaderFields {
| `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'allHeaderFields'
982 | headerFields[String(describing: key)] = String(describing: value)
983 | }
/host/spi-builder-workspace/Sources/Replay/HAR.swift:985:38: error: type 'HTTPCookie' (aka 'AnyObject') has no member 'cookies'
983 | }
984 |
985 | let cookies = HTTPCookie.cookies(withResponseHeaderFields: headerFields, for: url)
| `- error: type 'HTTPCookie' (aka 'AnyObject') has no member 'cookies'
986 | self.cookies = cookies.map { cookie in
987 | HAR.Cookie(
/host/spi-builder-workspace/Sources/Replay/HAR.swift:1021:32: error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
1019 |
1020 | guard
1021 | let httpResponse = HTTPURLResponse(
| `- error: 'HTTPURLResponse' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
1022 | url: url,
1023 | statusCode: response.status,
[23/43] Compiling Replay Capture.swift
/host/spi-builder-workspace/Sources/Replay/Capture.swift:32:28: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
30 | public static func session(
31 | configuration: CaptureConfiguration,
32 | baseConfiguration: URLSessionConfiguration = .default
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
33 | ) async -> URLSession {
34 | let config = baseConfiguration
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Capture.swift:33:16: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 | configuration: CaptureConfiguration,
32 | baseConfiguration: URLSessionConfiguration = .default
33 | ) async -> URLSession {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 | let config = baseConfiguration
35 | var protocols = config.protocolClasses ?? []
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/Replay/Capture.swift:32:55: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
30 | public static func session(
31 | configuration: CaptureConfiguration,
32 | baseConfiguration: URLSessionConfiguration = .default
| `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
33 | ) async -> URLSession {
34 | let config = baseConfiguration
/host/spi-builder-workspace/Sources/Replay/Capture.swift:140:27: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
138 | private let lock = NSLock()
139 | private var loadTask: Task<Void, Never>?
140 | private var dataTask: URLSessionDataTask?
| `- error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
141 | private var isStopped = false
142 |
Foundation.URLSessionDataTask:2:18: note: 'URLSessionDataTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionDataTask = AnyObject
| `- note: 'URLSessionDataTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Capture.swift:143:54: error: cannot find type 'URLRequest' in scope
141 | private var isStopped = false
142 |
143 | public override class func canInit(with request: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
144 | // Prevent infinite loops
145 | guard URLProtocol.property(forKey: handledKey, in: request) == nil else {
/host/spi-builder-workspace/Sources/Replay/Capture.swift:154:77: error: cannot find type 'URLRequest' in scope
152 | }
153 |
154 | public override class func canonicalRequest(for request: URLRequest) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
155 | request
156 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:154:62: error: cannot find type 'URLRequest' in scope
152 | }
153 |
154 | public override class func canonicalRequest(for request: URLRequest) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
155 | request
156 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:158:26: error: method does not override any method from its superclass
156 | }
157 |
158 | public override func startLoading() {
| `- error: method does not override any method from its superclass
159 | let startTime = Date()
160 | let request = self.request
/host/spi-builder-workspace/Sources/Replay/Capture.swift:184:38: error: cannot find type 'URLRequest' in scope
182 | }
183 |
184 | private func send(_ bodyRequest: URLRequest, startTime: Date) {
| `- error: cannot find type 'URLRequest' in scope
185 | // Mark request as handled
186 | let mutableRequest = (bodyRequest as NSURLRequest).mutableCopy() as! NSMutableURLRequest
/host/spi-builder-workspace/Sources/Replay/Capture.swift:240:26: error: method does not override any method from its superclass
238 | }
239 |
240 | public override func stopLoading() {
| `- error: method does not override any method from its superclass
241 | let (loadTask, dataTask) = lock.withLock {
242 | isStopped = true
/host/spi-builder-workspace/Sources/Replay/Capture.swift:135:40: error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
133 | /// `CaptureURLProtocol` forwards responses to the requesting client,
134 | /// and records the request/response pair asynchronously.
135 | public final class CaptureURLProtocol: URLProtocol {
| `- error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
136 | private static let handledKey = "ReplayCaptureHandled"
137 |
Foundation.URLProtocol:2:18: note: 'URLProtocol' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLProtocol = AnyObject
| `- note: 'URLProtocol' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Capture.swift:342:18: error: cannot find type 'URLRequest' in scope
340 | /// - duration: The request duration.
341 | public func recordEntry(
342 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
343 | response: HTTPURLResponse,
344 | data: Data,
/host/spi-builder-workspace/Sources/Replay/Capture.swift:343:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
341 | public func recordEntry(
342 | request: URLRequest,
343 | response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
344 | data: Data,
345 | startTime: Date,
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/Replay/Capture.swift:35:32: error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
33 | ) async -> URLSession {
34 | let config = baseConfiguration
35 | var protocols = config.protocolClasses ?? []
| `- error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
36 | protocols.insert(CaptureURLProtocol.self, at: 0)
37 | config.protocolClasses = protocols
/host/spi-builder-workspace/Sources/Replay/Capture.swift:37:16: error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
35 | var protocols = config.protocolClasses ?? []
36 | protocols.insert(CaptureURLProtocol.self, at: 0)
37 | config.protocolClasses = protocols
| `- error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
38 |
39 | await CaptureStore.shared.configure(configuration)
/host/spi-builder-workspace/Sources/Replay/Capture.swift:41:16: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
39 | await CaptureStore.shared.configure(configuration)
40 |
41 | return URLSession(configuration: config)
| `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
42 | }
43 |
/host/spi-builder-workspace/Sources/Replay/Capture.swift:145:27: error: type 'URLProtocol' (aka 'AnyObject') has no member 'property'
143 | public override class func canInit(with request: URLRequest) -> Bool {
144 | // Prevent infinite loops
145 | guard URLProtocol.property(forKey: handledKey, in: request) == nil else {
| `- error: type 'URLProtocol' (aka 'AnyObject') has no member 'property'
146 | return false
147 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:160:28: error: value of type 'CaptureURLProtocol' has no member 'request'
158 | public override func startLoading() {
159 | let startTime = Date()
160 | let request = self.request
| `- error: value of type 'CaptureURLProtocol' has no member 'request'
161 |
162 | // Read the body back from its stream so the recorded entry keeps it.
/host/spi-builder-workspace/Sources/Replay/Capture.swift:170:30: error: cannot find type 'URLRequest' in scope
168 | await CaptureStore.shared.currentConfiguration?.maximumRequestBodySize
169 | ?? Replay.defaultMaximumRequestBodySize
170 | let bodyRequest: URLRequest
| `- error: cannot find type 'URLRequest' in scope
171 | do {
172 | bodyRequest = try request.withBodyReadFromStream(limit: limit) { Task.isCancelled }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:165:20: error: type of expression is ambiguous without a type annotation
163 | // The read runs in a task so that `stopLoading()` can cancel it.
164 | let sendableSelf = UnsafeSendable(value: self)
165 | let task = Task {
| `- error: type of expression is ambiguous without a type annotation
166 | let urlProtocol = sendableSelf.value
167 | let limit =
/host/spi-builder-workspace/Sources/Replay/Capture.swift:186:46: error: cannot find type 'NSURLRequest' in scope
184 | private func send(_ bodyRequest: URLRequest, startTime: Date) {
185 | // Mark request as handled
186 | let mutableRequest = (bodyRequest as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find type 'NSURLRequest' in scope
187 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
188 |
/host/spi-builder-workspace/Sources/Replay/Capture.swift:186:78: error: cannot find type 'NSMutableURLRequest' in scope
184 | private func send(_ bodyRequest: URLRequest, startTime: Date) {
185 | // Mark request as handled
186 | let mutableRequest = (bodyRequest as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find type 'NSMutableURLRequest' in scope
187 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
188 |
/host/spi-builder-workspace/Sources/Replay/Capture.swift:187:21: error: type 'URLProtocol' (aka 'AnyObject') has no member 'setProperty'
185 | // Mark request as handled
186 | let mutableRequest = (bodyRequest as NSURLRequest).mutableCopy() as! NSMutableURLRequest
187 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
| `- error: type 'URLProtocol' (aka 'AnyObject') has no member 'setProperty'
188 |
189 | let session = URLSession.shared
/host/spi-builder-workspace/Sources/Replay/Capture.swift:189:34: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
187 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
188 |
189 | let session = URLSession.shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
190 | // URLSession completion handlers are strictly @Sendable in Swift 6.
191 | // We use a wrapper to capture `weak self` safely without requiring Sendable conformance on Linux.
/host/spi-builder-workspace/Sources/Replay/Capture.swift:193:61: error: cannot find type 'URLRequest' in scope
191 | // We use a wrapper to capture `weak self` safely without requiring Sendable conformance on Linux.
192 | let weakSelf = UnsafeWeakSendable(self)
193 | let task = session.dataTask(with: mutableRequest as URLRequest) {
| `- error: cannot find type 'URLRequest' in scope
194 | data, response, error in
195 | guard let self = weakSelf.value else { return }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:198:22: error: value of type 'CaptureURLProtocol' has no member 'client'
196 |
197 | if let error {
198 | self.client?.urlProtocol(self, didFailWithError: error)
| `- error: value of type 'CaptureURLProtocol' has no member 'client'
199 | return
200 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:246:19: error: value of type 'URLSessionDataTask' (aka 'AnyObject') has no member 'cancel'
244 | }
245 | loadTask?.cancel()
246 | dataTask?.cancel()
| `- error: value of type 'URLSessionDataTask' (aka 'AnyObject') has no member 'cancel'
247 | }
248 | }
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:156:36: error: cannot find type 'URLRequest' in scope
154 | ///
155 | /// This is used by capture as an opt-in filter.
156 | public func matches(_ request: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
157 | for matcher in self {
158 | if !matcher.test(request, request) {
/host/spi-builder-workspace/Sources/Replay/Capture.swift:351:28: error: referencing instance method 'matches(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
349 |
350 | if let matchers = config.matchers {
351 | guard matchers.matches(request) else { return }
| `- error: referencing instance method 'matches(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
352 | }
353 |
_StringProcessing.BidirectionalCollection:1:11: note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
1 | extension BidirectionalCollection where Self.SubSequence == Substring {
| `- note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | public func matches<Output>(of r: some RegexComponent) -> [Regex<Output>.Match]
/host/spi-builder-workspace/Sources/Replay/Capture.swift:351:36: error: missing argument label 'of:' in call
349 |
350 | if let matchers = config.matchers {
351 | guard matchers.matches(request) else { return }
| `- error: missing argument label 'of:' in call
352 | }
353 |
/host/spi-builder-workspace/Sources/Replay/Capture.swift:351:28: error: cannot convert value of type '[Regex<Output>.Match]' to expected condition type 'Bool'
349 |
350 | if let matchers = config.matchers {
351 | guard matchers.matches(request) else { return }
| `- error: cannot convert value of type '[Regex<Output>.Match]' to expected condition type 'Bool'
352 | }
353 |
/host/spi-builder-workspace/Sources/Replay/HAR.swift:848:18: error: cannot find type 'URLRequest' in scope
846 | /// Create an entry from a `URLRequest` and `HTTPURLResponse`.
847 | public init(
848 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
849 | response: HTTPURLResponse,
850 | data: Data,
/host/spi-builder-workspace/Sources/Replay/Capture.swift:355:38: error: extra arguments at positions #3, #4, #5 in call
353 |
354 | do {
355 | var entry = try HAR.Entry(
| `- error: extra arguments at positions #3, #4, #5 in call
356 | request: request,
357 | response: response,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:212:16: note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
210 | public var comment: String?
211 |
212 | public init(
| `- note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
213 | startedDateTime: Date,
214 | time: Int,
/host/spi-builder-workspace/Sources/Replay/Capture.swift:355:38: error: missing arguments for parameters 'startedDateTime', 'time', 'timings' in call
353 |
354 | do {
355 | var entry = try HAR.Entry(
| `- error: missing arguments for parameters 'startedDateTime', 'time', 'timings' in call
356 | request: request,
357 | response: response,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:212:16: note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
210 | public var comment: String?
211 |
212 | public init(
| `- note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
213 | startedDateTime: Date,
214 | time: Int,
/host/spi-builder-workspace/Sources/Replay/Capture.swift:357:27: error: cannot convert value of type 'HTTPURLResponse' (aka 'AnyObject') to expected argument type 'HAR.Response'
355 | var entry = try HAR.Entry(
356 | request: request,
357 | response: response,
| `- error: cannot convert value of type 'HTTPURLResponse' (aka 'AnyObject') to expected argument type 'HAR.Response'
358 | data: data,
359 | startTime: startTime,
[24/43] Compiling Replay Error.swift
/host/spi-builder-workspace/Sources/Replay/Capture.swift:32:28: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
30 | public static func session(
31 | configuration: CaptureConfiguration,
32 | baseConfiguration: URLSessionConfiguration = .default
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
33 | ) async -> URLSession {
34 | let config = baseConfiguration
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Capture.swift:33:16: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 | configuration: CaptureConfiguration,
32 | baseConfiguration: URLSessionConfiguration = .default
33 | ) async -> URLSession {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 | let config = baseConfiguration
35 | var protocols = config.protocolClasses ?? []
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/Replay/Capture.swift:32:55: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
30 | public static func session(
31 | configuration: CaptureConfiguration,
32 | baseConfiguration: URLSessionConfiguration = .default
| `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
33 | ) async -> URLSession {
34 | let config = baseConfiguration
/host/spi-builder-workspace/Sources/Replay/Capture.swift:140:27: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
138 | private let lock = NSLock()
139 | private var loadTask: Task<Void, Never>?
140 | private var dataTask: URLSessionDataTask?
| `- error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
141 | private var isStopped = false
142 |
Foundation.URLSessionDataTask:2:18: note: 'URLSessionDataTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionDataTask = AnyObject
| `- note: 'URLSessionDataTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Capture.swift:143:54: error: cannot find type 'URLRequest' in scope
141 | private var isStopped = false
142 |
143 | public override class func canInit(with request: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
144 | // Prevent infinite loops
145 | guard URLProtocol.property(forKey: handledKey, in: request) == nil else {
/host/spi-builder-workspace/Sources/Replay/Capture.swift:154:77: error: cannot find type 'URLRequest' in scope
152 | }
153 |
154 | public override class func canonicalRequest(for request: URLRequest) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
155 | request
156 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:154:62: error: cannot find type 'URLRequest' in scope
152 | }
153 |
154 | public override class func canonicalRequest(for request: URLRequest) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
155 | request
156 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:158:26: error: method does not override any method from its superclass
156 | }
157 |
158 | public override func startLoading() {
| `- error: method does not override any method from its superclass
159 | let startTime = Date()
160 | let request = self.request
/host/spi-builder-workspace/Sources/Replay/Capture.swift:184:38: error: cannot find type 'URLRequest' in scope
182 | }
183 |
184 | private func send(_ bodyRequest: URLRequest, startTime: Date) {
| `- error: cannot find type 'URLRequest' in scope
185 | // Mark request as handled
186 | let mutableRequest = (bodyRequest as NSURLRequest).mutableCopy() as! NSMutableURLRequest
/host/spi-builder-workspace/Sources/Replay/Capture.swift:240:26: error: method does not override any method from its superclass
238 | }
239 |
240 | public override func stopLoading() {
| `- error: method does not override any method from its superclass
241 | let (loadTask, dataTask) = lock.withLock {
242 | isStopped = true
/host/spi-builder-workspace/Sources/Replay/Capture.swift:135:40: error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
133 | /// `CaptureURLProtocol` forwards responses to the requesting client,
134 | /// and records the request/response pair asynchronously.
135 | public final class CaptureURLProtocol: URLProtocol {
| `- error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
136 | private static let handledKey = "ReplayCaptureHandled"
137 |
Foundation.URLProtocol:2:18: note: 'URLProtocol' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLProtocol = AnyObject
| `- note: 'URLProtocol' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Capture.swift:342:18: error: cannot find type 'URLRequest' in scope
340 | /// - duration: The request duration.
341 | public func recordEntry(
342 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
343 | response: HTTPURLResponse,
344 | data: Data,
/host/spi-builder-workspace/Sources/Replay/Capture.swift:343:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
341 | public func recordEntry(
342 | request: URLRequest,
343 | response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
344 | data: Data,
345 | startTime: Date,
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/Replay/Capture.swift:35:32: error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
33 | ) async -> URLSession {
34 | let config = baseConfiguration
35 | var protocols = config.protocolClasses ?? []
| `- error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
36 | protocols.insert(CaptureURLProtocol.self, at: 0)
37 | config.protocolClasses = protocols
/host/spi-builder-workspace/Sources/Replay/Capture.swift:37:16: error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
35 | var protocols = config.protocolClasses ?? []
36 | protocols.insert(CaptureURLProtocol.self, at: 0)
37 | config.protocolClasses = protocols
| `- error: value of type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'protocolClasses'
38 |
39 | await CaptureStore.shared.configure(configuration)
/host/spi-builder-workspace/Sources/Replay/Capture.swift:41:16: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
39 | await CaptureStore.shared.configure(configuration)
40 |
41 | return URLSession(configuration: config)
| `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
42 | }
43 |
/host/spi-builder-workspace/Sources/Replay/Capture.swift:145:27: error: type 'URLProtocol' (aka 'AnyObject') has no member 'property'
143 | public override class func canInit(with request: URLRequest) -> Bool {
144 | // Prevent infinite loops
145 | guard URLProtocol.property(forKey: handledKey, in: request) == nil else {
| `- error: type 'URLProtocol' (aka 'AnyObject') has no member 'property'
146 | return false
147 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:160:28: error: value of type 'CaptureURLProtocol' has no member 'request'
158 | public override func startLoading() {
159 | let startTime = Date()
160 | let request = self.request
| `- error: value of type 'CaptureURLProtocol' has no member 'request'
161 |
162 | // Read the body back from its stream so the recorded entry keeps it.
/host/spi-builder-workspace/Sources/Replay/Capture.swift:170:30: error: cannot find type 'URLRequest' in scope
168 | await CaptureStore.shared.currentConfiguration?.maximumRequestBodySize
169 | ?? Replay.defaultMaximumRequestBodySize
170 | let bodyRequest: URLRequest
| `- error: cannot find type 'URLRequest' in scope
171 | do {
172 | bodyRequest = try request.withBodyReadFromStream(limit: limit) { Task.isCancelled }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:165:20: error: type of expression is ambiguous without a type annotation
163 | // The read runs in a task so that `stopLoading()` can cancel it.
164 | let sendableSelf = UnsafeSendable(value: self)
165 | let task = Task {
| `- error: type of expression is ambiguous without a type annotation
166 | let urlProtocol = sendableSelf.value
167 | let limit =
/host/spi-builder-workspace/Sources/Replay/Capture.swift:186:46: error: cannot find type 'NSURLRequest' in scope
184 | private func send(_ bodyRequest: URLRequest, startTime: Date) {
185 | // Mark request as handled
186 | let mutableRequest = (bodyRequest as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find type 'NSURLRequest' in scope
187 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
188 |
/host/spi-builder-workspace/Sources/Replay/Capture.swift:186:78: error: cannot find type 'NSMutableURLRequest' in scope
184 | private func send(_ bodyRequest: URLRequest, startTime: Date) {
185 | // Mark request as handled
186 | let mutableRequest = (bodyRequest as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find type 'NSMutableURLRequest' in scope
187 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
188 |
/host/spi-builder-workspace/Sources/Replay/Capture.swift:187:21: error: type 'URLProtocol' (aka 'AnyObject') has no member 'setProperty'
185 | // Mark request as handled
186 | let mutableRequest = (bodyRequest as NSURLRequest).mutableCopy() as! NSMutableURLRequest
187 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
| `- error: type 'URLProtocol' (aka 'AnyObject') has no member 'setProperty'
188 |
189 | let session = URLSession.shared
/host/spi-builder-workspace/Sources/Replay/Capture.swift:189:34: error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
187 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
188 |
189 | let session = URLSession.shared
| `- error: type 'URLSession' (aka 'AnyObject') has no member 'shared'
190 | // URLSession completion handlers are strictly @Sendable in Swift 6.
191 | // We use a wrapper to capture `weak self` safely without requiring Sendable conformance on Linux.
/host/spi-builder-workspace/Sources/Replay/Capture.swift:193:61: error: cannot find type 'URLRequest' in scope
191 | // We use a wrapper to capture `weak self` safely without requiring Sendable conformance on Linux.
192 | let weakSelf = UnsafeWeakSendable(self)
193 | let task = session.dataTask(with: mutableRequest as URLRequest) {
| `- error: cannot find type 'URLRequest' in scope
194 | data, response, error in
195 | guard let self = weakSelf.value else { return }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:198:22: error: value of type 'CaptureURLProtocol' has no member 'client'
196 |
197 | if let error {
198 | self.client?.urlProtocol(self, didFailWithError: error)
| `- error: value of type 'CaptureURLProtocol' has no member 'client'
199 | return
200 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:246:19: error: value of type 'URLSessionDataTask' (aka 'AnyObject') has no member 'cancel'
244 | }
245 | loadTask?.cancel()
246 | dataTask?.cancel()
| `- error: value of type 'URLSessionDataTask' (aka 'AnyObject') has no member 'cancel'
247 | }
248 | }
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:156:36: error: cannot find type 'URLRequest' in scope
154 | ///
155 | /// This is used by capture as an opt-in filter.
156 | public func matches(_ request: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
157 | for matcher in self {
158 | if !matcher.test(request, request) {
/host/spi-builder-workspace/Sources/Replay/Capture.swift:351:28: error: referencing instance method 'matches(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
349 |
350 | if let matchers = config.matchers {
351 | guard matchers.matches(request) else { return }
| `- error: referencing instance method 'matches(of:)' on 'BidirectionalCollection' requires the types 'ArraySlice<Matcher>' and 'Substring' be equivalent
352 | }
353 |
_StringProcessing.BidirectionalCollection:1:11: note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
1 | extension BidirectionalCollection where Self.SubSequence == Substring {
| `- note: where 'Self.SubSequence' = 'ArraySlice<Matcher>'
2 | @available(macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0, *)
3 | public func matches<Output>(of r: some RegexComponent) -> [Regex<Output>.Match]
/host/spi-builder-workspace/Sources/Replay/Capture.swift:351:36: error: missing argument label 'of:' in call
349 |
350 | if let matchers = config.matchers {
351 | guard matchers.matches(request) else { return }
| `- error: missing argument label 'of:' in call
352 | }
353 |
/host/spi-builder-workspace/Sources/Replay/Capture.swift:351:28: error: cannot convert value of type '[Regex<Output>.Match]' to expected condition type 'Bool'
349 |
350 | if let matchers = config.matchers {
351 | guard matchers.matches(request) else { return }
| `- error: cannot convert value of type '[Regex<Output>.Match]' to expected condition type 'Bool'
352 | }
353 |
/host/spi-builder-workspace/Sources/Replay/HAR.swift:848:18: error: cannot find type 'URLRequest' in scope
846 | /// Create an entry from a `URLRequest` and `HTTPURLResponse`.
847 | public init(
848 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
849 | response: HTTPURLResponse,
850 | data: Data,
/host/spi-builder-workspace/Sources/Replay/Capture.swift:355:38: error: extra arguments at positions #3, #4, #5 in call
353 |
354 | do {
355 | var entry = try HAR.Entry(
| `- error: extra arguments at positions #3, #4, #5 in call
356 | request: request,
357 | response: response,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:212:16: note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
210 | public var comment: String?
211 |
212 | public init(
| `- note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
213 | startedDateTime: Date,
214 | time: Int,
/host/spi-builder-workspace/Sources/Replay/Capture.swift:355:38: error: missing arguments for parameters 'startedDateTime', 'time', 'timings' in call
353 |
354 | do {
355 | var entry = try HAR.Entry(
| `- error: missing arguments for parameters 'startedDateTime', 'time', 'timings' in call
356 | request: request,
357 | response: response,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:212:16: note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
210 | public var comment: String?
211 |
212 | public init(
| `- note: 'init(startedDateTime:time:request:response:cache:timings:serverIPAddress:connection:comment:)' declared here
213 | startedDateTime: Date,
214 | time: Int,
/host/spi-builder-workspace/Sources/Replay/Capture.swift:357:27: error: cannot convert value of type 'HTTPURLResponse' (aka 'AnyObject') to expected argument type 'HAR.Response'
355 | var entry = try HAR.Entry(
356 | request: request,
357 | response: response,
| `- error: cannot convert value of type 'HTTPURLResponse' (aka 'AnyObject') to expected argument type 'HAR.Response'
358 | data: data,
359 | startTime: startTime,
[25/43] Emitting module Replay
/host/spi-builder-workspace/Sources/Replay/Capture.swift:32:28: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
30 | public static func session(
31 | configuration: CaptureConfiguration,
32 | baseConfiguration: URLSessionConfiguration = .default
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
33 | ) async -> URLSession {
34 | let config = baseConfiguration
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Capture.swift:33:16: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
31 | configuration: CaptureConfiguration,
32 | baseConfiguration: URLSessionConfiguration = .default
33 | ) async -> URLSession {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
34 | let config = baseConfiguration
35 | var protocols = config.protocolClasses ?? []
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/Replay/Capture.swift:32:55: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
30 | public static func session(
31 | configuration: CaptureConfiguration,
32 | baseConfiguration: URLSessionConfiguration = .default
| `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
33 | ) async -> URLSession {
34 | let config = baseConfiguration
/host/spi-builder-workspace/Sources/Replay/Capture.swift:140:27: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
138 | private let lock = NSLock()
139 | private var loadTask: Task<Void, Never>?
140 | private var dataTask: URLSessionDataTask?
| `- error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
141 | private var isStopped = false
142 |
Foundation.URLSessionDataTask:2:18: note: 'URLSessionDataTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionDataTask = AnyObject
| `- note: 'URLSessionDataTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Capture.swift:143:54: error: cannot find type 'URLRequest' in scope
141 | private var isStopped = false
142 |
143 | public override class func canInit(with request: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
144 | // Prevent infinite loops
145 | guard URLProtocol.property(forKey: handledKey, in: request) == nil else {
/host/spi-builder-workspace/Sources/Replay/Capture.swift:154:77: error: cannot find type 'URLRequest' in scope
152 | }
153 |
154 | public override class func canonicalRequest(for request: URLRequest) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
155 | request
156 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:154:62: error: cannot find type 'URLRequest' in scope
152 | }
153 |
154 | public override class func canonicalRequest(for request: URLRequest) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
155 | request
156 | }
/host/spi-builder-workspace/Sources/Replay/Capture.swift:158:26: error: method does not override any method from its superclass
156 | }
157 |
158 | public override func startLoading() {
| `- error: method does not override any method from its superclass
159 | let startTime = Date()
160 | let request = self.request
/host/spi-builder-workspace/Sources/Replay/Capture.swift:184:38: error: cannot find type 'URLRequest' in scope
182 | }
183 |
184 | private func send(_ bodyRequest: URLRequest, startTime: Date) {
| `- error: cannot find type 'URLRequest' in scope
185 | // Mark request as handled
186 | let mutableRequest = (bodyRequest as NSURLRequest).mutableCopy() as! NSMutableURLRequest
/host/spi-builder-workspace/Sources/Replay/Capture.swift:240:26: error: method does not override any method from its superclass
238 | }
239 |
240 | public override func stopLoading() {
| `- error: method does not override any method from its superclass
241 | let (loadTask, dataTask) = lock.withLock {
242 | isStopped = true
/host/spi-builder-workspace/Sources/Replay/Capture.swift:135:40: error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
133 | /// `CaptureURLProtocol` forwards responses to the requesting client,
134 | /// and records the request/response pair asynchronously.
135 | public final class CaptureURLProtocol: URLProtocol {
| `- error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
136 | private static let handledKey = "ReplayCaptureHandled"
137 |
Foundation.URLProtocol:2:18: note: 'URLProtocol' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLProtocol = AnyObject
| `- note: 'URLProtocol' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Capture.swift:342:18: error: cannot find type 'URLRequest' in scope
340 | /// - duration: The request duration.
341 | public func recordEntry(
342 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
343 | response: HTTPURLResponse,
344 | data: Data,
/host/spi-builder-workspace/Sources/Replay/Capture.swift:343:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
341 | public func recordEntry(
342 | request: URLRequest,
343 | response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
344 | data: Data,
345 | startTime: Date,
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/Replay/HAR.swift:884:34: error: cannot find type 'URLRequest' in scope
882 | /// - Parameter urlRequest: The request to convert.
883 | /// - Throws: `ReplayError.invalidRequest` if the request is missing a URL.
884 | public init(from urlRequest: URLRequest) throws {
| `- error: cannot find type 'URLRequest' in scope
885 | guard let url = urlRequest.url else {
886 | throw ReplayError.invalidRequest("Missing URL")
/host/spi-builder-workspace/Sources/Replay/HAR.swift:848:18: error: cannot find type 'URLRequest' in scope
846 | /// Create an entry from a `URLRequest` and `HTTPURLResponse`.
847 | public init(
848 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
849 | response: HTTPURLResponse,
850 | data: Data,
/host/spi-builder-workspace/Sources/Replay/HAR.swift:849:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
847 | public init(
848 | request: URLRequest,
849 | response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
850 | data: Data,
851 | startTime: Date,
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/Replay/HAR.swift:956:36: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
954 | /// - httpResponse: The response to convert.
955 | /// - data: The response body data.
956 | public init(from httpResponse: HTTPURLResponse, data: Data) throws {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
957 | self.status = httpResponse.statusCode
958 | self.statusText = HTTPURLResponse.localizedString(forStatusCode: 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/Replay/HAR.swift:1010:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
1008 | extension HAR.Entry {
1009 | /// Convert an entry back into `HTTPURLResponse` and body `Data` for playback.
1010 | public func toURLResponse() throws -> (HTTPURLResponse, Data) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
1011 | guard let url = URL(string: request.url) else {
1012 | throw ReplayError.invalidURL(request.url)
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/Replay/Matcher.swift:59:39: error: cannot find type 'URLRequest' in scope
57 | /// Escape hatch for custom matching logic.
58 | /// Compares an incoming request against a candidate request (typically from a recorded entry).
59 | case custom(@Sendable (_ request: URLRequest, _ candidate: URLRequest) -> Bool)
| `- error: cannot find type 'URLRequest' in scope
60 |
61 | /// Whether this matcher can read the request body.
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:59:64: error: cannot find type 'URLRequest' in scope
57 | /// Escape hatch for custom matching logic.
58 | /// Compares an incoming request against a candidate request (typically from a recorded entry).
59 | case custom(@Sendable (_ request: URLRequest, _ candidate: URLRequest) -> Bool)
| `- error: cannot find type 'URLRequest' in scope
60 |
61 | /// Whether this matcher can read the request body.
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:72:26: error: cannot find type 'URLRequest' in scope
70 | }
71 |
72 | func test(_ request: URLRequest, _ candidate: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
73 | switch self {
74 | case .method:
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:72:51: error: cannot find type 'URLRequest' in scope
70 | }
71 |
72 | func test(_ request: URLRequest, _ candidate: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
73 | switch self {
74 | case .method:
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:156:36: error: cannot find type 'URLRequest' in scope
154 | ///
155 | /// This is used by capture as an opt-in filter.
156 | public func matches(_ request: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
157 | for matcher in self {
158 | if !matcher.test(request, request) {
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:166:41: error: cannot find type 'URLRequest' in scope
164 |
165 | /// Finds the first entry whose request matches according to all matchers.
166 | public func firstMatch(for request: URLRequest, in entries: [HAR.Entry]) -> HAR.Entry? {
| `- error: cannot find type 'URLRequest' in scope
167 | firstMatch(for: request, in: entries, filters: [])
168 | }
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:170:34: error: cannot find type 'URLRequest' in scope
168 | }
169 |
170 | func firstMatch(for request: URLRequest, in entries: [HAR.Entry], filters: [Filter]) -> HAR.Entry? {
| `- error: cannot find type 'URLRequest' in scope
171 | for entry in entries {
172 | guard let entryURL = URL(string: entry.request.url) else { continue }
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:197:20: error: cannot find type 'URLRequest' in scope
195 |
196 | private func matches(
197 | _ request: URLRequest, _ candidate: URLRequest, candidateURL: String, filters: [Filter]
| `- error: cannot find type 'URLRequest' in scope
198 | ) -> Bool {
199 | for matcher in self {
/host/spi-builder-workspace/Sources/Replay/Matcher.swift:197:45: error: cannot find type 'URLRequest' in scope
195 |
196 | private func matches(
197 | _ request: URLRequest, _ candidate: URLRequest, candidateURL: String, filters: [Filter]
| `- error: cannot find type 'URLRequest' in scope
198 | ) -> Bool {
199 | for matcher in self {
/host/spi-builder-workspace/Sources/Replay/Playback.swift:17:28: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
15 | public static func session(
16 | configuration: PlaybackConfiguration,
17 | baseConfiguration: URLSessionConfiguration = .ephemeral
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
18 | ) async throws -> URLSession {
19 | let config = baseConfiguration
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:18:23: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
16 | configuration: PlaybackConfiguration,
17 | baseConfiguration: URLSessionConfiguration = .ephemeral
18 | ) async throws -> URLSession {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
19 | let config = baseConfiguration
20 | var protocols = config.protocolClasses ?? []
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/Replay/Playback.swift:17:55: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
15 | public static func session(
16 | configuration: PlaybackConfiguration,
17 | baseConfiguration: URLSessionConfiguration = .ephemeral
| `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
18 | ) async throws -> URLSession {
19 | let config = baseConfiguration
/host/spi-builder-workspace/Sources/Replay/Playback.swift:195:11: error: cannot find type 'URLRequest' in scope
193 | }
194 |
195 | extension URLRequest {
| `- error: cannot find type 'URLRequest' in scope
196 | /// Returns a copy whose body is in `httpBody`, read from `httpBodyStream` if needed.
197 | ///
/host/spi-builder-workspace/Sources/Replay/Playback.swift:265:44: error: cannot find type 'URLRequest' in scope
263 | }
264 |
265 | private func requestDescription(_ request: URLRequest) -> String {
| `- error: cannot find type 'URLRequest' in scope
266 | let method = request.httpMethod ?? "GET"
267 | let url = request.url?.absoluteString ?? "<unknown URL>"
/host/spi-builder-workspace/Sources/Replay/Playback.swift:283:33: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
281 | private let lock = NSLock()
282 | private var streamTask: Task<Void, Never>?
283 | private var urlSessionTask: URLSessionTask?
| `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
284 |
285 | public override class func canInit(with request: URLRequest) -> Bool {
Foundation.URLSessionTask:2:18: note: 'URLSessionTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionTask = AnyObject
| `- note: 'URLSessionTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:285:54: error: cannot find type 'URLRequest' in scope
283 | private var urlSessionTask: URLSessionTask?
284 |
285 | public override class func canInit(with request: URLRequest) -> Bool {
| `- error: cannot find type 'URLRequest' in scope
286 | guard URLProtocol.property(forKey: handledKey, in: request) == nil else {
287 | return false
/host/spi-builder-workspace/Sources/Replay/Playback.swift:292:77: error: cannot find type 'URLRequest' in scope
290 | }
291 |
292 | public override class func canonicalRequest(for request: URLRequest) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
293 | request
294 | }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:292:62: error: cannot find type 'URLRequest' in scope
290 | }
291 |
292 | public override class func canonicalRequest(for request: URLRequest) -> URLRequest {
| `- error: cannot find type 'URLRequest' in scope
293 | request
294 | }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:296:26: error: method does not override any method from its superclass
294 | }
295 |
296 | public override func startLoading() {
| `- error: method does not override any method from its superclass
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
/host/spi-builder-workspace/Sources/Replay/Playback.swift:498:44: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
496 | }
497 |
498 | private func setURLSessionTask(_ task: URLSessionTask) {
| `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
499 | lock.lock()
500 | urlSessionTask = task
Foundation.URLSessionTask:2:18: note: 'URLSessionTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionTask = AnyObject
| `- note: 'URLSessionTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:504:26: error: method does not override any method from its superclass
502 | }
503 |
504 | public override func stopLoading() {
| `- error: method does not override any method from its superclass
505 | lock.lock()
506 | let urlSessionTask = self.urlSessionTask
/host/spi-builder-workspace/Sources/Replay/Playback.swift:277:41: error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
275 | /// For network requests (live/passthrough mode), responses are streamed incrementally,
276 | /// enabling support for Server-Sent Events and other streaming protocols.
277 | public final class PlaybackURLProtocol: URLProtocol, @unchecked Sendable {
| `- error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
278 | private static let handledKey = "ReplayPlaybackHandled"
279 | // `startLoading()` and `stopLoading()` run on the client's thread,
Foundation.URLProtocol:2:18: note: 'URLProtocol' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLProtocol = AnyObject
| `- note: 'URLProtocol' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:520:42: error: cannot find type 'URLSessionDataDelegate' in scope
518 |
519 | /// A delegate that bridges URLSession callbacks to async streams for SSE support.
520 | final class StreamingDelegate: NSObject, URLSessionDataDelegate, @unchecked Sendable {
| `- error: cannot find type 'URLSessionDataDelegate' in scope
521 | /// The response hand-off between URLSession's delegate queue and `waitForResponse()`.
522 | /// URLSession can deliver the response, or fail, before the caller starts to wait.
/host/spi-builder-workspace/Sources/Replay/Playback.swift:525:42: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
523 | private enum ResponseState {
524 | case pending
525 | case waiting(CheckedContinuation<HTTPURLResponse, Error>)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
526 | case ready(Result<HTTPURLResponse, Error>)
527 | case delivered
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/Replay/Playback.swift:526:27: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
524 | case pending
525 | case waiting(CheckedContinuation<HTTPURLResponse, Error>)
526 | case ready(Result<HTTPURLResponse, Error>)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
527 | case delivered
528 | }
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/Replay/Playback.swift:551:44: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
549 | ///
550 | /// Call this method at most once.
551 | func waitForResponse() async throws -> HTTPURLResponse {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
552 | try await withCheckedThrowingContinuation { continuation in
553 | lock.lock()
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/Replay/Playback.swift:570:50: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
568 |
569 | /// Settles the response with the first result; later results are ignored.
570 | private func settleResponse(_ result: Result<HTTPURLResponse, Error>) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
571 | lock.lock()
572 | switch responseState {
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/Replay/Playback.swift:587:50: error: 'ResponseDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
585 | func urlSession(
586 | _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse,
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
| `- error: 'ResponseDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
588 | ) {
589 | if let httpResponse = response as? HTTPURLResponse {
/host/spi-builder-workspace/Sources/Replay/Playback.swift:586:20: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
584 |
585 | func urlSession(
586 | _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
588 | ) {
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/Replay/Playback.swift:586:42: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
584 |
585 | func urlSession(
586 | _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse,
| `- error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
588 | ) {
Foundation.URLSessionDataTask:2:18: note: 'URLSessionDataTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionDataTask = AnyObject
| `- note: 'URLSessionDataTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:586:83: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
584 |
585 | func urlSession(
586 | _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse,
| `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
587 | completionHandler: @escaping (URLSession.ResponseDisposition) -> Void
588 | ) {
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/Replay/Playback.swift:595:32: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
593 | }
594 |
595 | func urlSession(_ session: URLSession, dataTask: URLSessionDataTask, didReceive data: Data) {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
596 | dataContinuation.yield(data)
597 | }
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/Replay/Playback.swift:595:54: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
593 | }
594 |
595 | func urlSession(_ session: URLSession, dataTask: URLSessionDataTask, didReceive data: Data) {
| `- error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
596 | dataContinuation.yield(data)
597 | }
Foundation.URLSessionDataTask:2:18: note: 'URLSessionDataTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionDataTask = AnyObject
| `- note: 'URLSessionDataTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:605:50: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
603 | _ session: URLSession,
604 | didReceive challenge: URLAuthenticationChallenge,
605 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
606 | ) {
607 | forward(challenge, completionHandler: completionHandler)
/host/spi-builder-workspace/Sources/Replay/Playback.swift:603:20: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
601 | // forwarded, otherwise trust decisions silently fall back to default handling.
602 | func urlSession(
603 | _ session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
604 | didReceive challenge: URLAuthenticationChallenge,
605 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
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/Replay/Playback.swift:604:31: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
602 | func urlSession(
603 | _ session: URLSession,
604 | didReceive challenge: URLAuthenticationChallenge,
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
605 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
606 | ) {
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:614:50: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
612 | task: URLSessionTask,
613 | didReceive challenge: URLAuthenticationChallenge,
614 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
615 | ) {
616 | forward(challenge, completionHandler: completionHandler)
/host/spi-builder-workspace/Sources/Replay/Playback.swift:611:20: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
609 |
610 | func urlSession(
611 | _ session: URLSession,
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
612 | task: URLSessionTask,
613 | didReceive challenge: URLAuthenticationChallenge,
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/Replay/Playback.swift:612:15: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
610 | func urlSession(
611 | _ session: URLSession,
612 | task: URLSessionTask,
| `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
613 | didReceive challenge: URLAuthenticationChallenge,
614 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
Foundation.URLSessionTask:2:18: note: 'URLSessionTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionTask = AnyObject
| `- note: 'URLSessionTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:613:31: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
611 | _ session: URLSession,
612 | task: URLSessionTask,
613 | didReceive challenge: URLAuthenticationChallenge,
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
614 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
615 | ) {
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:621:50: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
619 | private func forward(
620 | _ challenge: URLAuthenticationChallenge,
621 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
622 | ) {
623 | guard let urlProtocol, let client = urlProtocol.client else {
/host/spi-builder-workspace/Sources/Replay/Playback.swift:620:22: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
618 |
619 | private func forward(
620 | _ challenge: URLAuthenticationChallenge,
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
621 | completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
622 | ) {
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:642:32: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
640 | }
641 |
642 | func urlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?) {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
643 | if let error = error {
644 | settleResponse(.failure(error))
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/Replay/Playback.swift:642:50: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
640 | }
641 |
642 | func urlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?) {
| `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
643 | if let error = error {
644 | settleResponse(.failure(error))
Foundation.URLSessionTask:2:18: note: 'URLSessionTask' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionTask = AnyObject
| `- note: 'URLSessionTask' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:659:51: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
657 | private var completionHandler: ((URLSession.AuthChallengeDisposition, URLCredential?) -> Void)?
658 |
659 | init(completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) {
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
660 | self.completionHandler = completionHandler
661 | }
/host/spi-builder-workspace/Sources/Replay/Playback.swift:655:59: error: cannot find type 'URLAuthenticationChallengeSender' in scope
653 |
654 | /// Bridges URLProtocolClient challenge decisions back into URLSession's challenge completion handler.
655 | private final class PlaybackChallengeForwarder: NSObject, URLAuthenticationChallengeSender, @unchecked Sendable {
| `- error: cannot find type 'URLAuthenticationChallengeSender' in scope
656 | private let lock = NSLock()
657 | private var completionHandler: ((URLSession.AuthChallengeDisposition, URLCredential?) -> Void)?
/host/spi-builder-workspace/Sources/Replay/Playback.swift:657:49: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
655 | private final class PlaybackChallengeForwarder: NSObject, URLAuthenticationChallengeSender, @unchecked Sendable {
656 | private let lock = NSLock()
657 | private var completionHandler: ((URLSession.AuthChallengeDisposition, URLCredential?) -> Void)?
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
658 |
659 | init(completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) {
/host/spi-builder-workspace/Sources/Replay/Playback.swift:663:28: error: 'URLCredential' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
661 | }
662 |
663 | func use(_ credential: URLCredential, for challenge: URLAuthenticationChallenge) {
| `- error: 'URLCredential' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
664 | complete(.useCredential, credential)
665 | }
Foundation.URLCredential:2:18: note: 'URLCredential' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLCredential = AnyObject
| `- note: 'URLCredential' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:663:58: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
661 | }
662 |
663 | func use(_ credential: URLCredential, for challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
664 | complete(.useCredential, credential)
665 | }
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:667:51: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
665 | }
666 |
667 | func continueWithoutCredential(for challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
668 | // "Continue without a credential" maps to URLSession's default handling,
669 | // not to `.useCredential` with a nil credential.
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:673:30: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
671 | }
672 |
673 | func cancel(_ challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
674 | complete(.cancelAuthenticationChallenge, nil)
675 | }
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:677:48: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
675 | }
676 |
677 | func performDefaultHandling(for challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
678 | complete(.performDefaultHandling, nil)
679 | }
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:681:59: error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
679 | }
680 |
681 | func rejectProtectionSpaceAndContinue(with challenge: URLAuthenticationChallenge) {
| `- error: 'URLAuthenticationChallenge' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
682 | complete(.rejectProtectionSpace, nil)
683 | }
Foundation.URLAuthenticationChallenge:2:18: note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLAuthenticationChallenge = AnyObject
| `- note: 'URLAuthenticationChallenge' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:685:53: error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
683 | }
684 |
685 | private func complete(_ disposition: URLSession.AuthChallengeDisposition, _ credential: URLCredential?) {
| `- error: 'AuthChallengeDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
686 | // A challenge sender may receive more than one callback from a defensive client;
687 | // URLSession completion handlers must only be invoked once.
/host/spi-builder-workspace/Sources/Replay/Playback.swift:685:93: error: 'URLCredential' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
683 | }
684 |
685 | private func complete(_ disposition: URLSession.AuthChallengeDisposition, _ credential: URLCredential?) {
| `- error: 'URLCredential' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
686 | // A challenge sender may receive more than one callback from a defensive client;
687 | // URLSession completion handlers must only be invoked once.
Foundation.URLCredential:2:18: note: 'URLCredential' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLCredential = AnyObject
| `- note: 'URLCredential' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Playback.swift:804:23: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
802 | public enum RequestDisposition: Sendable {
803 | /// Use the recorded entry's response.
804 | case recorded(HTTPURLResponse, Data)
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
805 | /// No match found; go to the network (with optional recording).
806 | case network(shouldRecord: Bool)
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/Replay/Playback.swift:804:14: error: associated value 'recorded' of 'Sendable'-conforming enum 'RequestDisposition' has non-sendable type 'HTTPURLResponse' (aka 'AnyObject')
802 | public enum RequestDisposition: Sendable {
803 | /// Use the recorded entry's response.
804 | case recorded(HTTPURLResponse, Data)
| `- error: associated value 'recorded' of 'Sendable'-conforming enum 'RequestDisposition' has non-sendable type 'HTTPURLResponse' (aka 'AnyObject')
805 | /// No match found; go to the network (with optional recording).
806 | case network(shouldRecord: Bool)
/host/spi-builder-workspace/Sources/Replay/Playback.swift:818:41: error: cannot find type 'URLRequest' in scope
816 | /// - Parameter request: The request to check.
817 | /// - Returns: A disposition indicating how to handle the request.
818 | public func checkRequest(_ request: URLRequest) throws -> RequestDisposition {
| `- error: cannot find type 'URLRequest' in scope
819 | guard let config = configuration else {
820 | throw ReplayError.notConfigured
/host/spi-builder-workspace/Sources/Replay/Playback.swift:869:18: error: cannot find type 'URLRequest' in scope
867 | /// - duration: How long the request took.
868 | public func recordResponse(
869 | request: URLRequest,
| `- error: cannot find type 'URLRequest' in scope
870 | response: HTTPURLResponse,
871 | data: Data,
/host/spi-builder-workspace/Sources/Replay/Playback.swift:870:19: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
868 | public func recordResponse(
869 | request: URLRequest,
870 | response: HTTPURLResponse,
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
871 | data: Data,
872 | duration: TimeInterval,
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/Replay/Playback.swift:932:42: error: cannot find type 'URLRequest' in scope
930 | /// responses like Server-Sent Events. For streaming support, use `checkRequest(_:)`
931 | /// and handle network requests with `URLSession.bytes(for:)`.
932 | public func handleRequest(_ request: URLRequest) async throws -> (HTTPURLResponse, Data) {
| `- error: cannot find type 'URLRequest' in scope
933 | switch try checkRequest(request) {
934 | case .recorded(let response, let data):
/host/spi-builder-workspace/Sources/Replay/Playback.swift:932:71: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
930 | /// responses like Server-Sent Events. For streaming support, use `checkRequest(_:)`
931 | /// and handle network requests with `URLSession.bytes(for:)`.
932 | public func handleRequest(_ request: URLRequest) async throws -> (HTTPURLResponse, Data) {
| `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
933 | switch try checkRequest(request) {
934 | case .recorded(let response, let data):
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/Replay/Playback.swift:297:31: error: cannot find 'request' in scope
295 |
296 | public override func startLoading() {
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find 'request' in scope
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
299 | let markedRequest = mutableRequest as URLRequest
/host/spi-builder-workspace/Sources/Replay/Playback.swift:297:42: error: cannot find type 'NSURLRequest' in scope
295 |
296 | public override func startLoading() {
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find type 'NSURLRequest' in scope
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
299 | let markedRequest = mutableRequest as URLRequest
/host/spi-builder-workspace/Sources/Replay/Playback.swift:297:74: error: cannot find type 'NSMutableURLRequest' in scope
295 |
296 | public override func startLoading() {
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
| `- error: cannot find type 'NSMutableURLRequest' in scope
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
299 | let markedRequest = mutableRequest as URLRequest
/host/spi-builder-workspace/Sources/Replay/Playback.swift:298:21: error: type 'URLProtocol' (aka 'AnyObject') has no member 'setProperty'
296 | public override func startLoading() {
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
| `- error: type 'URLProtocol' (aka 'AnyObject') has no member 'setProperty'
299 | let markedRequest = mutableRequest as URLRequest
300 |
/host/spi-builder-workspace/Sources/Replay/Playback.swift:299:47: error: cannot find type 'URLRequest' in scope
297 | let mutableRequest = (request as NSURLRequest).mutableCopy() as! NSMutableURLRequest
298 | URLProtocol.setProperty(true, forKey: Self.handledKey, in: mutableRequest)
299 | let markedRequest = mutableRequest as URLRequest
| `- error: cannot find type 'URLRequest' in scope
300 |
301 | // URLProtocol predates Swift concurrency; wrap self to cross isolation boundary
/host/spi-builder-workspace/Sources/Replay/Replay.swift:86:32: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
84 | /// This is a convenience for tests and tools that want a session without
85 | /// manually configuring `URLSessionConfiguration`.
86 | public static var session: URLSession {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
87 | let config = URLSessionConfiguration.ephemeral
88 | configure(config)
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/Replay/Replay.swift:103:51: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
101 | /// Configure a `URLSessionConfiguration` with `PlaybackURLProtocol`
102 | /// inserted at highest priority.
103 | public static func configure(_ configuration: URLSessionConfiguration) {
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
104 | var protocols = configuration.protocolClasses ?? []
105 | if !protocols.contains(where: { $0 == PlaybackURLProtocol.self }) {
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Replay.swift:113:15: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
111 | /// Create a new `URLSessionConfiguration` with Replay pre-configured.
112 | public static func configuration(
113 | base: URLSessionConfiguration = .default
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
114 | ) -> URLSessionConfiguration {
115 | let config = base
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Replay.swift:114:10: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
112 | public static func configuration(
113 | base: URLSessionConfiguration = .default
114 | ) -> URLSessionConfiguration {
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
115 | let config = base
116 | configure(config)
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Replay.swift:113:42: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
111 | /// Create a new `URLSessionConfiguration` with Replay pre-configured.
112 | public static func configuration(
113 | base: URLSessionConfiguration = .default
| `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
114 | ) -> URLSessionConfiguration {
115 | let config = base
/host/spi-builder-workspace/Sources/Replay/Replay.swift:122:24: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
120 | /// Create a `URLSession` with Replay pre-configured.
121 | public static func makeSession(
122 | configuration: URLSessionConfiguration = .default
| `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
123 | ) -> URLSession {
124 | let config = self.configuration(base: configuration)
Foundation.URLSessionConfiguration:2:18: note: 'URLSessionConfiguration' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSessionConfiguration = AnyObject
| `- note: 'URLSessionConfiguration' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/Replay/Replay.swift:123:10: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
121 | public static func makeSession(
122 | configuration: URLSessionConfiguration = .default
123 | ) -> URLSession {
| `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
124 | let config = self.configuration(base: configuration)
125 |
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/Replay/Replay.swift:122:51: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
120 | /// Create a `URLSession` with Replay pre-configured.
121 | public static func makeSession(
122 | configuration: URLSessionConfiguration = .default
| `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
123 | ) -> URLSession {
124 | let config = self.configuration(base: configuration)
[27/43] Compiling Replay Matcher.swift
BUILD FAILURE 6.1 wasm