Build Information
Successful build of BSONSerialization with Swift 6.0 for macOS (SPM).
Swift 6 data race errors: 2
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/frizlab/bsonserialization.git
Reference: main
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/frizlab/bsonserialization
* branch main -> FETCH_HEAD
* [new branch] main -> origin/main
HEAD is now at 72abf22 Add the compressed BSON binary subtype
Cloned https://github.com/frizlab/bsonserialization.git
Revision (git rev-parse @):
72abf222b6c33fc6b40c906a83984cbbf90ec155
SUCCESS checkout https://github.com/frizlab/bsonserialization.git at main
========================================
Build
========================================
Selected platform: macosSpm
Swift version: 6.0
Building package at path: $workDir
https://github.com/frizlab/bsonserialization.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/3] Write sources
[2/3] Write swift-version-6F35C1178C84523A.txt
[4/13] Compiling StreamReader DataReader.swift
[5/13] Compiling StreamReader StreamReaderErrors.swift
[6/13] Compiling StreamReader StreamReader.swift
[7/13] Compiling StreamReader InputStreamReader.swift
[8/13] Compiling StreamReader Matching.swift
[9/13] Compiling StreamReader URLSessionStreamTaskReader.swift
[10/13] Compiling StreamReader GenericStreamReader.swift
[11/13] Compiling StreamReader FileHandleReader.swift
[12/13] Compiling StreamReader FileDescriptorReader.swift
[13/13] Emitting module StreamReader
[14/18] Compiling BSONSerialization Errors.swift
/Users/admin/builder/spi-builder-workspace/Sources/BSONSerialization/Errors.swift:70:7: warning: associated value 'invalidBSONObject(invalidElement:)' of 'Sendable'-conforming enum 'BSONSerializationError' has non-sendable type 'Any'; this is an error in the Swift 6 language mode
68 | An invalid BSON object was given to be serialized.
69 | The invalid element is passed in argument to this error. */
70 | case invalidBSONObject(invalidElement: Any)
| `- warning: associated value 'invalidBSONObject(invalidElement:)' of 'Sendable'-conforming enum 'BSONSerializationError' has non-sendable type 'Any'; this is an error in the Swift 6 language mode
71 | /**
72 | Tried to serialize an unserializable string (using the C representation).
[15/18] Emitting module BSONSerialization
/Users/admin/builder/spi-builder-workspace/Sources/BSONSerialization/BSONSerialization.swift:41:21: warning: static property 'skipSizes' is not concurrency-safe because non-'Sendable' type 'BSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
32 | }
33 |
34 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
35 |
36 | public let rawValue: Int
:
39 | Set all sizes to 0 in generated BSON.
40 | Mainly useful internally for optimization purposes. */
41 | public static let skipSizes = WritingOptions(rawValue: 1 << 0)
| |- warning: static property 'skipSizes' is not concurrency-safe because non-'Sendable' type 'BSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'skipSizes' 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
42 |
43 | public init(rawValue v: Int) {
/Users/admin/builder/spi-builder-workspace/Sources/BSONSerialization/Errors.swift:70:7: warning: associated value 'invalidBSONObject(invalidElement:)' of 'Sendable'-conforming enum 'BSONSerializationError' has non-sendable type 'Any'; this is an error in the Swift 6 language mode
68 | An invalid BSON object was given to be serialized.
69 | The invalid element is passed in argument to this error. */
70 | case invalidBSONObject(invalidElement: Any)
| `- warning: associated value 'invalidBSONObject(invalidElement:)' of 'Sendable'-conforming enum 'BSONSerializationError' has non-sendable type 'Any'; this is an error in the Swift 6 language mode
71 | /**
72 | Tried to serialize an unserializable string (using the C representation).
[16/18] Compiling BSONSerialization OutputStream+Utils.swift
[17/18] Compiling BSONSerialization BSONClasses.swift
[18/18] Compiling BSONSerialization BSONSerialization.swift
/Users/admin/builder/spi-builder-workspace/Sources/BSONSerialization/BSONSerialization.swift:41:21: warning: static property 'skipSizes' is not concurrency-safe because non-'Sendable' type 'BSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
32 | }
33 |
34 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
35 |
36 | public let rawValue: Int
:
39 | Set all sizes to 0 in generated BSON.
40 | Mainly useful internally for optimization purposes. */
41 | public static let skipSizes = WritingOptions(rawValue: 1 << 0)
| |- warning: static property 'skipSizes' is not concurrency-safe because non-'Sendable' type 'BSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'skipSizes' 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
42 |
43 | public init(rawValue v: Int) {
Build complete! (27.29s)
Fetching https://github.com/Frizlab/stream-reader.git
[1/995] Fetching stream-reader
Fetched https://github.com/Frizlab/stream-reader.git from cache (0.89s)
Computing version for https://github.com/Frizlab/stream-reader.git
Computed https://github.com/Frizlab/stream-reader.git at 3.5.1 (0.69s)
Creating working copy for https://github.com/Frizlab/stream-reader.git
Working copy of https://github.com/Frizlab/stream-reader.git resolved at 3.5.1
Build complete.
{
"dependencies" : [
{
"identity" : "stream-reader",
"requirement" : {
"range" : [
{
"lower_bound" : "3.0.0",
"upper_bound" : "4.0.0"
}
]
},
"type" : "sourceControl",
"url" : "https://github.com/Frizlab/stream-reader.git"
}
],
"manifest_display_name" : "BSONSerialization",
"name" : "BSONSerialization",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
],
"products" : [
{
"name" : "BSONSerialization",
"targets" : [
"BSONSerialization"
],
"type" : {
"library" : [
"automatic"
]
}
}
],
"targets" : [
{
"c99name" : "BSONSerializationTests",
"module_type" : "SwiftTarget",
"name" : "BSONSerializationTests",
"path" : "Tests/BSONSerializationTests",
"sources" : [
"BSONSerializationTests.swift",
"TestHelpers.swift"
],
"target_dependencies" : [
"BSONSerialization"
],
"type" : "test"
},
{
"c99name" : "BSONSerialization",
"module_type" : "SwiftTarget",
"name" : "BSONSerialization",
"path" : "Sources/BSONSerialization",
"product_dependencies" : [
"StreamReader"
],
"product_memberships" : [
"BSONSerialization"
],
"sources" : [
"BSONClasses.swift",
"BSONSerialization.swift",
"Errors.swift",
"OutputStream+Utils.swift"
],
"type" : "library"
}
],
"tools_version" : "5.1"
}
Done.