Build Information
Successful build of SwiftRestClient with Swift 6.0 for macOS (SPM).
Swift 6 data race errors: 1
Build Command
env DEVELOPER_DIR=/Applications/Xcode-15.3.0.app xcrun --toolchain org.swift.600202405261a swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Build Log
========================================
RunAll
========================================
Builder version: 4.40.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/duhnnie/SwiftRestClient.git
Reference: main
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/duhnnie/SwiftRestClient
* branch main -> FETCH_HEAD
* [new branch] main -> origin/main
HEAD is now at f6828e8 Merge pull request #8 from duhnnie/develop
Cloned https://github.com/duhnnie/SwiftRestClient.git
Revision (git rev-parse @):
f6828e84d000aa9fc05137ce459d0013e3474831
SUCCESS checkout https://github.com/duhnnie/SwiftRestClient.git at main
========================================
Build
========================================
Selected platform: macosSpm
Swift version: 6.0
Building package at path: $workDir
https://github.com/duhnnie/SwiftRestClient.git
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-15.3.0.app xcrun --toolchain org.swift.600202405261a swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-6F35C1178C84523A.txt
[3/5] Compiling SwiftRestClient HTTPFormURLEncoded.swift
[4/5] Emitting module SwiftRestClient
/Users/admin/builder/spi-builder-workspace/Sources/SwiftRestClient/SwiftRestClient.swift:12:23: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'SwiftRestClient' may have shared mutable state; this is an error in the Swift 6 language mode
4 | #endif
5 |
6 | public class SwiftRestClient {
| `- note: class 'SwiftRestClient' does not conform to the 'Sendable' protocol
7 | private enum HTTPMethod: String {
8 | case GET
:
10 | }
11 |
12 | public static let shared = SwiftRestClient()
| |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'SwiftRestClient' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'shared' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
13 | public typealias RequestCompletion = (Data?, URLResponse?, Error?) -> Void
14 | public typealias Headers = [String: String]
[5/5] Compiling SwiftRestClient SwiftRestClient.swift
/Users/admin/builder/spi-builder-workspace/Sources/SwiftRestClient/SwiftRestClient.swift:12:23: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'SwiftRestClient' may have shared mutable state; this is an error in the Swift 6 language mode
4 | #endif
5 |
6 | public class SwiftRestClient {
| `- note: class 'SwiftRestClient' does not conform to the 'Sendable' protocol
7 | private enum HTTPMethod: String {
8 | case GET
:
10 | }
11 |
12 | public static let shared = SwiftRestClient()
| |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'SwiftRestClient' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'shared' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
13 | public typealias RequestCompletion = (Data?, URLResponse?, Error?) -> Void
14 | public typealias Headers = [String: String]
/Users/admin/builder/spi-builder-workspace/Sources/SwiftRestClient/SwiftRestClient.swift:37:85: warning: passing non-sendable parameter 'onCompletion' to function expecting a @Sendable closure
21 | body: Data? = nil,
22 | headers: Headers? = nil,
23 | onCompletion: @escaping RequestCompletion
| `- note: parameter 'onCompletion' is implicitly non-sendable
24 | ) -> Void {
25 | var request = URLRequest(url: url)
:
35 | request.httpBody = body
36 |
37 | let dataTask = URLSession.shared.dataTask(with: request, completionHandler: onCompletion)
| `- warning: passing non-sendable parameter 'onCompletion' to function expecting a @Sendable closure
38 |
39 | dataTask.resume()
Build complete! (16.87s)
Build complete.
{
"dependencies" : [
],
"manifest_display_name" : "SwiftRestClient",
"name" : "SwiftRestClient",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
{
"name" : "ios",
"version" : "11.0"
},
{
"name" : "macos",
"version" : "10.15"
},
{
"name" : "watchos",
"version" : "4.0"
},
{
"name" : "tvos",
"version" : "11.0"
},
{
"name" : "maccatalyst",
"version" : "13.0"
}
],
"products" : [
{
"name" : "SwiftRestClient",
"targets" : [
"SwiftRestClient"
],
"type" : {
"library" : [
"automatic"
]
}
}
],
"swift_languages_versions" : [
"5"
],
"targets" : [
{
"c99name" : "SwiftRestClientTests",
"module_type" : "SwiftTarget",
"name" : "SwiftRestClientTests",
"path" : "Tests/SwiftRestClientTests",
"sources" : [
"SwiftRestClientTests.swift"
],
"target_dependencies" : [
"SwiftRestClient"
],
"type" : "test"
},
{
"c99name" : "SwiftRestClient",
"module_type" : "SwiftTarget",
"name" : "SwiftRestClient",
"path" : "Sources/SwiftRestClient",
"product_memberships" : [
"SwiftRestClient"
],
"sources" : [
"Encoders/HTTPFormURLEncoded.swift",
"SwiftRestClient.swift"
],
"type" : "library"
}
],
"tools_version" : "5.5"
}
Done.