The Swift Package Index logo.Swift Package Index

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

Build Information

Failed to build BroadcastWriter, reference main (ef52e6), with Swift 6.0 for macOS (SPM) on 28 Nov 2024 00:06:52 UTC.

Build Command

env DEVELOPER_DIR=/Applications/Xcode-16.1.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete -Xswiftc -enable-upcoming-feature -Xswiftc StrictConcurrency -Xswiftc -enable-upcoming-feature -Xswiftc DisableOutwardActorInference -Xswiftc -enable-upcoming-feature -Xswiftc GlobalActorIsolatedTypesUsability -Xswiftc -enable-upcoming-feature -Xswiftc InferSendableFromCaptures

Build Log

========================================
RunAll
========================================
Builder version: 4.58.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/romiroma/BroadcastWriter.git
Reference: main
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/romiroma/BroadcastWriter
 * branch            main       -> FETCH_HEAD
 * [new branch]      main       -> origin/main
HEAD is now at ef52e6f Update README.md
Cloned https://github.com/romiroma/BroadcastWriter.git
Revision (git rev-parse @):
ef52e6f09f12c60bcca8544934799a5863947a7f
SUCCESS checkout https://github.com/romiroma/BroadcastWriter.git at main
========================================
ResolveProductDependencies
========================================
Resolving dependencies ...
{
  "identity": ".resolve-product-dependencies",
  "name": "resolve-dependencies",
  "url": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies",
  "version": "unspecified",
  "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies",
  "dependencies": [
    {
      "identity": "broadcastwriter",
      "name": "BroadcastWriter",
      "url": "https://github.com/romiroma/BroadcastWriter.git",
      "version": "unspecified",
      "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/BroadcastWriter",
      "dependencies": [
      ]
    }
  ]
}
Fetching https://github.com/romiroma/BroadcastWriter.git
[1/63] Fetching broadcastwriter
Fetched https://github.com/romiroma/BroadcastWriter.git from cache (0.70s)
Creating working copy for https://github.com/romiroma/BroadcastWriter.git
Working copy of https://github.com/romiroma/BroadcastWriter.git resolved at main (ef52e6f)
warning: '.resolve-product-dependencies': dependency 'broadcastwriter' is not used by any target
Found 0 product dependencies
========================================
Build
========================================
Selected platform:         macosSpm
Swift version:             6.0
Building package at path:  $PWD
https://github.com/romiroma/BroadcastWriter.git
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-16.1.0.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete -Xswiftc -enable-upcoming-feature -Xswiftc StrictConcurrency -Xswiftc -enable-upcoming-feature -Xswiftc DisableOutwardActorInference -Xswiftc -enable-upcoming-feature -Xswiftc GlobalActorIsolatedTypesUsability -Xswiftc -enable-upcoming-feature -Xswiftc InferSendableFromCaptures
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version--7754E27361AE5C74.txt
[3/7] Compiling BroadcastWriter Int+NSNumber.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)
[4/7] Compiling BroadcastWriter CGFloat+NSNumber.swift
[5/7] Compiling BroadcastWriter AVAssetWriter.Status+stringDescription.swift
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/AVAssetWriter.Status+stringDescription.swift:4:1: warning: extension declares a conformance of imported type 'Status' to imported protocol 'CustomStringConvertible'; this will not behave correctly if the owners of 'AVFoundation' introduce this conformance in the future
 2 | import AVFoundation
 3 |
 4 | extension AVAssetWriter.Status: CustomStringConvertible {
   | |- warning: extension declares a conformance of imported type 'Status' to imported protocol 'CustomStringConvertible'; this will not behave correctly if the owners of 'AVFoundation' introduce this conformance in the future
   | `- note: add '@retroactive' to silence this warning
 5 |
 6 |     public var description: String {
[6/7] Emitting module BroadcastWriter
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/AVAssetWriter.Status+stringDescription.swift:4:1: warning: extension declares a conformance of imported type 'Status' to imported protocol 'CustomStringConvertible'; this will not behave correctly if the owners of 'AVFoundation' introduce this conformance in the future
 2 | import AVFoundation
 3 |
 4 | extension AVAssetWriter.Status: CustomStringConvertible {
   | |- warning: extension declares a conformance of imported type 'Status' to imported protocol 'CustomStringConvertible'; this will not behave correctly if the owners of 'AVFoundation' introduce this conformance in the future
   | `- note: add '@retroactive' to silence this warning
 5 |
 6 |     public var description: String {
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:58:26: error: 'AVAudioSession' is unavailable in macOS
 56 |
 57 |     private lazy var microphoneInput: AVAssetWriterInput = {
 58 |         let sampleRate = AVAudioSession.sharedInstance().sampleRate
    |                          `- error: 'AVAudioSession' is unavailable in macOS
 59 |
 60 |         var audioSettings: [String: Any] = [
AVFAudio.AVAudioSession:2:12: note: 'AVAudioSession' has been explicitly marked unavailable here
 1 | @available(macOS, unavailable)
 2 | open class AVAudioSession : NSObject, @unchecked Sendable {
   |            `- note: 'AVAudioSession' has been explicitly marked unavailable here
 3 |     @available(macOS, unavailable)
 4 |     open class func sharedInstance() -> AVAudioSession
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:58:41: error: 'sharedInstance()' is unavailable in macOS
 56 |
 57 |     private lazy var microphoneInput: AVAssetWriterInput = {
 58 |         let sampleRate = AVAudioSession.sharedInstance().sampleRate
    |                                         `- error: 'sharedInstance()' is unavailable in macOS
 59 |
 60 |         var audioSettings: [String: Any] = [
AVFAudio.AVAudioSession:4:21: note: 'sharedInstance()' has been explicitly marked unavailable here
 2 | open class AVAudioSession : NSObject, @unchecked Sendable {
 3 |     @available(macOS, unavailable)
 4 |     open class func sharedInstance() -> AVAudioSession
   |                     `- note: 'sharedInstance()' has been explicitly marked unavailable here
 5 |     @available(macOS, unavailable)
 6 |     open var availableCategories: [AVAudioSession.Category] { get }
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:58:58: error: 'sampleRate' is unavailable in macOS
 56 |
 57 |     private lazy var microphoneInput: AVAssetWriterInput = {
 58 |         let sampleRate = AVAudioSession.sharedInstance().sampleRate
    |                                                          `- error: 'sampleRate' is unavailable in macOS
 59 |
 60 |         var audioSettings: [String: Any] = [
AVFAudio.AVAudioSession:55:14: note: 'sampleRate' has been explicitly marked unavailable here
53 |     open func setOutputDataSource(_ dataSource: AVAudioSessionDataSourceDescription?) throws
54 |     @available(macOS, unavailable)
55 |     open var sampleRate: Double { get }
   |              `- note: 'sampleRate' has been explicitly marked unavailable here
56 |     @available(macOS, unavailable)
57 |     open var inputNumberOfChannels: Int { get }
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:120:32: error: 'RPSampleBufferType' is only available in macOS 11.0 or newer
  8 | }
  9 |
 10 | public final class BroadcastWriter {
    |                    `- note: add @available attribute to enclosing class
 11 |
 12 |     private var assetWriterSessionStarted: Bool = false
    :
116 |     }
117 |
118 |     public func processSampleBuffer(
    |                 `- note: add @available attribute to enclosing instance method
119 |         _ sampleBuffer: CMSampleBuffer,
120 |         with sampleBufferType: RPSampleBufferType
    |                                `- error: 'RPSampleBufferType' is only available in macOS 11.0 or newer
121 |     ) throws -> Bool {
122 |
[7/7] Compiling BroadcastWriter BroadcastWriter.swift
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:58:26: error: 'AVAudioSession' is unavailable in macOS
 56 |
 57 |     private lazy var microphoneInput: AVAssetWriterInput = {
 58 |         let sampleRate = AVAudioSession.sharedInstance().sampleRate
    |                          `- error: 'AVAudioSession' is unavailable in macOS
 59 |
 60 |         var audioSettings: [String: Any] = [
AVFAudio.AVAudioSession:2:12: note: 'AVAudioSession' has been explicitly marked unavailable here
 1 | @available(macOS, unavailable)
 2 | open class AVAudioSession : NSObject, @unchecked Sendable {
   |            `- note: 'AVAudioSession' has been explicitly marked unavailable here
 3 |     @available(macOS, unavailable)
 4 |     open class func sharedInstance() -> AVAudioSession
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:58:41: error: 'sharedInstance()' is unavailable in macOS
 56 |
 57 |     private lazy var microphoneInput: AVAssetWriterInput = {
 58 |         let sampleRate = AVAudioSession.sharedInstance().sampleRate
    |                                         `- error: 'sharedInstance()' is unavailable in macOS
 59 |
 60 |         var audioSettings: [String: Any] = [
AVFAudio.AVAudioSession:4:21: note: 'sharedInstance()' has been explicitly marked unavailable here
 2 | open class AVAudioSession : NSObject, @unchecked Sendable {
 3 |     @available(macOS, unavailable)
 4 |     open class func sharedInstance() -> AVAudioSession
   |                     `- note: 'sharedInstance()' has been explicitly marked unavailable here
 5 |     @available(macOS, unavailable)
 6 |     open var availableCategories: [AVAudioSession.Category] { get }
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:58:58: error: 'sampleRate' is unavailable in macOS
 56 |
 57 |     private lazy var microphoneInput: AVAssetWriterInput = {
 58 |         let sampleRate = AVAudioSession.sharedInstance().sampleRate
    |                                                          `- error: 'sampleRate' is unavailable in macOS
 59 |
 60 |         var audioSettings: [String: Any] = [
AVFAudio.AVAudioSession:55:14: note: 'sampleRate' has been explicitly marked unavailable here
53 |     open func setOutputDataSource(_ dataSource: AVAudioSessionDataSourceDescription?) throws
54 |     @available(macOS, unavailable)
55 |     open var sampleRate: Double { get }
   |              `- note: 'sampleRate' has been explicitly marked unavailable here
56 |     @available(macOS, unavailable)
57 |     open var inputNumberOfChannels: Int { get }
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:120:32: error: 'RPSampleBufferType' is only available in macOS 11.0 or newer
  8 | }
  9 |
 10 | public final class BroadcastWriter {
    |                    `- note: add @available attribute to enclosing class
 11 |
 12 |     private var assetWriterSessionStarted: Bool = false
    :
116 |     }
117 |
118 |     public func processSampleBuffer(
    |                 `- note: add @available attribute to enclosing instance method
119 |         _ sampleBuffer: CMSampleBuffer,
120 |         with sampleBufferType: RPSampleBufferType
    |                                `- error: 'RPSampleBufferType' is only available in macOS 11.0 or newer
121 |     ) throws -> Bool {
122 |
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:40:9: error: 'AVAudioSession' is unavailable in macOS
 38 |
 39 |     private var audioSampleRate: Double {
 40 |         AVAudioSession.sharedInstance().sampleRate
    |         `- error: 'AVAudioSession' is unavailable in macOS
 41 |     }
 42 |     private lazy var audioInput: AVAssetWriterInput = {
AVFAudio.AVAudioSession:2:12: note: 'AVAudioSession' has been explicitly marked unavailable here
 1 | @available(macOS, unavailable)
 2 | open class AVAudioSession : NSObject, @unchecked Sendable {
   |            `- note: 'AVAudioSession' has been explicitly marked unavailable here
 3 |     @available(macOS, unavailable)
 4 |     open class func sharedInstance() -> AVAudioSession
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:40:24: error: 'sharedInstance()' is unavailable in macOS
 38 |
 39 |     private var audioSampleRate: Double {
 40 |         AVAudioSession.sharedInstance().sampleRate
    |                        `- error: 'sharedInstance()' is unavailable in macOS
 41 |     }
 42 |     private lazy var audioInput: AVAssetWriterInput = {
AVFAudio.AVAudioSession:4:21: note: 'sharedInstance()' has been explicitly marked unavailable here
 2 | open class AVAudioSession : NSObject, @unchecked Sendable {
 3 |     @available(macOS, unavailable)
 4 |     open class func sharedInstance() -> AVAudioSession
   |                     `- note: 'sharedInstance()' has been explicitly marked unavailable here
 5 |     @available(macOS, unavailable)
 6 |     open var availableCategories: [AVAudioSession.Category] { get }
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:40:41: error: 'sampleRate' is unavailable in macOS
 38 |
 39 |     private var audioSampleRate: Double {
 40 |         AVAudioSession.sharedInstance().sampleRate
    |                                         `- error: 'sampleRate' is unavailable in macOS
 41 |     }
 42 |     private lazy var audioInput: AVAssetWriterInput = {
AVFAudio.AVAudioSession:55:14: note: 'sampleRate' has been explicitly marked unavailable here
53 |     open func setOutputDataSource(_ dataSource: AVAudioSessionDataSourceDescription?) throws
54 |     @available(macOS, unavailable)
55 |     open var sampleRate: Double { get }
   |              `- note: 'sampleRate' has been explicitly marked unavailable here
56 |     @available(macOS, unavailable)
57 |     open var inputNumberOfChannels: Int { get }
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:123:28: error: 'isValid' is only available in macOS 10.15 or newer
  8 | }
  9 |
 10 | public final class BroadcastWriter {
    |                    `- note: add @available attribute to enclosing class
 11 |
 12 |     private var assetWriterSessionStarted: Bool = false
    :
116 |     }
117 |
118 |     public func processSampleBuffer(
    |                 `- note: add @available attribute to enclosing instance method
119 |         _ sampleBuffer: CMSampleBuffer,
120 |         with sampleBufferType: RPSampleBufferType
121 |     ) throws -> Bool {
122 |
123 |         guard sampleBuffer.isValid,
    |                            |- error: 'isValid' is only available in macOS 10.15 or newer
    |                            `- note: add 'if #available' version check
124 |               CMSampleBufferDataIsReady(sampleBuffer) else {
125 |             debugPrint(
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:126:54: error: 'isValid' is only available in macOS 10.15 or newer
  8 | }
  9 |
 10 | public final class BroadcastWriter {
    |                    `- note: add @available attribute to enclosing class
 11 |
 12 |     private var assetWriterSessionStarted: Bool = false
    :
116 |     }
117 |
118 |     public func processSampleBuffer(
    |                 `- note: add @available attribute to enclosing instance method
119 |         _ sampleBuffer: CMSampleBuffer,
120 |         with sampleBufferType: RPSampleBufferType
    :
124 |               CMSampleBufferDataIsReady(sampleBuffer) else {
125 |             debugPrint(
126 |                 "sampleBuffer.isValid", sampleBuffer.isValid,
    |                                                      |- error: 'isValid' is only available in macOS 10.15 or newer
    |                                                      `- note: add 'if #available' version check
127 |                 "CMSampleBufferDataIsReady(sampleBuffer)", CMSampleBufferDataIsReady(sampleBuffer)
128 |             )
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:198:34: warning: capture of 'self' with non-sendable type 'BroadcastWriter?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
  8 | }
  9 |
 10 | public final class BroadcastWriter {
    |                    `- note: class 'BroadcastWriter' does not conform to the 'Sendable' protocol
 11 |
 12 |     private var assetWriterSessionStarted: Bool = false
    :
196 |                 }
197 |
198 |                 guard let self = self else {
    |                                  `- warning: capture of 'self' with non-sendable type 'BroadcastWriter?' in a `@Sendable` closure; this is an error in the Swift 6 language mode
199 |                     error = Error.selfDeallocated
200 |                     return
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:199:21: warning: mutation of captured var 'error' in concurrently-executing code; this is an error in the Swift 6 language mode
197 |
198 |                 guard let self = self else {
199 |                     error = Error.selfDeallocated
    |                     `- warning: mutation of captured var 'error' in concurrently-executing code; this is an error in the Swift 6 language mode
200 |                     return
201 |                 }
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:204:21: warning: mutation of captured var 'error' in concurrently-executing code; this is an error in the Swift 6 language mode
202 |
203 |                 if let e = self.assetWriter.error {
204 |                     error = e
    |                     `- warning: mutation of captured var 'error' in concurrently-executing code; this is an error in the Swift 6 language mode
205 |                     return
206 |                 }
/Users/admin/builder/spi-builder-workspace/Sources/BroadcastWriter/BroadcastWriter.swift:210:21: warning: mutation of captured var 'error' in concurrently-executing code; this is an error in the Swift 6 language mode
208 |                 let status = self.assetWriter.status
209 |                 guard status == .completed else {
210 |                     error = Error.wrongAssetWriterStatus(status)
    |                     `- warning: mutation of captured var 'error' in concurrently-executing code; this is an error in the Swift 6 language mode
211 |                     return
212 |                 }
BUILD FAILURE 6.0 macosSpm