The Swift Package Index logo.Swift Package Index

Track the adoption of Swift 6 strict concurrency checks for data race safety. How many packages are Ready for Swift 6?

Build Information

Failed to build EventSource, reference master (78934b), with Swift 6.0 for Linux on 3 Nov 2024 00:20:22 UTC.

Build Command

bash -c docker run --pull=always --rm -v "checkouts-4606859-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:basic-6.0-latest swift build --triple x86_64-unknown-linux-gnu -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete 2>&1

Build Log

========================================
RunAll
========================================
Builder version: 4.56.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/inaka/EventSource.git
Reference: master
Initialized empty Git repository in /host/spi-builder-workspace/.git/
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: 	git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: 	git branch -m <name>
From https://github.com/inaka/EventSource
 * branch            master     -> FETCH_HEAD
 * [new branch]      master     -> origin/master
HEAD is now at 78934b3 Merge pull request #134 from daniel-andersen/master
Cloned https://github.com/inaka/EventSource.git
Revision (git rev-parse @):
78934b361891c7d0fa3d399d128e959f0c94d267
SUCCESS checkout https://github.com/inaka/EventSource.git at master
========================================
Build
========================================
Selected platform:         linux
Swift version:             6.0
Building package at path:  $PWD
https://github.com/inaka/EventSource.git
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4606859-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:basic-6.0-latest swift build --triple x86_64-unknown-linux-gnu -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete 2>&1
basic-6.0-latest: Pulling from finestructure/spi-images
Digest: sha256:47d26c99ca4f1ac0a332c85fd5b13ff4390e72115219984a57a68fe9d1063a05
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:basic-6.0-latest
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-24593BA9C3E375BF.txt
[3/6] Compiling EventSource EventStreamParser.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)
[4/6] Emitting module EventSource
/host/spi-builder-workspace/EventSource/EventSource.swift:93:29: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 91 |     private var operationQueue: OperationQueue
 92 |     private var mainQueue = DispatchQueue.main
 93 |     private var urlSession: URLSession?
    |                             `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 94 |
 95 |     public init(
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/EventSource/EventSource.swift:148:37: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
146 | 	}
147 |
148 |     open 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.
149 |
150 | 		if readyState != .open {
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/EventSource/EventSource.swift:148:59: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
146 | 	}
147 |
148 |     open 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.
149 |
150 | 		if readyState != .open {
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/EventSource/EventSource.swift:162:67: error: 'ResponseDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
160 |                          dataTask: URLSessionDataTask,
161 |                          didReceive response: URLResponse,
162 |                          completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) {
    |                                                                   `- error: 'ResponseDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
