Build Information
Successful build of Transcoding, reference main (80cad2
), with Swift 6.0 for macOS (SPM) on 4 Nov 2024 10:08:32 UTC.
Swift 6 data race errors: 4
Build Command
env DEVELOPER_DIR=/Applications/Xcode-16.1.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Build Log
========================================
RunAll
========================================
Builder version: 4.56.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/finnvoor/Transcoding.git
Reference: main
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/finnvoor/Transcoding
* branch main -> FETCH_HEAD
* [new branch] main -> origin/main
HEAD is now at 80cad2a Update README.md
Cloned https://github.com/finnvoor/Transcoding.git
Revision (git rev-parse @):
80cad2adefce9d143e42d589a22c3c668b37fc02
SUCCESS checkout https://github.com/finnvoor/Transcoding.git at main
========================================
ResolveProductDependencies
========================================
Resolving dependencies ...
{
"identity": ".resolve-product-dependencies",
"name": "resolve-dependencies",
"url": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies",
"version": "unspecified",
"path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies",
"dependencies": [
{
"identity": "transcoding",
"name": "Transcoding",
"url": "https://github.com/finnvoor/Transcoding.git",
"version": "unspecified",
"path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/Transcoding",
"dependencies": [
]
}
]
}
Fetching https://github.com/finnvoor/Transcoding.git
[1/114] Fetching transcoding
Fetched https://github.com/finnvoor/Transcoding.git from cache (0.66s)
Creating working copy for https://github.com/finnvoor/Transcoding.git
Working copy of https://github.com/finnvoor/Transcoding.git resolved at main (80cad2a)
warning: '.resolve-product-dependencies': dependency 'transcoding' is not used by any target
Found 0 product dependencies
========================================
Build
========================================
Selected platform: macosSpm
Swift version: 6.0
Building package at path: $PWD
https://github.com/finnvoor/Transcoding.git
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-16.1.0.app xcrun 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--7754E27361AE5C74.txt
[3/14] Compiling Transcoding HEVCNALU.swift
[4/15] Compiling Transcoding VideoDecoderAnnexBAdaptor.swift
[5/15] Compiling Transcoding VideoEncoder.swift
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder.swift:42:17: warning: capture of 'self' with non-sendable type 'VideoEncoder?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
8 | // MARK: - VideoEncoder
9 |
10 | public final class VideoEncoder {
| `- note: class 'VideoEncoder' does not conform to the 'Sendable' protocol
11 | // MARK: Lifecycle
12 |
:
40 | continuations[id] = continuation
41 | continuation.onTermination = { [weak self] _ in
42 | self?.continuations[id] = nil
| `- warning: capture of 'self' with non-sendable type 'VideoEncoder?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
43 | }
44 | }
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder.swift:106:31: warning: capture of 'self' with non-sendable type 'VideoEncoder?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
8 | // MARK: - VideoEncoder
9 |
10 | public final class VideoEncoder {
| `- note: class 'VideoEncoder' does not conform to the 'Sendable' protocol
11 | // MARK: Lifecycle
12 |
:
104 | duration: duration
105 | ) { [weak self] status, _, sampleBuffer in
106 | guard let self else { return }
| `- warning: capture of 'self' with non-sendable type 'VideoEncoder?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
107 | outputQueue.sync {
108 | do {
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder.swift:112:46: warning: sending 'sampleBuffer' risks causing data races; this is an error in the Swift 6 language mode
110 | guard let sampleBuffer else { return }
111 | for continuation in self.continuations.values {
112 | continuation.yield(sampleBuffer)
| |- warning: sending 'sampleBuffer' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'sampleBuffer' is passed as a 'sending' parameter; Uses in callee may race with later task-isolated uses
113 | }
114 | } catch {
[6/15] Compiling Transcoding VideoEncoderAnnexBAdaptor.swift
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoderAnnexBAdaptor.swift:104:17: warning: capture of 'self' with non-sendable type 'VideoEncoderAnnexBAdaptor?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
3 | import OSLog
4 |
5 | public final class VideoEncoderAnnexBAdaptor {
| `- note: class 'VideoEncoderAnnexBAdaptor' does not conform to the 'Sendable' protocol
6 | // MARK: Lifecycle
7 |
:
102 | continuations[id] = continuation
103 | continuation.onTermination = { [weak self] _ in
104 | self?.continuations[id] = nil
| `- warning: capture of 'self' with non-sendable type 'VideoEncoderAnnexBAdaptor?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
105 | }
106 | }
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoderAnnexBAdaptor.swift:10:31: warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
8 | public init(videoEncoder: VideoEncoder) {
9 | self.videoEncoder = videoEncoder
10 | conversionTask = Task { [weak self] in
| `- warning: passing closure as a 'sending' parameter risks causing data races between code in the current task and concurrent execution of the closure; this is an error in the Swift 6 language mode
11 | for await sampleBuffer in videoEncoder.encodedSampleBuffers {
| `- note: closure captures non-Sendable 'videoEncoder'
12 | guard let self else { return }
| `- note: closure captures non-Sendable 'self'
13 | let sampleAttachments = CMSampleBufferGetSampleAttachmentsArray(
14 | sampleBuffer,
[7/15] Compiling Transcoding VideoDecoder.swift
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoDecoder.swift:42:17: warning: capture of 'self' with non-sendable type 'VideoDecoder?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
8 | // MARK: - VideoDecoder
9 |
10 | public final class VideoDecoder {
| `- note: class 'VideoDecoder' does not conform to the 'Sendable' protocol
11 | // MARK: Lifecycle
12 |
:
40 | continuations[id] = continuation
41 | continuation.onTermination = { [weak self] _ in
42 | self?.continuations[id] = nil
| `- warning: capture of 'self' with non-sendable type 'VideoDecoder?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
43 | }
44 | }
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoDecoder.swift:75:31: warning: capture of 'self' with non-sendable type 'VideoDecoder?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
8 | // MARK: - VideoDecoder
9 |
10 | public final class VideoDecoder {
| `- note: class 'VideoDecoder' does not conform to the 'Sendable' protocol
11 | // MARK: Lifecycle
12 |
:
73 | flags: [._1xRealTimePlayback]
74 | ) { [weak self] status, _, imageBuffer, presentationTimeStamp, presentationDuration in
75 | guard let self else { return }
| `- warning: capture of 'self' with non-sendable type 'VideoDecoder?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
76 | outputQueue.sync {
77 | do {
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoDecoder.swift:84:50: warning: capture of 'sampleBuffer' with non-sendable type 'CMSampleBuffer' in a `@Sendable` closure; this is an error in the Swift 6 language mode
82 | duration: presentationDuration,
83 | presentationTimeStamp: presentationTimeStamp,
84 | decodeTimeStamp: sampleBuffer.decodeTimeStamp
| `- warning: capture of 'sampleBuffer' with non-sendable type 'CMSampleBuffer' in a `@Sendable` closure; this is an error in the Swift 6 language mode
85 | )
86 | let sampleBuffer = try CMSampleBuffer(
CoreMedia.CMSampleBuffer:2:14: note: class 'CMSampleBuffer' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | public class CMSampleBuffer : _CFObject {
| `- note: class 'CMSampleBuffer' does not conform to the 'Sendable' protocol
3 | }
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoDecoder.swift:84:50: warning: capture of 'sampleBuffer' with non-sendable type 'CMSampleBuffer' in an isolated closure; this is an error in the Swift 6 language mode
82 | duration: presentationDuration,
83 | presentationTimeStamp: presentationTimeStamp,
84 | decodeTimeStamp: sampleBuffer.decodeTimeStamp
| `- warning: capture of 'sampleBuffer' with non-sendable type 'CMSampleBuffer' in an isolated closure; this is an error in the Swift 6 language mode
85 | )
86 | let sampleBuffer = try CMSampleBuffer(
CoreMedia.CMSampleBuffer:2:14: note: class 'CMSampleBuffer' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | public class CMSampleBuffer : _CFObject {
| `- note: class 'CMSampleBuffer' does not conform to the 'Sendable' protocol
3 | }
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoDecoder.swift:92:46: warning: sending 'sampleBuffer' risks causing data races; this is an error in the Swift 6 language mode
90 | )
91 | for continuation in self.continuations.values {
92 | continuation.yield(sampleBuffer)
| |- warning: sending 'sampleBuffer' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'sampleBuffer' is passed as a 'sending' parameter; Uses in callee may race with later task-isolated uses
93 | }
94 | } catch {
[8/15] Compiling Transcoding VideoDecoder+Config.swift
[9/15] Compiling Transcoding VideoEncoder+Config.swift
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder+Config.swift:147:27: warning: static property 'liveCapture' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
2 |
3 | public extension VideoEncoder {
4 | struct Config {
| `- note: consider making struct 'Config' conform to the 'Sendable' protocol
5 | // MARK: Lifecycle
6 |
:
145 | /// Live capture and live broadcast scenarios.
146 | /// Also set expectedFrameRate to real-time frame rate if possible
147 | public static let liveCapture = Config(
| |- warning: static property 'liveCapture' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'liveCapture' 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
148 | realTime: true
149 | )
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder+Config.swift:152:27: warning: static property 'activeTranscoding' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
2 |
3 | public extension VideoEncoder {
4 | struct Config {
| `- note: consider making struct 'Config' conform to the 'Sendable' protocol
5 | // MARK: Lifecycle
6 |
:
150 |
151 | /// Offline transcode initiated by a user, who is waiting for the results
152 | public static let activeTranscoding = Config(
| |- warning: static property 'activeTranscoding' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'activeTranscoding' 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
153 | realTime: false,
154 | maximizePowerEfficiency: false
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder+Config.swift:158:27: warning: static property 'backgroundTranscoding' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
2 |
3 | public extension VideoEncoder {
4 | struct Config {
| `- note: consider making struct 'Config' conform to the 'Sendable' protocol
5 | // MARK: Lifecycle
6 |
:
156 |
157 | /// Offline transcode in the background (when the user is not aware)
158 | public static let backgroundTranscoding = Config(
| |- warning: static property 'backgroundTranscoding' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'backgroundTranscoding' 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
159 | realTime: false,
160 | maximizePowerEfficiency: false
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder+Config.swift:165:27: warning: static property 'ultraLowLatency' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
2 |
3 | public extension VideoEncoder {
4 | struct Config {
| `- note: consider making struct 'Config' conform to the 'Sendable' protocol
5 | // MARK: Lifecycle
6 |
:
163 | /// Ultra-low-latency conferencing and cloud gaming (cases where every millisecond counts).
164 | /// Also set expectedFrameRate to real-time frame rate if possible
165 | public static let ultraLowLatency = Config(
| |- warning: static property 'ultraLowLatency' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'ultraLowLatency' 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
166 | prioritizeEncodingSpeedOverQuality: true,
167 | realTime: true,
[10/15] Compiling Transcoding VTDecompressionSession+Extensions.swift
[11/15] Compiling Transcoding H264NALU.swift
[12/15] Compiling Transcoding Data+Extensions.swift
[13/15] Compiling Transcoding VTCompressionSession+Extensions.swift
[14/15] Emitting module Transcoding
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder+Config.swift:147:27: warning: static property 'liveCapture' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
2 |
3 | public extension VideoEncoder {
4 | struct Config {
| `- note: consider making struct 'Config' conform to the 'Sendable' protocol
5 | // MARK: Lifecycle
6 |
:
145 | /// Live capture and live broadcast scenarios.
146 | /// Also set expectedFrameRate to real-time frame rate if possible
147 | public static let liveCapture = Config(
| |- warning: static property 'liveCapture' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'liveCapture' 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
148 | realTime: true
149 | )
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder+Config.swift:152:27: warning: static property 'activeTranscoding' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
2 |
3 | public extension VideoEncoder {
4 | struct Config {
| `- note: consider making struct 'Config' conform to the 'Sendable' protocol
5 | // MARK: Lifecycle
6 |
:
150 |
151 | /// Offline transcode initiated by a user, who is waiting for the results
152 | public static let activeTranscoding = Config(
| |- warning: static property 'activeTranscoding' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'activeTranscoding' 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
153 | realTime: false,
154 | maximizePowerEfficiency: false
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder+Config.swift:158:27: warning: static property 'backgroundTranscoding' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
2 |
3 | public extension VideoEncoder {
4 | struct Config {
| `- note: consider making struct 'Config' conform to the 'Sendable' protocol
5 | // MARK: Lifecycle
6 |
:
156 |
157 | /// Offline transcode in the background (when the user is not aware)
158 | public static let backgroundTranscoding = Config(
| |- warning: static property 'backgroundTranscoding' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'backgroundTranscoding' 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
159 | realTime: false,
160 | maximizePowerEfficiency: false
/Users/admin/builder/spi-builder-workspace/Sources/Transcoding/VideoEncoder+Config.swift:165:27: warning: static property 'ultraLowLatency' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
2 |
3 | public extension VideoEncoder {
4 | struct Config {
| `- note: consider making struct 'Config' conform to the 'Sendable' protocol
5 | // MARK: Lifecycle
6 |
:
163 | /// Ultra-low-latency conferencing and cloud gaming (cases where every millisecond counts).
164 | /// Also set expectedFrameRate to real-time frame rate if possible
165 | public static let ultraLowLatency = Config(
| |- warning: static property 'ultraLowLatency' is not concurrency-safe because non-'Sendable' type 'VideoEncoder.Config' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'ultraLowLatency' 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
166 | prioritizeEncodingSpeedOverQuality: true,
167 | realTime: true,
[15/15] Compiling Transcoding VideoTranscoderError.swift
Build complete! (18.40s)
Build complete.
{
"dependencies" : [
],
"manifest_display_name" : "Transcoding",
"name" : "Transcoding",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
{
"name" : "ios",
"version" : "15.0"
},
{
"name" : "macos",
"version" : "13.0"
},
{
"name" : "visionos",
"version" : "1.0"
},
{
"name" : "tvos",
"version" : "15.0"
}
],
"products" : [
{
"name" : "Transcoding",
"targets" : [
"Transcoding"
],
"type" : {
"library" : [
"automatic"
]
}
}
],
"targets" : [
{
"c99name" : "TranscodingTests",
"module_type" : "SwiftTarget",
"name" : "TranscodingTests",
"path" : "Tests/TranscodingTests",
"sources" : [
"TranscodingTests.swift"
],
"target_dependencies" : [
"Transcoding"
],
"type" : "test"
},
{
"c99name" : "Transcoding",
"module_type" : "SwiftTarget",
"name" : "Transcoding",
"path" : "Sources/Transcoding",
"product_memberships" : [
"Transcoding"
],
"sources" : [
"Extensions/Data+Extensions.swift",
"Extensions/VTCompressionSession+Extensions.swift",
"Extensions/VTDecompressionSession+Extensions.swift",
"NALUs/H264NALU.swift",
"NALUs/HEVCNALU.swift",
"VideoDecoder+Config.swift",
"VideoDecoder.swift",
"VideoDecoderAnnexBAdaptor.swift",
"VideoEncoder+Config.swift",
"VideoEncoder.swift",
"VideoEncoderAnnexBAdaptor.swift",
"VideoTranscoderError.swift"
],
"type" : "library"
}
],
"tools_version" : "5.9"
}
Done.