Build Information
Failed to build VideoIO with Swift 6.0 for macOS (SPM).
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/MetalPetal/VideoIO.git
Reference: master
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/MetalPetal/VideoIO
* branch master -> FETCH_HEAD
* [new branch] master -> origin/master
HEAD is now at 1623b3d [Camera] Add method to switch to a specific video device
Cloned https://github.com/MetalPetal/VideoIO.git
Revision (git rev-parse @):
1623b3d597d8ae987979ce8ac7b1ce0d085d2855
SUCCESS checkout https://github.com/MetalPetal/VideoIO.git at master
========================================
Build
========================================
Selected platform: macosSpm
Swift version: 6.0
Building package at path: $workDir
https://github.com/MetalPetal/VideoIO.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/19] Compiling VideoIO VideoComposition.swift
[4/19] Compiling VideoIO UnfairLock.swift
[5/19] Compiling VideoIO PlayerVideoOutput.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:17:27: warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'PlayerVideoOutput.Configuration' may have shared mutable state; this is an error in the Swift 6 language mode
12 | public class PlayerVideoOutput: NSObject {
13 |
14 | public struct Configuration {
| `- note: consider making struct 'Configuration' conform to the 'Sendable' protocol
15 | public var sourcePixelBufferAttributes: [String: Any]?
16 | public var preferredFramesPerSecond: Int = 30
17 | public static let `default` = Configuration()
| |- warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'PlayerVideoOutput.Configuration' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'default' 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
18 | public init() {
19 |
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:63:30: error: 'CADisplayLink' is only available in macOS 14.0 or newer
61 | }
62 |
63 | private var displayLink: CADisplayLink?
| `- error: 'CADisplayLink' is only available in macOS 14.0 or newer
64 |
65 | private var playerItemStatusObservation: NSKeyValueObservation?
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:208:52: error: 'CADisplayLink' is only available in macOS 14.0 or newer
201 | }
202 |
203 | private class DisplayLinkTarget {
| `- note: add @available attribute to enclosing class
204 | private let handler: () -> Void
205 | init(_ handler: @escaping () -> Void) {
206 | self.handler = handler
207 | }
208 | @objc func handleDisplayLinkUpdate(sender: CADisplayLink) {
| | `- error: 'CADisplayLink' is only available in macOS 14.0 or newer
| `- note: add @available attribute to enclosing instance method
209 | self.handler()
210 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:100:36: warning: capture of 'self' with non-sendable type 'PlayerVideoOutput?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
10 |
11 | @available(macOS, unavailable)
12 | public class PlayerVideoOutput: NSObject {
| `- note: class 'PlayerVideoOutput' does not conform to the 'Sendable' protocol
13 |
14 | public struct Configuration {
:
98 | private func attachCurrentPlayer() {
99 | self.playerItemObservation = self.player?.observe(\.currentItem, options: [.initial, .new], changeHandler: { [weak self] (player, change) in
100 | guard let strongSelf = self, strongSelf.player == player else {
| `- warning: capture of 'self' with non-sendable type 'PlayerVideoOutput?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
101 | return
102 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:121:36: warning: capture of 'self' with non-sendable type 'PlayerVideoOutput?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
10 |
11 | @available(macOS, unavailable)
12 | public class PlayerVideoOutput: NSObject {
| `- note: class 'PlayerVideoOutput' does not conform to the 'Sendable' protocol
13 |
14 | public struct Configuration {
:
119 | self.playerItem = playerItem
120 | self.playerItemStatusObservation = self.playerItem?.observe(\.status, options: [.initial,.new], changeHandler: { [weak self] item, change in
121 | guard let strongSelf = self else {
| `- warning: capture of 'self' with non-sendable type 'PlayerVideoOutput?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
122 | return
123 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:161:31: error: 'CADisplayLink' is only available in macOS 14.0 or newer
154 | }
155 |
156 | private func setupDisplayLink() {
| `- note: add @available attribute to enclosing instance method
157 | self.displayLink?.invalidate()
158 | self.displayLink = nil
159 |
160 | if self.playerItemOutput != nil {
161 | let displayLink = CADisplayLink(target: DisplayLinkTarget({ [weak self] in
| |- error: 'CADisplayLink' is only available in macOS 14.0 or newer
| `- note: add 'if #available' version check
162 | self?.handleUpdate()
163 | }), selector: #selector(DisplayLinkTarget.handleDisplayLinkUpdate(sender:)))
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:171:45: warning: main actor-isolated property 'rate' can not be referenced from a non-isolated context; this is an error in the Swift 6 language mode
168 | }
169 |
170 | private func handleUpdate() {
| `- note: add '@MainActor' to make instance method 'handleUpdate()' part of global actor 'MainActor'
171 | if let player = self.player, player.rate != 0 {
| `- warning: main actor-isolated property 'rate' can not be referenced from a non-isolated context; this is an error in the Swift 6 language mode
172 | self.forceUpdate = true
173 | }
AVFoundation.AVPlayer:2:25: note: property declared here
1 | extension AVPlayer {
2 | @MainActor open var rate: Float { get set }
| `- note: property declared here
3 | @available(macOS 13.0, *)
4 | open var defaultRate: Float { get set }
[6/19] Compiling VideoIO SampleBufferUtilities.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:17:27: warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'PlayerVideoOutput.Configuration' may have shared mutable state; this is an error in the Swift 6 language mode
12 | public class PlayerVideoOutput: NSObject {
13 |
14 | public struct Configuration {
| `- note: consider making struct 'Configuration' conform to the 'Sendable' protocol
15 | public var sourcePixelBufferAttributes: [String: Any]?
16 | public var preferredFramesPerSecond: Int = 30
17 | public static let `default` = Configuration()
| |- warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'PlayerVideoOutput.Configuration' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'default' 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
18 | public init() {
19 |
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:63:30: error: 'CADisplayLink' is only available in macOS 14.0 or newer
61 | }
62 |
63 | private var displayLink: CADisplayLink?
| `- error: 'CADisplayLink' is only available in macOS 14.0 or newer
64 |
65 | private var playerItemStatusObservation: NSKeyValueObservation?
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:208:52: error: 'CADisplayLink' is only available in macOS 14.0 or newer
201 | }
202 |
203 | private class DisplayLinkTarget {
| `- note: add @available attribute to enclosing class
204 | private let handler: () -> Void
205 | init(_ handler: @escaping () -> Void) {
206 | self.handler = handler
207 | }
208 | @objc func handleDisplayLinkUpdate(sender: CADisplayLink) {
| | `- error: 'CADisplayLink' is only available in macOS 14.0 or newer
| `- note: add @available attribute to enclosing instance method
209 | self.handler()
210 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:100:36: warning: capture of 'self' with non-sendable type 'PlayerVideoOutput?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
10 |
11 | @available(macOS, unavailable)
12 | public class PlayerVideoOutput: NSObject {
| `- note: class 'PlayerVideoOutput' does not conform to the 'Sendable' protocol
13 |
14 | public struct Configuration {
:
98 | private func attachCurrentPlayer() {
99 | self.playerItemObservation = self.player?.observe(\.currentItem, options: [.initial, .new], changeHandler: { [weak self] (player, change) in
100 | guard let strongSelf = self, strongSelf.player == player else {
| `- warning: capture of 'self' with non-sendable type 'PlayerVideoOutput?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
101 | return
102 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:121:36: warning: capture of 'self' with non-sendable type 'PlayerVideoOutput?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
10 |
11 | @available(macOS, unavailable)
12 | public class PlayerVideoOutput: NSObject {
| `- note: class 'PlayerVideoOutput' does not conform to the 'Sendable' protocol
13 |
14 | public struct Configuration {
:
119 | self.playerItem = playerItem
120 | self.playerItemStatusObservation = self.playerItem?.observe(\.status, options: [.initial,.new], changeHandler: { [weak self] item, change in
121 | guard let strongSelf = self else {
| `- warning: capture of 'self' with non-sendable type 'PlayerVideoOutput?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
122 | return
123 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:161:31: error: 'CADisplayLink' is only available in macOS 14.0 or newer
154 | }
155 |
156 | private func setupDisplayLink() {
| `- note: add @available attribute to enclosing instance method
157 | self.displayLink?.invalidate()
158 | self.displayLink = nil
159 |
160 | if self.playerItemOutput != nil {
161 | let displayLink = CADisplayLink(target: DisplayLinkTarget({ [weak self] in
| |- error: 'CADisplayLink' is only available in macOS 14.0 or newer
| `- note: add 'if #available' version check
162 | self?.handleUpdate()
163 | }), selector: #selector(DisplayLinkTarget.handleDisplayLinkUpdate(sender:)))
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:171:45: warning: main actor-isolated property 'rate' can not be referenced from a non-isolated context; this is an error in the Swift 6 language mode
168 | }
169 |
170 | private func handleUpdate() {
| `- note: add '@MainActor' to make instance method 'handleUpdate()' part of global actor 'MainActor'
171 | if let player = self.player, player.rate != 0 {
| `- warning: main actor-isolated property 'rate' can not be referenced from a non-isolated context; this is an error in the Swift 6 language mode
172 | self.forceUpdate = true
173 | }
AVFoundation.AVPlayer:2:25: note: property declared here
1 | extension AVPlayer {
2 | @MainActor open var rate: Float { get set }
| `- note: property declared here
3 | @available(macOS 13.0, *)
4 | open var defaultRate: Float { get set }
error: emit-module command failed with exit code 1 (use -v to see invocation)
[7/20] Compiling VideoIO DeviceOrientationTracker.swift
[8/20] Compiling VideoIO MovieFileType.swift
[9/20] Compiling VideoIO MovieMerger.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:177:19: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
175 | self.queue.async {
176 | //no `errorLock` is required here because the `error` can only be assigned on `self.queue`
177 | guard self.stopped == false, self.error == nil else {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
178 | return
179 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:184:41: warning: capture of 'sampleBuffers' with non-sendable type '[CMSampleBuffer]' in a `@Sendable` closure; this is an error in the Swift 6 language mode
182 | do {
183 | var videoInputs: [AVAssetWriterInput] = []
184 | for sampleBuffer in sampleBuffers {
| `- warning: capture of 'sampleBuffers' with non-sendable type '[CMSampleBuffer]' in a `@Sendable` closure; this is an error in the Swift 6 language mode
185 | guard let formatDescription = CMSampleBufferGetFormatDescription(sampleBuffer) else {
186 | throw RecorderError.cannotSetupVideoInputs
Swift.Array:1:23: note: generic struct 'Array' does not conform to the 'Sendable' protocol
1 | @frozen public struct Array<Element> : _DestructorSafeContainer {
| `- note: generic struct 'Array' does not conform to the 'Sendable' protocol
2 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:217:87: warning: implicit capture of 'self' requires that 'MultitrackMovieRecorder' conforms to `Sendable`; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
215 | }
216 |
217 | guard self.videoInputs.count == self.configuration.numberOfVideoTracks && self.audioInputs.count == self.configuration.numberOfAudioTracks else {
| `- warning: implicit capture of 'self' requires that 'MultitrackMovieRecorder' conforms to `Sendable`; this is an error in the Swift 6 language mode
218 | return
219 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:233:21: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
231 | self.lastVideoSampleTime = presentationTime
232 | DispatchQueue.main.async {
233 | self.sampleWritingSessionStartedHandler?(presentationTime)
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
234 | }
235 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:246:33: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
244 | self._duration = duration
245 | DispatchQueue.main.async {
246 | self.durationChangedHandler?(duration)
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
247 | }
248 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:287:19: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
285 | self.queue.async {
286 | //no `errorLock` is required here because the `error` can only be assigned on `self.queue`
287 | guard self.stopped == false, self.error == nil else {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
288 | return
289 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:294:41: warning: capture of 'sampleBuffers' with non-sendable type '[CMSampleBuffer]' in a `@Sendable` closure; this is an error in the Swift 6 language mode
292 | do {
293 | var audioInputs: [AVAssetWriterInput] = []
294 | for sampleBuffer in sampleBuffers {
| `- warning: capture of 'sampleBuffers' with non-sendable type '[CMSampleBuffer]' in a `@Sendable` closure; this is an error in the Swift 6 language mode
295 | guard let formatDescription = CMSampleBufferGetFormatDescription(sampleBuffer) else {
296 | throw RecorderError.cannotSetupAudioInputs
Swift.Array:1:23: note: generic struct 'Array' does not conform to the 'Sendable' protocol
1 | @frozen public struct Array<Element> : _DestructorSafeContainer {
| `- note: generic struct 'Array' does not conform to the 'Sendable' protocol
2 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:338:87: warning: implicit capture of 'self' requires that 'MultitrackMovieRecorder' conforms to `Sendable`; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
336 | }
337 |
338 | guard self.videoInputs.count == self.configuration.numberOfVideoTracks && self.audioInputs.count == self.configuration.numberOfAudioTracks else {
| `- warning: implicit capture of 'self' requires that 'MultitrackMovieRecorder' conforms to `Sendable`; this is an error in the Swift 6 language mode
339 | return
340 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:356:16: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
354 | public func cancelRecording(completion: @escaping () -> Void) {
355 | self.queue.async {
356 | if self.stopped {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
357 | DispatchQueue.main.async {
358 | completion()
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:358:21: warning: capture of 'completion' with non-sendable type '() -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
356 | if self.stopped {
357 | DispatchQueue.main.async {
358 | completion()
| |- warning: capture of 'completion' with non-sendable type '() -> 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'
359 | }
360 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:358:21: warning: capture of 'completion' with non-sendable type '() -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
356 | if self.stopped {
357 | DispatchQueue.main.async {
358 | completion()
| |- warning: capture of 'completion' with non-sendable type '() -> 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'
359 | }
360 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:370:17: warning: capture of 'completion' with non-sendable type '() -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
368 | try? fileManager.removeItem(at: self.url)
369 | DispatchQueue.main.async {
370 | completion()
| |- warning: capture of 'completion' with non-sendable type '() -> 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'
371 | }
372 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:381:16: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
379 | public func stopRecording(completion: @escaping (Error?) -> Void) {
380 | self.queue.async {
381 | if self.stopped {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
382 | DispatchQueue.main.async {
383 | completion(RecorderError.alreadyStopped)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:383:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
381 | if self.stopped {
382 | DispatchQueue.main.async {
383 | completion(RecorderError.alreadyStopped)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
384 | }
385 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:383:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
381 | if self.stopped {
382 | DispatchQueue.main.async {
383 | completion(RecorderError.alreadyStopped)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
384 | }
385 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:392:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
390 | if let error = self.error {
391 | DispatchQueue.main.async {
392 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
393 | }
394 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:401:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
399 | } catch {
400 | DispatchQueue.main.async {
401 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
402 | }
403 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:408:36: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in an isolated closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
406 | if self.assetWriter.status == .writing {
407 | self.assetWriter.finishWriting {
408 | if let error = self.assetWriter.error {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in an isolated closure; this is an error in the Swift 6 language mode
409 | DispatchQueue.main.async {
410 | completion(error)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:410:29: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in an isolated closure; this is an error in the Swift 6 language mode
408 | if let error = self.assetWriter.error {
409 | DispatchQueue.main.async {
410 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in an isolated closure; this is an error in the Swift 6 language mode
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
411 | }
412 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:410:29: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
408 | if let error = self.assetWriter.error {
409 | DispatchQueue.main.async {
410 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
411 | }
412 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:414:29: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
412 | } else {
413 | DispatchQueue.main.async {
414 | completion(nil)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
415 | }
416 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:420:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
418 | } else if let error = self.assetWriter.error {
419 | DispatchQueue.main.async {
420 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
421 | }
422 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:424:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
422 | } else {
423 | DispatchQueue.main.async {
424 | completion(RecorderError.unexpectedAssetWriterStatus)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
425 | }
426 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:246:33: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
237 | if self.assetWriter.status == .writing {
238 | if self.videoInputs.map(\.isReadyForMoreMediaData).reduce(true, { $0 && $1 }) {
239 | for (index, sampleBuffer) in sampleBuffers.enumerated() {
| `- note: access can happen concurrently
240 | if self.videoInputs[index].append(sampleBuffer) {
241 | self.lastVideoSampleTime = presentationTime
:
244 | self._duration = duration
245 | DispatchQueue.main.async {
246 | self.durationChangedHandler?(duration)
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
247 | }
248 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:233:21: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
231 | self.lastVideoSampleTime = presentationTime
232 | DispatchQueue.main.async {
233 | self.sampleWritingSessionStartedHandler?(presentationTime)
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
234 | }
235 | }
236 |
237 | if self.assetWriter.status == .writing {
| `- note: access can happen concurrently
238 | if self.videoInputs.map(\.isReadyForMoreMediaData).reduce(true, { $0 && $1 }) {
239 | for (index, sampleBuffer) in sampleBuffers.enumerated() {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:410:29: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
408 | if let error = self.assetWriter.error {
409 | DispatchQueue.main.async {
410 | completion(error)
| |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
411 | }
412 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:414:29: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
412 | } else {
413 | DispatchQueue.main.async {
414 | completion(nil)
| |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
415 | }
416 | }
[10/20] Compiling VideoIO MultitrackMovieRecorder.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:177:19: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
175 | self.queue.async {
176 | //no `errorLock` is required here because the `error` can only be assigned on `self.queue`
177 | guard self.stopped == false, self.error == nil else {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
178 | return
179 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:184:41: warning: capture of 'sampleBuffers' with non-sendable type '[CMSampleBuffer]' in a `@Sendable` closure; this is an error in the Swift 6 language mode
182 | do {
183 | var videoInputs: [AVAssetWriterInput] = []
184 | for sampleBuffer in sampleBuffers {
| `- warning: capture of 'sampleBuffers' with non-sendable type '[CMSampleBuffer]' in a `@Sendable` closure; this is an error in the Swift 6 language mode
185 | guard let formatDescription = CMSampleBufferGetFormatDescription(sampleBuffer) else {
186 | throw RecorderError.cannotSetupVideoInputs
Swift.Array:1:23: note: generic struct 'Array' does not conform to the 'Sendable' protocol
1 | @frozen public struct Array<Element> : _DestructorSafeContainer {
| `- note: generic struct 'Array' does not conform to the 'Sendable' protocol
2 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:217:87: warning: implicit capture of 'self' requires that 'MultitrackMovieRecorder' conforms to `Sendable`; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
215 | }
216 |
217 | guard self.videoInputs.count == self.configuration.numberOfVideoTracks && self.audioInputs.count == self.configuration.numberOfAudioTracks else {
| `- warning: implicit capture of 'self' requires that 'MultitrackMovieRecorder' conforms to `Sendable`; this is an error in the Swift 6 language mode
218 | return
219 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:233:21: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
231 | self.lastVideoSampleTime = presentationTime
232 | DispatchQueue.main.async {
233 | self.sampleWritingSessionStartedHandler?(presentationTime)
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
234 | }
235 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:246:33: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
244 | self._duration = duration
245 | DispatchQueue.main.async {
246 | self.durationChangedHandler?(duration)
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
247 | }
248 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:287:19: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
285 | self.queue.async {
286 | //no `errorLock` is required here because the `error` can only be assigned on `self.queue`
287 | guard self.stopped == false, self.error == nil else {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
288 | return
289 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:294:41: warning: capture of 'sampleBuffers' with non-sendable type '[CMSampleBuffer]' in a `@Sendable` closure; this is an error in the Swift 6 language mode
292 | do {
293 | var audioInputs: [AVAssetWriterInput] = []
294 | for sampleBuffer in sampleBuffers {
| `- warning: capture of 'sampleBuffers' with non-sendable type '[CMSampleBuffer]' in a `@Sendable` closure; this is an error in the Swift 6 language mode
295 | guard let formatDescription = CMSampleBufferGetFormatDescription(sampleBuffer) else {
296 | throw RecorderError.cannotSetupAudioInputs
Swift.Array:1:23: note: generic struct 'Array' does not conform to the 'Sendable' protocol
1 | @frozen public struct Array<Element> : _DestructorSafeContainer {
| `- note: generic struct 'Array' does not conform to the 'Sendable' protocol
2 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:338:87: warning: implicit capture of 'self' requires that 'MultitrackMovieRecorder' conforms to `Sendable`; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
336 | }
337 |
338 | guard self.videoInputs.count == self.configuration.numberOfVideoTracks && self.audioInputs.count == self.configuration.numberOfAudioTracks else {
| `- warning: implicit capture of 'self' requires that 'MultitrackMovieRecorder' conforms to `Sendable`; this is an error in the Swift 6 language mode
339 | return
340 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:356:16: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
354 | public func cancelRecording(completion: @escaping () -> Void) {
355 | self.queue.async {
356 | if self.stopped {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
357 | DispatchQueue.main.async {
358 | completion()
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:358:21: warning: capture of 'completion' with non-sendable type '() -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
356 | if self.stopped {
357 | DispatchQueue.main.async {
358 | completion()
| |- warning: capture of 'completion' with non-sendable type '() -> 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'
359 | }
360 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:358:21: warning: capture of 'completion' with non-sendable type '() -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
356 | if self.stopped {
357 | DispatchQueue.main.async {
358 | completion()
| |- warning: capture of 'completion' with non-sendable type '() -> 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'
359 | }
360 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:370:17: warning: capture of 'completion' with non-sendable type '() -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
368 | try? fileManager.removeItem(at: self.url)
369 | DispatchQueue.main.async {
370 | completion()
| |- warning: capture of 'completion' with non-sendable type '() -> 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'
371 | }
372 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:381:16: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
379 | public func stopRecording(completion: @escaping (Error?) -> Void) {
380 | self.queue.async {
381 | if self.stopped {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
382 | DispatchQueue.main.async {
383 | completion(RecorderError.alreadyStopped)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:383:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
381 | if self.stopped {
382 | DispatchQueue.main.async {
383 | completion(RecorderError.alreadyStopped)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
384 | }
385 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:383:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
381 | if self.stopped {
382 | DispatchQueue.main.async {
383 | completion(RecorderError.alreadyStopped)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
384 | }
385 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:392:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
390 | if let error = self.error {
391 | DispatchQueue.main.async {
392 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
393 | }
394 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:401:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
399 | } catch {
400 | DispatchQueue.main.async {
401 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
402 | }
403 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:408:36: warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in an isolated closure; this is an error in the Swift 6 language mode
2 | import CoreImage
3 |
4 | public final class MultitrackMovieRecorder {
| `- note: class 'MultitrackMovieRecorder' does not conform to the 'Sendable' protocol
5 |
6 | public enum RecorderError: LocalizedError {
:
406 | if self.assetWriter.status == .writing {
407 | self.assetWriter.finishWriting {
408 | if let error = self.assetWriter.error {
| `- warning: capture of 'self' with non-sendable type 'MultitrackMovieRecorder' in an isolated closure; this is an error in the Swift 6 language mode
409 | DispatchQueue.main.async {
410 | completion(error)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:410:29: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in an isolated closure; this is an error in the Swift 6 language mode
408 | if let error = self.assetWriter.error {
409 | DispatchQueue.main.async {
410 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in an isolated closure; this is an error in the Swift 6 language mode
| `- note: a function type must be marked '@Sendable' to conform to 'Sendable'
411 | }
412 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:410:29: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
408 | if let error = self.assetWriter.error {
409 | DispatchQueue.main.async {
410 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
411 | }
412 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:414:29: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
412 | } else {
413 | DispatchQueue.main.async {
414 | completion(nil)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
415 | }
416 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:420:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
418 | } else if let error = self.assetWriter.error {
419 | DispatchQueue.main.async {
420 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
421 | }
422 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:424:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
422 | } else {
423 | DispatchQueue.main.async {
424 | completion(RecorderError.unexpectedAssetWriterStatus)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
425 | }
426 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:246:33: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
237 | if self.assetWriter.status == .writing {
238 | if self.videoInputs.map(\.isReadyForMoreMediaData).reduce(true, { $0 && $1 }) {
239 | for (index, sampleBuffer) in sampleBuffers.enumerated() {
| `- note: access can happen concurrently
240 | if self.videoInputs[index].append(sampleBuffer) {
241 | self.lastVideoSampleTime = presentationTime
:
244 | self._duration = duration
245 | DispatchQueue.main.async {
246 | self.durationChangedHandler?(duration)
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
247 | }
248 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:233:21: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
231 | self.lastVideoSampleTime = presentationTime
232 | DispatchQueue.main.async {
233 | self.sampleWritingSessionStartedHandler?(presentationTime)
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
234 | }
235 | }
236 |
237 | if self.assetWriter.status == .writing {
| `- note: access can happen concurrently
238 | if self.videoInputs.map(\.isReadyForMoreMediaData).reduce(true, { $0 && $1 }) {
239 | for (index, sampleBuffer) in sampleBuffers.enumerated() {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:410:29: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
408 | if let error = self.assetWriter.error {
409 | DispatchQueue.main.async {
410 | completion(error)
| |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
411 | }
412 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/MultitrackMovieRecorder.swift:414:29: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
412 | } else {
413 | DispatchQueue.main.async {
414 | completion(nil)
| |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
415 | }
416 | }
[11/20] Compiling VideoIO Camera+AudioQueueCapture.swift
[12/20] Compiling VideoIO Camera+FocusExposure.swift
[13/20] Compiling VideoIO AVAsset.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:216:18: warning: class 'ExportProgress' must restate inherited '@unchecked Sendable' conformance
214 |
215 |
216 | public class ExportProgress: Progress {
| `- warning: class 'ExportProgress' must restate inherited '@unchecked Sendable' conformance
217 | public let videoEncodingProgress: Progress?
218 | public let audioEncodingProgress: Progress?
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:265:17: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
263 | if self.status != .idle || self.cancelled {
264 | DispatchQueue.main.async {
265 | completion(Error.invalidStatus)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
266 | }
267 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:287:17: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
285 | } catch {
286 | DispatchQueue.main.async {
287 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
288 | }
289 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:304:37: warning: capture of 'sessionForVideoEncoder' with non-sendable type 'AssetExportSession?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
302 | var sessionForVideoEncoder: AssetExportSession? = self
303 | videoInput.requestMediaDataWhenReady(on: self.queue) { [unowned videoInput] in
304 | guard let session = sessionForVideoEncoder else { return }
| `- warning: capture of 'sessionForVideoEncoder' with non-sendable type 'AssetExportSession?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
305 | if !session.encode(from: videoOutput, to: videoInput) {
306 | videoCompleted = true
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:305:42: warning: capture of 'videoOutput' with non-sendable type 'AVAssetReaderOutput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
303 | videoInput.requestMediaDataWhenReady(on: self.queue) { [unowned videoInput] in
304 | guard let session = sessionForVideoEncoder else { return }
305 | if !session.encode(from: videoOutput, to: videoInput) {
| `- warning: capture of 'videoOutput' with non-sendable type 'AVAssetReaderOutput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
306 | videoCompleted = true
307 | sessionForVideoEncoder = nil
AVFoundation.AVAssetReaderOutput:2:12: note: class 'AVAssetReaderOutput' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | open class AVAssetReaderOutput : NSObject {
| `- note: class 'AVAssetReaderOutput' does not conform to the 'Sendable' protocol
3 | open var mediaType: AVMediaType { get }
4 | @available(macOS 10.8, *)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:9:1: warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'AVFoundation'
7 |
8 | import Foundation
9 | import AVFoundation
| `- warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'AVFoundation'
10 |
11 | public class AssetExportSession {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:305:59: warning: capture of 'videoInput' with non-sendable type 'AVAssetWriterInput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
303 | videoInput.requestMediaDataWhenReady(on: self.queue) { [unowned videoInput] in
304 | guard let session = sessionForVideoEncoder else { return }
305 | if !session.encode(from: videoOutput, to: videoInput) {
| `- warning: capture of 'videoInput' with non-sendable type 'AVAssetWriterInput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
306 | videoCompleted = true
307 | sessionForVideoEncoder = nil
AVFoundation.AVAssetWriterInput:2:12: note: class 'AVAssetWriterInput' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | open class AVAssetWriterInput : NSObject {
| `- note: class 'AVAssetWriterInput' does not conform to the 'Sendable' protocol
3 | @available(*, unavailable)
4 | public convenience init()
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:309:59: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
307 | sessionForVideoEncoder = nil
308 | if audioCompleted {
309 | session.finish(completionHandler: completion)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
310 | }
311 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:304:37: warning: reference to captured var 'sessionForVideoEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
302 | var sessionForVideoEncoder: AssetExportSession? = self
303 | videoInput.requestMediaDataWhenReady(on: self.queue) { [unowned videoInput] in
304 | guard let session = sessionForVideoEncoder else { return }
| `- warning: reference to captured var 'sessionForVideoEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
305 | if !session.encode(from: videoOutput, to: videoInput) {
306 | videoCompleted = true
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:306:21: warning: mutation of captured var 'videoCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
304 | guard let session = sessionForVideoEncoder else { return }
305 | if !session.encode(from: videoOutput, to: videoInput) {
306 | videoCompleted = true
| `- warning: mutation of captured var 'videoCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
307 | sessionForVideoEncoder = nil
308 | if audioCompleted {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:307:21: warning: mutation of captured var 'sessionForVideoEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
305 | if !session.encode(from: videoOutput, to: videoInput) {
306 | videoCompleted = true
307 | sessionForVideoEncoder = nil
| `- warning: mutation of captured var 'sessionForVideoEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
308 | if audioCompleted {
309 | session.finish(completionHandler: completion)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:308:24: warning: reference to captured var 'audioCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
306 | videoCompleted = true
307 | sessionForVideoEncoder = nil
308 | if audioCompleted {
| `- warning: reference to captured var 'audioCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
309 | session.finish(completionHandler: completion)
310 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:320:37: warning: capture of 'sessionForAudioEncoder' with non-sendable type 'AssetExportSession?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
318 | var sessionForAudioEncoder: AssetExportSession? = self
319 | audioInput.requestMediaDataWhenReady(on: self.queue) { [unowned audioInput] in
320 | guard let session = sessionForAudioEncoder else { return }
| `- warning: capture of 'sessionForAudioEncoder' with non-sendable type 'AssetExportSession?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
321 | if !session.encode(from: audioOutput, to: audioInput) {
322 | audioCompleted = true
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:321:42: warning: capture of 'audioOutput' with non-sendable type 'AVAssetReaderAudioMixOutput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
319 | audioInput.requestMediaDataWhenReady(on: self.queue) { [unowned audioInput] in
320 | guard let session = sessionForAudioEncoder else { return }
321 | if !session.encode(from: audioOutput, to: audioInput) {
| `- warning: capture of 'audioOutput' with non-sendable type 'AVAssetReaderAudioMixOutput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
322 | audioCompleted = true
323 | sessionForAudioEncoder = nil
AVFoundation.AVAssetReaderAudioMixOutput:2:12: note: class 'AVAssetReaderAudioMixOutput' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | open class AVAssetReaderAudioMixOutput : AVAssetReaderOutput {
| `- note: class 'AVAssetReaderAudioMixOutput' does not conform to the 'Sendable' protocol
3 | @available(*, unavailable)
4 | public convenience init()
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:321:59: warning: capture of 'audioInput' with non-sendable type 'AVAssetWriterInput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
319 | audioInput.requestMediaDataWhenReady(on: self.queue) { [unowned audioInput] in
320 | guard let session = sessionForAudioEncoder else { return }
321 | if !session.encode(from: audioOutput, to: audioInput) {
| `- warning: capture of 'audioInput' with non-sendable type 'AVAssetWriterInput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
322 | audioCompleted = true
323 | sessionForAudioEncoder = nil
AVFoundation.AVAssetWriterInput:2:12: note: class 'AVAssetWriterInput' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | open class AVAssetWriterInput : NSObject {
| `- note: class 'AVAssetWriterInput' does not conform to the 'Sendable' protocol
3 | @available(*, unavailable)
4 | public convenience init()
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:325:59: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
323 | sessionForAudioEncoder = nil
324 | if videoCompleted {
325 | session.finish(completionHandler: completion)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
326 | }
327 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:320:37: warning: reference to captured var 'sessionForAudioEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
318 | var sessionForAudioEncoder: AssetExportSession? = self
319 | audioInput.requestMediaDataWhenReady(on: self.queue) { [unowned audioInput] in
320 | guard let session = sessionForAudioEncoder else { return }
| `- warning: reference to captured var 'sessionForAudioEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
321 | if !session.encode(from: audioOutput, to: audioInput) {
322 | audioCompleted = true
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:322:21: warning: mutation of captured var 'audioCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
320 | guard let session = sessionForAudioEncoder else { return }
321 | if !session.encode(from: audioOutput, to: audioInput) {
322 | audioCompleted = true
| `- warning: mutation of captured var 'audioCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
323 | sessionForAudioEncoder = nil
324 | if videoCompleted {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:323:21: warning: mutation of captured var 'sessionForAudioEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
321 | if !session.encode(from: audioOutput, to: audioInput) {
322 | audioCompleted = true
323 | sessionForAudioEncoder = nil
| `- warning: mutation of captured var 'sessionForAudioEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
324 | if videoCompleted {
325 | session.finish(completionHandler: completion)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:324:24: warning: reference to captured var 'videoCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
322 | audioCompleted = true
323 | sessionForAudioEncoder = nil
324 | if videoCompleted {
| `- warning: reference to captured var 'videoCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
325 | session.finish(completionHandler: completion)
326 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:336:31: warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
334 | private func dispatchProgressCallback(with updater: @escaping (ExportProgress) -> Void) {
335 | DispatchQueue.main.async {
336 | if let progress = self.progress {
| `- warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
337 | updater(progress)
338 | self.progressHandler?(progress)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:337:17: warning: capture of 'updater' with non-sendable type '(AssetExportSession.ExportProgress) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
335 | DispatchQueue.main.async {
336 | if let progress = self.progress {
337 | updater(progress)
| |- warning: capture of 'updater' with non-sendable type '(AssetExportSession.ExportProgress) -> 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'
338 | self.progressHandler?(progress)
339 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:345:13: warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
343 | private func dispatchCallback(with error: Swift.Error?, _ completionHandler: @escaping (Swift.Error?) -> Void) {
344 | DispatchQueue.main.async {
345 | self.progressHandler = nil
| `- warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
346 | self.status = .completed
347 | completionHandler(error)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:347:13: warning: capture of 'completionHandler' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
345 | self.progressHandler = nil
346 | self.status = .completed
347 | completionHandler(error)
| |- warning: capture of 'completionHandler' with non-sendable type '((any Error)?) -> 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'
348 | }
349 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:381:24: warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
379 | self.writer.finishWriting {
380 | self.queue.async {
381 | if self.writer.status == .failed {
| `- warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
382 | try? FileManager().removeItem(at: self.outputURL)
383 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:387:68: warning: capture of 'completionHandler' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
385 | self.dispatchProgressCallback { $0.updateFinishWritingProgress(fractionCompleted: 1) }
386 | }
387 | self.dispatchCallback(with: self.writer.error, completionHandler)
| |- warning: capture of 'completionHandler' with non-sendable type '((any Error)?) -> 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'
388 | }
389 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:421:16: warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
419 | self.cancelled = true
420 | self.queue.async {
421 | if self.reader.status == .reading {
| `- warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
422 | self.reader.cancelReading()
423 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:336:31: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
334 | private func dispatchProgressCallback(with updater: @escaping (ExportProgress) -> Void) {
335 | DispatchQueue.main.async {
336 | if let progress = self.progress {
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
337 | updater(progress)
338 | self.progressHandler?(progress)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:337:17: warning: sending 'updater' risks causing data races; this is an error in the Swift 6 language mode
335 | DispatchQueue.main.async {
336 | if let progress = self.progress {
337 | updater(progress)
| |- warning: sending 'updater' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'updater' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
338 | self.progressHandler?(progress)
339 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:265:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
263 | if self.status != .idle || self.cancelled {
264 | DispatchQueue.main.async {
265 | completion(Error.invalidStatus)
| |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
266 | }
267 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:287:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
285 | } catch {
286 | DispatchQueue.main.async {
287 | completion(error)
| |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
288 | }
289 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:345:13: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
343 | private func dispatchCallback(with error: Swift.Error?, _ completionHandler: @escaping (Swift.Error?) -> Void) {
344 | DispatchQueue.main.async {
345 | self.progressHandler = nil
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
346 | self.status = .completed
347 | completionHandler(error)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:347:13: warning: sending 'completionHandler' risks causing data races; this is an error in the Swift 6 language mode
345 | self.progressHandler = nil
346 | self.status = .completed
347 | completionHandler(error)
| |- warning: sending 'completionHandler' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completionHandler' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
348 | }
349 | }
[14/20] Compiling VideoIO AssetExportSession.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:216:18: warning: class 'ExportProgress' must restate inherited '@unchecked Sendable' conformance
214 |
215 |
216 | public class ExportProgress: Progress {
| `- warning: class 'ExportProgress' must restate inherited '@unchecked Sendable' conformance
217 | public let videoEncodingProgress: Progress?
218 | public let audioEncodingProgress: Progress?
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:265:17: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
263 | if self.status != .idle || self.cancelled {
264 | DispatchQueue.main.async {
265 | completion(Error.invalidStatus)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
266 | }
267 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:287:17: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
285 | } catch {
286 | DispatchQueue.main.async {
287 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
288 | }
289 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:304:37: warning: capture of 'sessionForVideoEncoder' with non-sendable type 'AssetExportSession?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
302 | var sessionForVideoEncoder: AssetExportSession? = self
303 | videoInput.requestMediaDataWhenReady(on: self.queue) { [unowned videoInput] in
304 | guard let session = sessionForVideoEncoder else { return }
| `- warning: capture of 'sessionForVideoEncoder' with non-sendable type 'AssetExportSession?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
305 | if !session.encode(from: videoOutput, to: videoInput) {
306 | videoCompleted = true
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:305:42: warning: capture of 'videoOutput' with non-sendable type 'AVAssetReaderOutput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
303 | videoInput.requestMediaDataWhenReady(on: self.queue) { [unowned videoInput] in
304 | guard let session = sessionForVideoEncoder else { return }
305 | if !session.encode(from: videoOutput, to: videoInput) {
| `- warning: capture of 'videoOutput' with non-sendable type 'AVAssetReaderOutput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
306 | videoCompleted = true
307 | sessionForVideoEncoder = nil
AVFoundation.AVAssetReaderOutput:2:12: note: class 'AVAssetReaderOutput' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | open class AVAssetReaderOutput : NSObject {
| `- note: class 'AVAssetReaderOutput' does not conform to the 'Sendable' protocol
3 | open var mediaType: AVMediaType { get }
4 | @available(macOS 10.8, *)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:9:1: warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'AVFoundation'
7 |
8 | import Foundation
9 | import AVFoundation
| `- warning: add '@preconcurrency' to suppress 'Sendable'-related warnings from module 'AVFoundation'
10 |
11 | public class AssetExportSession {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:305:59: warning: capture of 'videoInput' with non-sendable type 'AVAssetWriterInput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
303 | videoInput.requestMediaDataWhenReady(on: self.queue) { [unowned videoInput] in
304 | guard let session = sessionForVideoEncoder else { return }
305 | if !session.encode(from: videoOutput, to: videoInput) {
| `- warning: capture of 'videoInput' with non-sendable type 'AVAssetWriterInput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
306 | videoCompleted = true
307 | sessionForVideoEncoder = nil
AVFoundation.AVAssetWriterInput:2:12: note: class 'AVAssetWriterInput' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | open class AVAssetWriterInput : NSObject {
| `- note: class 'AVAssetWriterInput' does not conform to the 'Sendable' protocol
3 | @available(*, unavailable)
4 | public convenience init()
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:309:59: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
307 | sessionForVideoEncoder = nil
308 | if audioCompleted {
309 | session.finish(completionHandler: completion)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
310 | }
311 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:304:37: warning: reference to captured var 'sessionForVideoEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
302 | var sessionForVideoEncoder: AssetExportSession? = self
303 | videoInput.requestMediaDataWhenReady(on: self.queue) { [unowned videoInput] in
304 | guard let session = sessionForVideoEncoder else { return }
| `- warning: reference to captured var 'sessionForVideoEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
305 | if !session.encode(from: videoOutput, to: videoInput) {
306 | videoCompleted = true
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:306:21: warning: mutation of captured var 'videoCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
304 | guard let session = sessionForVideoEncoder else { return }
305 | if !session.encode(from: videoOutput, to: videoInput) {
306 | videoCompleted = true
| `- warning: mutation of captured var 'videoCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
307 | sessionForVideoEncoder = nil
308 | if audioCompleted {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:307:21: warning: mutation of captured var 'sessionForVideoEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
305 | if !session.encode(from: videoOutput, to: videoInput) {
306 | videoCompleted = true
307 | sessionForVideoEncoder = nil
| `- warning: mutation of captured var 'sessionForVideoEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
308 | if audioCompleted {
309 | session.finish(completionHandler: completion)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:308:24: warning: reference to captured var 'audioCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
306 | videoCompleted = true
307 | sessionForVideoEncoder = nil
308 | if audioCompleted {
| `- warning: reference to captured var 'audioCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
309 | session.finish(completionHandler: completion)
310 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:320:37: warning: capture of 'sessionForAudioEncoder' with non-sendable type 'AssetExportSession?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
318 | var sessionForAudioEncoder: AssetExportSession? = self
319 | audioInput.requestMediaDataWhenReady(on: self.queue) { [unowned audioInput] in
320 | guard let session = sessionForAudioEncoder else { return }
| `- warning: capture of 'sessionForAudioEncoder' with non-sendable type 'AssetExportSession?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
321 | if !session.encode(from: audioOutput, to: audioInput) {
322 | audioCompleted = true
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:321:42: warning: capture of 'audioOutput' with non-sendable type 'AVAssetReaderAudioMixOutput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
319 | audioInput.requestMediaDataWhenReady(on: self.queue) { [unowned audioInput] in
320 | guard let session = sessionForAudioEncoder else { return }
321 | if !session.encode(from: audioOutput, to: audioInput) {
| `- warning: capture of 'audioOutput' with non-sendable type 'AVAssetReaderAudioMixOutput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
322 | audioCompleted = true
323 | sessionForAudioEncoder = nil
AVFoundation.AVAssetReaderAudioMixOutput:2:12: note: class 'AVAssetReaderAudioMixOutput' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | open class AVAssetReaderAudioMixOutput : AVAssetReaderOutput {
| `- note: class 'AVAssetReaderAudioMixOutput' does not conform to the 'Sendable' protocol
3 | @available(*, unavailable)
4 | public convenience init()
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:321:59: warning: capture of 'audioInput' with non-sendable type 'AVAssetWriterInput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
319 | audioInput.requestMediaDataWhenReady(on: self.queue) { [unowned audioInput] in
320 | guard let session = sessionForAudioEncoder else { return }
321 | if !session.encode(from: audioOutput, to: audioInput) {
| `- warning: capture of 'audioInput' with non-sendable type 'AVAssetWriterInput' in a `@Sendable` closure; this is an error in the Swift 6 language mode
322 | audioCompleted = true
323 | sessionForAudioEncoder = nil
AVFoundation.AVAssetWriterInput:2:12: note: class 'AVAssetWriterInput' does not conform to the 'Sendable' protocol
1 | @available(macOS 10.7, *)
2 | open class AVAssetWriterInput : NSObject {
| `- note: class 'AVAssetWriterInput' does not conform to the 'Sendable' protocol
3 | @available(*, unavailable)
4 | public convenience init()
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:325:59: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
323 | sessionForAudioEncoder = nil
324 | if videoCompleted {
325 | session.finish(completionHandler: completion)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
326 | }
327 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:320:37: warning: reference to captured var 'sessionForAudioEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
318 | var sessionForAudioEncoder: AssetExportSession? = self
319 | audioInput.requestMediaDataWhenReady(on: self.queue) { [unowned audioInput] in
320 | guard let session = sessionForAudioEncoder else { return }
| `- warning: reference to captured var 'sessionForAudioEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
321 | if !session.encode(from: audioOutput, to: audioInput) {
322 | audioCompleted = true
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:322:21: warning: mutation of captured var 'audioCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
320 | guard let session = sessionForAudioEncoder else { return }
321 | if !session.encode(from: audioOutput, to: audioInput) {
322 | audioCompleted = true
| `- warning: mutation of captured var 'audioCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
323 | sessionForAudioEncoder = nil
324 | if videoCompleted {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:323:21: warning: mutation of captured var 'sessionForAudioEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
321 | if !session.encode(from: audioOutput, to: audioInput) {
322 | audioCompleted = true
323 | sessionForAudioEncoder = nil
| `- warning: mutation of captured var 'sessionForAudioEncoder' in concurrently-executing code; this is an error in the Swift 6 language mode
324 | if videoCompleted {
325 | session.finish(completionHandler: completion)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:324:24: warning: reference to captured var 'videoCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
322 | audioCompleted = true
323 | sessionForAudioEncoder = nil
324 | if videoCompleted {
| `- warning: reference to captured var 'videoCompleted' in concurrently-executing code; this is an error in the Swift 6 language mode
325 | session.finish(completionHandler: completion)
326 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:336:31: warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
334 | private func dispatchProgressCallback(with updater: @escaping (ExportProgress) -> Void) {
335 | DispatchQueue.main.async {
336 | if let progress = self.progress {
| `- warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
337 | updater(progress)
338 | self.progressHandler?(progress)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:337:17: warning: capture of 'updater' with non-sendable type '(AssetExportSession.ExportProgress) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
335 | DispatchQueue.main.async {
336 | if let progress = self.progress {
337 | updater(progress)
| |- warning: capture of 'updater' with non-sendable type '(AssetExportSession.ExportProgress) -> 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'
338 | self.progressHandler?(progress)
339 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:345:13: warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
343 | private func dispatchCallback(with error: Swift.Error?, _ completionHandler: @escaping (Swift.Error?) -> Void) {
344 | DispatchQueue.main.async {
345 | self.progressHandler = nil
| `- warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
346 | self.status = .completed
347 | completionHandler(error)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:347:13: warning: capture of 'completionHandler' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
345 | self.progressHandler = nil
346 | self.status = .completed
347 | completionHandler(error)
| |- warning: capture of 'completionHandler' with non-sendable type '((any Error)?) -> 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'
348 | }
349 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:381:24: warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
379 | self.writer.finishWriting {
380 | self.queue.async {
381 | if self.writer.status == .failed {
| `- warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
382 | try? FileManager().removeItem(at: self.outputURL)
383 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:387:68: warning: capture of 'completionHandler' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
385 | self.dispatchProgressCallback { $0.updateFinishWritingProgress(fractionCompleted: 1) }
386 | }
387 | self.dispatchCallback(with: self.writer.error, completionHandler)
| |- warning: capture of 'completionHandler' with non-sendable type '((any Error)?) -> 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'
388 | }
389 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:421:16: warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
9 | import AVFoundation
10 |
11 | public class AssetExportSession {
| `- note: class 'AssetExportSession' does not conform to the 'Sendable' protocol
12 |
13 | public struct Configuration {
:
419 | self.cancelled = true
420 | self.queue.async {
421 | if self.reader.status == .reading {
| `- warning: capture of 'self' with non-sendable type 'AssetExportSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
422 | self.reader.cancelReading()
423 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:336:31: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
334 | private func dispatchProgressCallback(with updater: @escaping (ExportProgress) -> Void) {
335 | DispatchQueue.main.async {
336 | if let progress = self.progress {
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
337 | updater(progress)
338 | self.progressHandler?(progress)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:337:17: warning: sending 'updater' risks causing data races; this is an error in the Swift 6 language mode
335 | DispatchQueue.main.async {
336 | if let progress = self.progress {
337 | updater(progress)
| |- warning: sending 'updater' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'updater' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
338 | self.progressHandler?(progress)
339 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:265:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
263 | if self.status != .idle || self.cancelled {
264 | DispatchQueue.main.async {
265 | completion(Error.invalidStatus)
| |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
266 | }
267 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:287:17: warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
285 | } catch {
286 | DispatchQueue.main.async {
287 | completion(error)
| |- warning: sending 'completion' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completion' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
288 | }
289 | return
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:345:13: warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
343 | private func dispatchCallback(with error: Swift.Error?, _ completionHandler: @escaping (Swift.Error?) -> Void) {
344 | DispatchQueue.main.async {
345 | self.progressHandler = nil
| |- warning: sending 'self' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'self' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
346 | self.status = .completed
347 | completionHandler(error)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:347:13: warning: sending 'completionHandler' risks causing data races; this is an error in the Swift 6 language mode
345 | self.progressHandler = nil
346 | self.status = .completed
347 | completionHandler(error)
| |- warning: sending 'completionHandler' risks causing data races; this is an error in the Swift 6 language mode
| `- note: task-isolated 'completionHandler' is captured by a main actor-isolated closure. main actor-isolated uses in closure may race against later nonisolated uses
348 | }
349 | }
[15/20] Compiling VideoIO Camera+PhotoCapture.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/Camera.swift:30:27: warning: static property 'portraitFrontMirroredVideoOutput' is not concurrency-safe because non-'Sendable' type 'Camera.Configurator' may have shared mutable state; this is an error in the Swift 6 language mode
21 | }
22 |
23 | public struct Configurator {
| `- note: consider making struct 'Configurator' conform to the 'Sendable' protocol
24 | /// Called when video connection estiblished or video device changed. Called before `captureSession.commitConfiguration`.
25 | public var videoConnectionConfigurator: (Camera, AVCaptureConnection) -> Void
:
28 | public var videoDeviceConfigurator: (Camera, AVCaptureDevice) -> Void
29 |
30 | public static let portraitFrontMirroredVideoOutput: Configurator = {
| |- warning: static property 'portraitFrontMirroredVideoOutput' is not concurrency-safe because non-'Sendable' type 'Camera.Configurator' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'portraitFrontMirroredVideoOutput' 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
31 | var configurator = Configurator()
32 | configurator.videoConnectionConfigurator = { camera, connection in
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/Camera.swift:403:6: error: stored properties cannot be marked unavailable with '@available'
401 | internal var photoCaptureDelegateHandlers: [AnyObject] = []
402 |
403 | @available(macOS, unavailable)
| `- error: stored properties cannot be marked unavailable with '@available'
404 | internal var audioQueueCaptureSession: AudioQueueCaptureSession?
405 | }
[16/20] Compiling VideoIO Camera.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/Camera.swift:30:27: warning: static property 'portraitFrontMirroredVideoOutput' is not concurrency-safe because non-'Sendable' type 'Camera.Configurator' may have shared mutable state; this is an error in the Swift 6 language mode
21 | }
22 |
23 | public struct Configurator {
| `- note: consider making struct 'Configurator' conform to the 'Sendable' protocol
24 | /// Called when video connection estiblished or video device changed. Called before `captureSession.commitConfiguration`.
25 | public var videoConnectionConfigurator: (Camera, AVCaptureConnection) -> Void
:
28 | public var videoDeviceConfigurator: (Camera, AVCaptureDevice) -> Void
29 |
30 | public static let portraitFrontMirroredVideoOutput: Configurator = {
| |- warning: static property 'portraitFrontMirroredVideoOutput' is not concurrency-safe because non-'Sendable' type 'Camera.Configurator' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'portraitFrontMirroredVideoOutput' 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
31 | var configurator = Configurator()
32 | configurator.videoConnectionConfigurator = { camera, connection in
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/Camera.swift:403:6: error: stored properties cannot be marked unavailable with '@available'
401 | internal var photoCaptureDelegateHandlers: [AnyObject] = []
402 |
403 | @available(macOS, unavailable)
| `- error: stored properties cannot be marked unavailable with '@available'
404 | internal var audioQueueCaptureSession: AudioQueueCaptureSession?
405 | }
[17/20] Emitting module VideoIO
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AssetExportSession.swift:216:18: warning: class 'ExportProgress' must restate inherited '@unchecked Sendable' conformance
214 |
215 |
216 | public class ExportProgress: Progress {
| `- warning: class 'ExportProgress' must restate inherited '@unchecked Sendable' conformance
217 | public let videoEncodingProgress: Progress?
218 | public let audioEncodingProgress: Progress?
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:43:24: warning: static property 'tracker' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
41 |
42 | private struct Key {
43 | static var tracker = ""
| |- warning: static property 'tracker' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'tracker' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: annotate 'tracker' 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
44 | }
45 |
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:26:27: warning: static property 'fit' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
24 | self.init(rawValue: value)
25 | }
26 | public static let fit = ScalingMode(AVVideoScalingModeFit)
| |- warning: static property 'fit' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'fit' 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
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:27:27: warning: static property 'resize' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
25 | }
26 | public static let fit = ScalingMode(AVVideoScalingModeFit)
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
| |- warning: static property 'resize' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'resize' 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
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
29 | public static let resizeAspectFill = ScalingMode(AVVideoScalingModeResizeAspectFill)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:28:27: warning: static property 'resizeAspect' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
26 | public static let fit = ScalingMode(AVVideoScalingModeFit)
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
| |- warning: static property 'resizeAspect' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'resizeAspect' 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
29 | public static let resizeAspectFill = ScalingMode(AVVideoScalingModeResizeAspectFill)
30 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:29:27: warning: static property 'resizeAspectFill' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
29 | public static let resizeAspectFill = ScalingMode(AVVideoScalingModeResizeAspectFill)
| |- warning: static property 'resizeAspectFill' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'resizeAspectFill' 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
30 | }
31 |
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/Camera.swift:30:27: warning: static property 'portraitFrontMirroredVideoOutput' is not concurrency-safe because non-'Sendable' type 'Camera.Configurator' may have shared mutable state; this is an error in the Swift 6 language mode
21 | }
22 |
23 | public struct Configurator {
| `- note: consider making struct 'Configurator' conform to the 'Sendable' protocol
24 | /// Called when video connection estiblished or video device changed. Called before `captureSession.commitConfiguration`.
25 | public var videoConnectionConfigurator: (Camera, AVCaptureConnection) -> Void
:
28 | public var videoDeviceConfigurator: (Camera, AVCaptureDevice) -> Void
29 |
30 | public static let portraitFrontMirroredVideoOutput: Configurator = {
| |- warning: static property 'portraitFrontMirroredVideoOutput' is not concurrency-safe because non-'Sendable' type 'Camera.Configurator' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'portraitFrontMirroredVideoOutput' 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
31 | var configurator = Configurator()
32 | configurator.videoConnectionConfigurator = { camera, connection in
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/Camera.swift:403:6: error: stored properties cannot be marked unavailable with '@available'
401 | internal var photoCaptureDelegateHandlers: [AnyObject] = []
402 |
403 | @available(macOS, unavailable)
| `- error: stored properties cannot be marked unavailable with '@available'
404 | internal var audioQueueCaptureSession: AudioQueueCaptureSession?
405 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:17:27: warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'PlayerVideoOutput.Configuration' may have shared mutable state; this is an error in the Swift 6 language mode
12 | public class PlayerVideoOutput: NSObject {
13 |
14 | public struct Configuration {
| `- note: consider making struct 'Configuration' conform to the 'Sendable' protocol
15 | public var sourcePixelBufferAttributes: [String: Any]?
16 | public var preferredFramesPerSecond: Int = 30
17 | public static let `default` = Configuration()
| |- warning: static property 'default' is not concurrency-safe because non-'Sendable' type 'PlayerVideoOutput.Configuration' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'default' 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
18 | public init() {
19 |
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:63:30: error: 'CADisplayLink' is only available in macOS 14.0 or newer
61 | }
62 |
63 | private var displayLink: CADisplayLink?
| `- error: 'CADisplayLink' is only available in macOS 14.0 or newer
64 |
65 | private var playerItemStatusObservation: NSKeyValueObservation?
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/PlayerVideoOutput.swift:208:52: error: 'CADisplayLink' is only available in macOS 14.0 or newer
201 | }
202 |
203 | private class DisplayLinkTarget {
| `- note: add @available attribute to enclosing class
204 | private let handler: () -> Void
205 | init(_ handler: @escaping () -> Void) {
206 | self.handler = handler
207 | }
208 | @objc func handleDisplayLinkUpdate(sender: CADisplayLink) {
| | `- error: 'CADisplayLink' is only available in macOS 14.0 or newer
| `- note: add @available attribute to enclosing instance method
209 | self.handler()
210 | }
[18/20] Compiling VideoIO AudioQueueCaptureSession.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:43:24: warning: static property 'tracker' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
41 |
42 | private struct Key {
43 | static var tracker = ""
| |- warning: static property 'tracker' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'tracker' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: annotate 'tracker' 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
44 | }
45 |
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:130:17: warning: capture of 'self' with non-sendable type 'AudioQueueCaptureSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
15 |
16 | @available(macOS, unavailable)
17 | public class AudioQueueCaptureSession {
| `- note: class 'AudioQueueCaptureSession' does not conform to the 'Sendable' protocol
18 |
19 | public enum Error: Swift.Error {
:
128 | self.queue.async {
129 | do {
130 | self._stopAudioRecording()
| `- warning: capture of 'self' with non-sendable type 'AudioQueueCaptureSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
131 | try self._beginAudioRecording()
132 | self.delegateQueue.async {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:133:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
131 | try self._beginAudioRecording()
132 | self.delegateQueue.async {
133 | completion(nil)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
134 | }
135 | } catch {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:133:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
131 | try self._beginAudioRecording()
132 | self.delegateQueue.async {
133 | completion(nil)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
134 | }
135 | } catch {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:138:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
136 | self._stopAudioRecording()
137 | self.delegateQueue.async {
138 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
139 | }
140 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:196:37: warning: capture of 'session' with non-sendable type 'AudioQueueCaptureSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
15 |
16 | @available(macOS, unavailable)
17 | public class AudioQueueCaptureSession {
| `- note: class 'AudioQueueCaptureSession' does not conform to the 'Sendable' protocol
18 |
19 | public enum Error: Swift.Error {
:
194 |
195 | session.delegateQueue.async {
196 | session.delegate?.audioQueueCaptureSession(session, didOutputSampleBuffer: sampleBuffer)
| `- warning: capture of 'session' with non-sendable type 'AudioQueueCaptureSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
197 | }
198 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:196:112: warning: capture of 'sampleBuffer' with non-sendable type 'CMSampleBuffer' in a `@Sendable` closure; this is an error in the Swift 6 language mode
194 |
195 | session.delegateQueue.async {
196 | session.delegate?.audioQueueCaptureSession(session, didOutputSampleBuffer: sampleBuffer)
| `- warning: capture of 'sampleBuffer' with non-sendable type 'CMSampleBuffer' in a `@Sendable` closure; this is an error in the Swift 6 language mode
197 | }
198 | } else {
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/VideoIO/AudioVideoSettings.swift:26:27: warning: static property 'fit' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
24 | self.init(rawValue: value)
25 | }
26 | public static let fit = ScalingMode(AVVideoScalingModeFit)
| |- warning: static property 'fit' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'fit' 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
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:27:27: warning: static property 'resize' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
25 | }
26 | public static let fit = ScalingMode(AVVideoScalingModeFit)
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
| |- warning: static property 'resize' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'resize' 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
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
29 | public static let resizeAspectFill = ScalingMode(AVVideoScalingModeResizeAspectFill)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:28:27: warning: static property 'resizeAspect' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
26 | public static let fit = ScalingMode(AVVideoScalingModeFit)
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
| |- warning: static property 'resizeAspect' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'resizeAspect' 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
29 | public static let resizeAspectFill = ScalingMode(AVVideoScalingModeResizeAspectFill)
30 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:29:27: warning: static property 'resizeAspectFill' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
29 | public static let resizeAspectFill = ScalingMode(AVVideoScalingModeResizeAspectFill)
| |- warning: static property 'resizeAspectFill' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'resizeAspectFill' 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
30 | }
31 |
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:48:42: warning: forming 'UnsafeRawPointer' to an inout variable of type String exposes the internal representation rather than the string contents.
46 | static func attach(to: AnyObject, callback: @escaping () -> Void) {
47 | let tracker = LifetimeTracker(callback: callback)
48 | objc_setAssociatedObject(to, &Key.tracker, tracker, .OBJC_ASSOCIATION_RETAIN_NONATOMIC)
| `- warning: forming 'UnsafeRawPointer' to an inout variable of type String exposes the internal representation rather than the string contents.
49 | }
50 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:206:16: warning: forming 'UnsafeMutableRawPointer' to a variable of type 'Optional<AudioQueueCaptureSession.ClientInfo>'; this is likely incorrect because 'Optional<AudioQueueCaptureSession.ClientInfo>' may contain an object reference.
204 | }
205 | AudioQueueEnqueueBuffer(inAudioQueue, bufferRef, 0, nil)
206 | }, &self.clientInfo, nil, nil, 0, &audioQueue)
| `- warning: forming 'UnsafeMutableRawPointer' to a variable of type 'Optional<AudioQueueCaptureSession.ClientInfo>'; this is likely incorrect because 'Optional<AudioQueueCaptureSession.ClientInfo>' may contain an object reference.
207 |
208 | if status != 0 {
[19/20] Compiling VideoIO AudioVideoSettings.swift
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:43:24: warning: static property 'tracker' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
41 |
42 | private struct Key {
43 | static var tracker = ""
| |- warning: static property 'tracker' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'tracker' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: annotate 'tracker' 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
44 | }
45 |
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:130:17: warning: capture of 'self' with non-sendable type 'AudioQueueCaptureSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
15 |
16 | @available(macOS, unavailable)
17 | public class AudioQueueCaptureSession {
| `- note: class 'AudioQueueCaptureSession' does not conform to the 'Sendable' protocol
18 |
19 | public enum Error: Swift.Error {
:
128 | self.queue.async {
129 | do {
130 | self._stopAudioRecording()
| `- warning: capture of 'self' with non-sendable type 'AudioQueueCaptureSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
131 | try self._beginAudioRecording()
132 | self.delegateQueue.async {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:133:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
131 | try self._beginAudioRecording()
132 | self.delegateQueue.async {
133 | completion(nil)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
134 | }
135 | } catch {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:133:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
131 | try self._beginAudioRecording()
132 | self.delegateQueue.async {
133 | completion(nil)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
134 | }
135 | } catch {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:138:21: warning: capture of 'completion' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
136 | self._stopAudioRecording()
137 | self.delegateQueue.async {
138 | completion(error)
| |- warning: capture of 'completion' with non-sendable type '((any Error)?) -> 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'
139 | }
140 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:196:37: warning: capture of 'session' with non-sendable type 'AudioQueueCaptureSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
15 |
16 | @available(macOS, unavailable)
17 | public class AudioQueueCaptureSession {
| `- note: class 'AudioQueueCaptureSession' does not conform to the 'Sendable' protocol
18 |
19 | public enum Error: Swift.Error {
:
194 |
195 | session.delegateQueue.async {
196 | session.delegate?.audioQueueCaptureSession(session, didOutputSampleBuffer: sampleBuffer)
| `- warning: capture of 'session' with non-sendable type 'AudioQueueCaptureSession' in a `@Sendable` closure; this is an error in the Swift 6 language mode
197 | }
198 | } else {
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:196:112: warning: capture of 'sampleBuffer' with non-sendable type 'CMSampleBuffer' in a `@Sendable` closure; this is an error in the Swift 6 language mode
194 |
195 | session.delegateQueue.async {
196 | session.delegate?.audioQueueCaptureSession(session, didOutputSampleBuffer: sampleBuffer)
| `- warning: capture of 'sampleBuffer' with non-sendable type 'CMSampleBuffer' in a `@Sendable` closure; this is an error in the Swift 6 language mode
197 | }
198 | } else {
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/VideoIO/AudioVideoSettings.swift:26:27: warning: static property 'fit' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
24 | self.init(rawValue: value)
25 | }
26 | public static let fit = ScalingMode(AVVideoScalingModeFit)
| |- warning: static property 'fit' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'fit' 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
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:27:27: warning: static property 'resize' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
25 | }
26 | public static let fit = ScalingMode(AVVideoScalingModeFit)
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
| |- warning: static property 'resize' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'resize' 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
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
29 | public static let resizeAspectFill = ScalingMode(AVVideoScalingModeResizeAspectFill)
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:28:27: warning: static property 'resizeAspect' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
26 | public static let fit = ScalingMode(AVVideoScalingModeFit)
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
| |- warning: static property 'resizeAspect' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'resizeAspect' 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
29 | public static let resizeAspectFill = ScalingMode(AVVideoScalingModeResizeAspectFill)
30 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioVideoSettings.swift:29:27: warning: static property 'resizeAspectFill' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
16 | public struct VideoSettings: Codable {
17 |
18 | public struct ScalingMode: RawRepresentable {
| `- note: consider making struct 'ScalingMode' conform to the 'Sendable' protocol
19 | public let rawValue: String
20 | public init(rawValue: String) {
:
27 | public static let resize = ScalingMode(AVVideoScalingModeResize)
28 | public static let resizeAspect = ScalingMode(AVVideoScalingModeResizeAspect)
29 | public static let resizeAspectFill = ScalingMode(AVVideoScalingModeResizeAspectFill)
| |- warning: static property 'resizeAspectFill' is not concurrency-safe because non-'Sendable' type 'VideoSettings.ScalingMode' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'resizeAspectFill' 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
30 | }
31 |
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:48:42: warning: forming 'UnsafeRawPointer' to an inout variable of type String exposes the internal representation rather than the string contents.
46 | static func attach(to: AnyObject, callback: @escaping () -> Void) {
47 | let tracker = LifetimeTracker(callback: callback)
48 | objc_setAssociatedObject(to, &Key.tracker, tracker, .OBJC_ASSOCIATION_RETAIN_NONATOMIC)
| `- warning: forming 'UnsafeRawPointer' to an inout variable of type String exposes the internal representation rather than the string contents.
49 | }
50 | }
/Users/admin/builder/spi-builder-workspace/Sources/VideoIO/AudioQueueCaptureSession.swift:206:16: warning: forming 'UnsafeMutableRawPointer' to a variable of type 'Optional<AudioQueueCaptureSession.ClientInfo>'; this is likely incorrect because 'Optional<AudioQueueCaptureSession.ClientInfo>' may contain an object reference.
204 | }
205 | AudioQueueEnqueueBuffer(inAudioQueue, bufferRef, 0, nil)
206 | }, &self.clientInfo, nil, nil, 0, &audioQueue)
| `- warning: forming 'UnsafeMutableRawPointer' to a variable of type 'Optional<AudioQueueCaptureSession.ClientInfo>'; this is likely incorrect because 'Optional<AudioQueueCaptureSession.ClientInfo>' may contain an object reference.
207 |
208 | if status != 0 {
[20/20] Compiling VideoIO VideoOrientationUtilities.swift
BUILD FAILURE 6.0 macosSpm