163 |
164 |         completionHandler(URLSession.ResponseDisposition.allow)
/host/spi-builder-workspace/EventSource/EventSource.swift:159:37: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
157 |     }
158 |
159 |     open func urlSession(_ session: URLSession,
    |                                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
160 |                          dataTask: URLSessionDataTask,
161 |                          didReceive response: URLResponse,
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/EventSource/EventSource.swift:160:36: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
158 |
159 |     open func urlSession(_ session: URLSession,
160 |                          dataTask: URLSessionDataTask,
    |                                    `- error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
161 |                          didReceive response: URLResponse,
162 |                          completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) {
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/EventSource/EventSource.swift:161:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
159 |     open func urlSession(_ session: URLSession,
160 |                          dataTask: URLSessionDataTask,
161 |                          didReceive response: URLResponse,
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
162 |                          completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) {
163 |
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/EventSource/EventSource.swift:170:37: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
168 |     }
169 |
170 |     open func urlSession(_ session: URLSession,
    |                                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
171 |                          task: URLSessionTask,
172 |                          didCompleteWithError error: 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/EventSource/EventSource.swift:171:32: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
169 |
170 |     open func urlSession(_ session: URLSession,
171 |                          task: URLSessionTask,
    |                                `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
172 |                          didCompleteWithError error: Error?) {
173 |
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/EventSource/EventSource.swift:186:46: error: cannot find type 'URLRequest' in scope
184 |                          task: URLSessionTask,
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
186 |                          newRequest request: URLRequest,
    |                                              `- error: cannot find type 'URLRequest' in scope
187 |                          completionHandler: @escaping (URLRequest?) -> Void) {
188 |
/host/spi-builder-workspace/EventSource/EventSource.swift:187:56: error: cannot find type 'URLRequest' in scope
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
186 |                          newRequest request: URLRequest,
187 |                          completionHandler: @escaping (URLRequest?) -> Void) {
    |                                                        `- error: cannot find type 'URLRequest' in scope
188 |
189 |         var newRequest = request
/host/spi-builder-workspace/EventSource/EventSource.swift:183:37: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
181 |     }
182 |
183 |     open func urlSession(_ session: URLSession,
    |                                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
184 |                          task: URLSessionTask,
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/EventSource/EventSource.swift:184:32: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
182 |
183 |     open func urlSession(_ session: URLSession,
184 |                          task: URLSessionTask,
    |                                `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
186 |                          newRequest request: URLRequest,
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/EventSource/EventSource.swift:185:63: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
183 |     open func urlSession(_ session: URLSession,
184 |                          task: URLSessionTask,
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
    |                                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
186 |                          newRequest request: URLRequest,
187 |                          completionHandler: @escaping (URLRequest?) -> Void) {
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/EventSource/EventSource.swift:76:56: error: cannot find type 'URLSessionDataDelegate' in scope
 74 | }
 75 |
 76 | open class EventSource: NSObject, EventSourceProtocol, URLSessionDataDelegate {
    |                                                        `- error: cannot find type 'URLSessionDataDelegate' in scope
 77 |     static let DefaultRetryTime = 3000
 78 |
/host/spi-builder-workspace/EventSource/EventSource.swift:197:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
195 | internal extension EventSource {
196 |
197 |     func sessionConfiguration(lastEventId: String?) -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
198 |
199 |         var additionalHeaders = headers
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
[5/6] Compiling EventSource Event.swift
/host/spi-builder-workspace/EventSource/Event.swift:87:37: error: cannot convert value of type 'UnsafeMutablePointer<NSString?>' to expected argument type 'UnsafeMutablePointer<String?>'
 85 |         var key: NSString?, value: NSString?
 86 |         let scanner = Scanner(string: line)
 87 |         scanner.scanUpTo(":", into: &key)
    |                                     |- error: cannot convert value of type 'UnsafeMutablePointer<NSString?>' to expected argument type 'UnsafeMutablePointer<String?>'
    |                                     `- note: arguments to generic parameter 'Pointee' ('NSString?' and 'String?') are expected to be equal
 88 |         scanner.scanString(":", into: nil)
 89 |
/host/spi-builder-workspace/EventSource/Event.swift:88:17: warning: 'scanString(_:into:)' is deprecated: renamed to 'scanString(_:)'
 86 |         let scanner = Scanner(string: line)
 87 |         scanner.scanUpTo(":", into: &key)
 88 |         scanner.scanString(":", into: nil)
    |                 |- warning: 'scanString(_:into:)' is deprecated: renamed to 'scanString(_:)'
    |                 `- note: use 'scanString(_:)' instead
 89 |
 90 |         for newline in newLineCharacters {
/host/spi-builder-workspace/EventSource/Event.swift:91:48: error: cannot convert value of type 'UnsafeMutablePointer<NSString?>' to expected argument type 'UnsafeMutablePointer<String?>'
 89 |
 90 |         for newline in newLineCharacters {
 91 |             if scanner.scanUpTo(newline, into: &value) {
    |                                                |- error: cannot convert value of type 'UnsafeMutablePointer<NSString?>' to expected argument type 'UnsafeMutablePointer<String?>'
    |                                                `- note: arguments to generic parameter 'Pointee' ('NSString?' and 'String?') are expected to be equal
 92 |                 break
 93 |             }
[6/6] Compiling EventSource EventSource.swift
/host/spi-builder-workspace/EventSource/EventSource.swift:93:29: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 91 |     private var operationQueue: OperationQueue
 92 |     private var mainQueue = DispatchQueue.main
 93 |     private var urlSession: URLSession?
    |                             `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 94 |
 95 |     public init(
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/EventSource/EventSource.swift:148:37: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
146 | 	}
147 |
148 |     open 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.
149 |
150 | 		if readyState != .open {
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/EventSource/EventSource.swift:148:59: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
146 | 	}
147 |
148 |     open 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.
149 |
150 | 		if readyState != .open {
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/EventSource/EventSource.swift:162:67: error: 'ResponseDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
160 |                          dataTask: URLSessionDataTask,
161 |                          didReceive response: URLResponse,
162 |                          completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) {
    |                                                                   `- error: 'ResponseDisposition' is not a member type of type 'Foundation.URLSession' (aka 'AnyObject')
163 |
164 |         completionHandler(URLSession.ResponseDisposition.allow)
/host/spi-builder-workspace/EventSource/EventSource.swift:159:37: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
157 |     }
158 |
159 |     open func urlSession(_ session: URLSession,
    |                                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
160 |                          dataTask: URLSessionDataTask,
161 |                          didReceive response: URLResponse,
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/EventSource/EventSource.swift:160:36: error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
158 |
159 |     open func urlSession(_ session: URLSession,
160 |                          dataTask: URLSessionDataTask,
    |                                    `- error: 'URLSessionDataTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
161 |                          didReceive response: URLResponse,
162 |                          completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) {
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/EventSource/EventSource.swift:161:47: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
159 |     open func urlSession(_ session: URLSession,
160 |                          dataTask: URLSessionDataTask,
161 |                          didReceive response: URLResponse,
    |                                               `- error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
162 |                          completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) {
163 |
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/EventSource/EventSource.swift:170:37: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
168 |     }
169 |
170 |     open func urlSession(_ session: URLSession,
    |                                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
171 |                          task: URLSessionTask,
172 |                          didCompleteWithError error: 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/EventSource/EventSource.swift:171:32: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
169 |
170 |     open func urlSession(_ session: URLSession,
171 |                          task: URLSessionTask,
    |                                `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
172 |                          didCompleteWithError error: Error?) {
173 |
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/EventSource/EventSource.swift:186:46: error: cannot find type 'URLRequest' in scope
184 |                          task: URLSessionTask,
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
186 |                          newRequest request: URLRequest,
    |                                              `- error: cannot find type 'URLRequest' in scope
187 |                          completionHandler: @escaping (URLRequest?) -> Void) {
188 |
/host/spi-builder-workspace/EventSource/EventSource.swift:187:56: error: cannot find type 'URLRequest' in scope
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
186 |                          newRequest request: URLRequest,
187 |                          completionHandler: @escaping (URLRequest?) -> Void) {
    |                                                        `- error: cannot find type 'URLRequest' in scope
188 |
189 |         var newRequest = request
/host/spi-builder-workspace/EventSource/EventSource.swift:183:37: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
181 |     }
182 |
183 |     open func urlSession(_ session: URLSession,
    |                                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
184 |                          task: URLSessionTask,
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/EventSource/EventSource.swift:184:32: error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
182 |
183 |     open func urlSession(_ session: URLSession,
184 |                          task: URLSessionTask,
    |                                `- error: 'URLSessionTask' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
186 |                          newRequest request: URLRequest,
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/EventSource/EventSource.swift:185:63: error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
183 |     open func urlSession(_ session: URLSession,
184 |                          task: URLSessionTask,
185 |                          willPerformHTTPRedirection response: HTTPURLResponse,
    |                                                               `- error: 'HTTPURLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
186 |                          newRequest request: URLRequest,
187 |                          completionHandler: @escaping (URLRequest?) -> Void) {
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/EventSource/EventSource.swift:76:56: error: cannot find type 'URLSessionDataDelegate' in scope
 74 | }
 75 |
 76 | open class EventSource: NSObject, EventSourceProtocol, URLSessionDataDelegate {
    |                                                        `- error: cannot find type 'URLSessionDataDelegate' in scope
 77 |     static let DefaultRetryTime = 3000
 78 |
/host/spi-builder-workspace/EventSource/EventSource.swift:197:56: error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
195 | internal extension EventSource {
196 |
197 |     func sessionConfiguration(lastEventId: String?) -> URLSessionConfiguration {
    |                                                        `- error: 'URLSessionConfiguration' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
198 |
199 |         var additionalHeaders = headers
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/EventSource/EventSource.swift:114:22: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
112 |
113 |         let configuration = sessionConfiguration(lastEventId: lastEventId)
114 |         urlSession = URLSession(configuration: configuration, delegate: self, delegateQueue: operationQueue)
    |                      `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
115 |         urlSession?.dataTask(with: url).resume()
116 |     }
/host/spi-builder-workspace/EventSource/EventSource.swift:115:21: error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
113 |         let configuration = sessionConfiguration(lastEventId: lastEventId)
114 |         urlSession = URLSession(configuration: configuration, delegate: self, delegateQueue: operationQueue)
115 |         urlSession?.dataTask(with: url).resume()
    |                     `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'dataTask'
116 |     }
117 |
/host/spi-builder-workspace/EventSource/EventSource.swift:120:21: error: value of type 'URLSession' (aka 'AnyObject') has no member 'invalidateAndCancel'
118 |     public func disconnect() {
119 |         readyState = .closed
120 |         urlSession?.invalidateAndCancel()
    |                     `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'invalidateAndCancel'
121 |     }
122 |
/host/spi-builder-workspace/EventSource/EventSource.swift:164:38: error: type 'URLSession' (aka 'AnyObject') has no member 'ResponseDisposition'
162 |                          completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) {
163 |
164 |         completionHandler(URLSession.ResponseDisposition.allow)
    |                                      `- error: type 'URLSession' (aka 'AnyObject') has no member 'ResponseDisposition'
165 |
166 |         readyState = .open
/host/spi-builder-workspace/EventSource/EventSource.swift:167:42: warning: capture of 'self' with non-sendable type 'EventSource?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
 74 | }
 75 |
 76 | open class EventSource: NSObject, EventSourceProtocol, URLSessionDataDelegate {
    |            `- note: class 'EventSource' does not conform to the 'Sendable' protocol
 77 |     static let DefaultRetryTime = 3000
 78 |
    :
165 |
166 |         readyState = .open
167 |         mainQueue.async { [weak self] in self?.onOpenCallback?() }
    |                                          `- warning: capture of 'self' with non-sendable type 'EventSource?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
168 |     }
169 |
/host/spi-builder-workspace/EventSource/EventSource.swift:174:46: error: value of type 'URLSessionTask' (aka 'AnyObject') has no member 'response'
172 |                          didCompleteWithError error: Error?) {
173 |
174 |         guard let responseStatusCode = (task.response as? HTTPURLResponse)?.statusCode else {
    |                                              `- error: value of type 'URLSessionTask' (aka 'AnyObject') has no member 'response'
175 |             mainQueue.async { [weak self] in self?.onComplete?(nil, nil, error as NSError?) }
176 |             return
/host/spi-builder-workspace/EventSource/EventSource.swift:174:77: error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
172 |                          didCompleteWithError error: Error?) {
173 |
174 |         guard let responseStatusCode = (task.response as? HTTPURLResponse)?.statusCode else {
    |                                                                             `- error: value of type 'HTTPURLResponse' (aka 'AnyObject') has no member 'statusCode'
175 |             mainQueue.async { [weak self] in self?.onComplete?(nil, nil, error as NSError?) }
176 |             return
/host/spi-builder-workspace/EventSource/EventSource.swift:175:46: warning: capture of 'self' with non-sendable type 'EventSource?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
 74 | }
 75 |
 76 | open class EventSource: NSObject, EventSourceProtocol, URLSessionDataDelegate {
    |            `- note: class 'EventSource' does not conform to the 'Sendable' protocol
 77 |     static let DefaultRetryTime = 3000
 78 |
    :
173 |
174 |         guard let responseStatusCode = (task.response as? HTTPURLResponse)?.statusCode else {
175 |             mainQueue.async { [weak self] in self?.onComplete?(nil, nil, error as NSError?) }
    |                                              `- warning: capture of 'self' with non-sendable type 'EventSource?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
176 |             return
177 |         }
/host/spi-builder-workspace/EventSource/EventSource.swift:207:60: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
205 |         additionalHeaders["Cache-Control"] = "no-cache"
206 |
207 |         let sessionConfiguration = URLSessionConfiguration.default
    |                                                            `- error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'default'
208 |         sessionConfiguration.timeoutIntervalForRequest = TimeInterval(INT_MAX)
209 |         sessionConfiguration.timeoutIntervalForResource = TimeInterval(INT_MAX)
/host/spi-builder-workspace/EventSource/EventSource.swift:233:50: warning: capture of 'self' with non-sendable type 'EventSource?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
 74 | }
 75 |
 76 | open class EventSource: NSObject, EventSourceProtocol, URLSessionDataDelegate {
    |            `- note: class 'EventSource' does not conform to the 'Sendable' protocol
 77 |     static let DefaultRetryTime = 3000
 78 |
    :
231 |
232 |             if event.event == nil || event.event == "message" {
233 |                 mainQueue.async { [weak self] in self?.onMessageCallback?(event.id, "message", event.data) }
    |                                                  `- warning: capture of 'self' with non-sendable type 'EventSource?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
234 |             }
235 |
/host/spi-builder-workspace/EventSource/EventSource.swift:237:35: warning: capture of 'eventHandler' with non-sendable type '(String?, String?, String?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
235 |
236 |             if let eventName = event.event, let eventHandler = eventListeners[eventName] {
237 |                 mainQueue.async { eventHandler(event.id, event.event, event.data) }
    |                                   |- warning: capture of 'eventHandler' with non-sendable type '(String?, String?, String?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
    |                                   `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
238 |             }
239 |         }
BUILD FAILURE 6.0 linux