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 Wyler, reference master (69c855), with Swift 6.0 for macOS (SPM) on 27 Nov 2024 23:21:24 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/toupper/Wyler.git
Reference: master
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/toupper/Wyler
 * branch            master     -> FETCH_HEAD
 * [new branch]      master     -> origin/master
HEAD is now at 69c8552 Merge pull request #8 from riderx/master
Cloned https://github.com/toupper/Wyler.git
Revision (git rev-parse @):
69c8552a0f2f280e2d93f4c8ac856f7567148996
SUCCESS checkout https://github.com/toupper/Wyler.git at master
========================================
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": "wyler",
      "name": "Wyler",
      "url": "https://github.com/toupper/Wyler.git",
      "version": "unspecified",
      "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/Wyler",
      "dependencies": [
      ]
    }
  ]
}
Fetching https://github.com/toupper/Wyler.git
[1/124] Fetching wyler
Fetched https://github.com/toupper/Wyler.git from cache (1.03s)
Creating working copy for https://github.com/toupper/Wyler.git
Working copy of https://github.com/toupper/Wyler.git resolved at master (69c8552)
warning: '.resolve-product-dependencies': dependency 'wyler' 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/toupper/Wyler.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/4] Emitting module Wyler
[4/4] Compiling Wyler ScreenRecorder.swift
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:51:21: error: incorrect argument label in call (have 'error:', expected 'handler:')
 49 |            self.appAudioWriterInput = createAndAddAudioInput()
 50 |         }
 51 |         startCapture(error: errorHandler)
    |                     `- error: incorrect argument label in call (have 'error:', expected 'handler:')
 52 |     } catch let err {
 53 |         errorHandler(err)
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:89:39: error: cannot find 'UIScreen' in scope
 87 |
 88 |   private func addVideoWriterInput(size: CGSize?) {
 89 |     let passingSize: CGSize = size ?? UIScreen.main.bounds.size
    |                                       `- error: cannot find 'UIScreen' in scope
 90 |
 91 |     let videoSettings: [String: Any] = [AVVideoCodecKey: AVVideoCodecType.h264,
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:121:14: error: 'startCapture(handler:completionHandler:)' is only available in macOS 11.0 or newer
 16 | }
 17 |
 18 | final public class ScreenRecorder {
    |                    `- note: add @available attribute to enclosing class
 19 |   private var videoOutputURL: URL?
 20 |   private var videoWriter: AVAssetWriter?
    :
115 |   }
116 |
117 |   private func startCapture(handler: @escaping (Error?) -> Void) {
    |                `- note: add @available attribute to enclosing instance method
118 |     guard recorder.isAvailable else {
119 |         return handler(ScreenRecorderError.notAvailable)
120 |     }
121 |     recorder.startCapture(handler: { (sampleBuffer, sampleType, passedError) in
    |              |- error: 'startCapture(handler:completionHandler:)' is only available in macOS 11.0 or newer
    |              `- note: add 'if #available' version check
122 |       if let passedError = passedError {
123 |         handler(passedError)
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:162:14: error: 'stopCapture(handler:)' is only available in macOS 11.0 or newer
 16 | }
 17 |
 18 | final public class ScreenRecorder {
    |                    `- note: add @available attribute to enclosing class
 19 |   private var videoOutputURL: URL?
 20 |   private var videoWriter: AVAssetWriter?
    :
159 |   - Parameter errorHandler: Called when an error is found
160 |   */
161 |   public func stoprecording(handler: @escaping (Error?) -> Void) {
    |               `- note: add @available attribute to enclosing instance method
162 |     recorder.stopCapture( handler: { error in
    |              |- error: 'stopCapture(handler:)' is only available in macOS 11.0 or newer
    |              `- note: add 'if #available' version check
163 |       if let error = error {
164 |         handler(error)
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:183:63: error: cannot find 'errorHandler' in scope
181 |     }
182 |     self.videoWriter?.finishWriting {
183 |       self.saveVideoToCameraRollAfterAuthorized(errorHandler: errorHandler)
    |                                                               `- error: cannot find 'errorHandler' in scope
184 |     }
185 |   }
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:183:48: error: incorrect argument label in call (have 'errorHandler:', expected 'handler:')
181 |     }
182 |     self.videoWriter?.finishWriting {
183 |       self.saveVideoToCameraRollAfterAuthorized(errorHandler: errorHandler)
    |                                                `- error: incorrect argument label in call (have 'errorHandler:', expected 'handler:')
184 |     }
185 |   }
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:172:11: warning: capture of 'self' with non-sendable type 'ScreenRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
 16 | }
 17 |
 18 | final public class ScreenRecorder {
    |                    `- note: class 'ScreenRecorder' does not conform to the 'Sendable' protocol
 19 |   private var videoOutputURL: URL?
 20 |   private var videoWriter: AVAssetWriter?
    :
170 |         }
171 |         self.videoWriter?.finishWriting {
172 |           self.saveVideoToCameraRollAfterAuthorized(handler: handler)
    |           `- warning: capture of 'self' with non-sendable type 'ScreenRecorder' in a `@Sendable` closure; this is an error in the Swift 6 language mode
173 |         }
174 |       }
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:172:62: warning: capture of 'handler' with non-sendable type '((any Error)?) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
170 |         }
171 |         self.videoWriter?.finishWriting {
172 |           self.saveVideoToCameraRollAfterAuthorized(handler: handler)
    |                                                              |- warning: capture of 'handler' 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'
173 |         }
174 |       }
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:207:7: error: 'PHAssetChangeRequest' is only available in macOS 10.15 or newer
 16 | }
 17 |
 18 | final public class ScreenRecorder {
    |                    `- note: add @available attribute to enclosing class
 19 |   private var videoOutputURL: URL?
 20 |   private var videoWriter: AVAssetWriter?
    :
199 |   }
200 |
201 |   private func saveVideoToCameraRoll(handler: @escaping (Error?) -> Void) {
    |                `- note: add @available attribute to enclosing instance method
202 |     guard let videoOutputURL = self.videoOutputURL else {
203 |       return handler(nil)
    :
205 |
206 |     PHPhotoLibrary.shared().performChanges({
207 |       PHAssetChangeRequest.creationRequestForAssetFromVideo(atFileURL: videoOutputURL)
    |       |- error: 'PHAssetChangeRequest' is only available in macOS 10.15 or newer
    |       `- note: add 'if #available' version check
208 |     }, completionHandler: { _, error in
209 |       if let error = error {
/Users/admin/builder/spi-builder-workspace/Wyler/Wyler/ScreenRecorder.swift:207:28: error: 'creationRequestForAssetFromVideo(atFileURL:)' is only available in macOS 10.15 or newer
 16 | }
 17 |
 18 | final public class ScreenRecorder {
    |                    `- note: add @available attribute to enclosing class
 19 |   private var videoOutputURL: URL?
 20 |   private var videoWriter: AVAssetWriter?
    :
199 |   }
200 |
201 |   private func saveVideoToCameraRoll(handler: @escaping (Error?) -> Void) {
    |                `- note: add @available attribute to enclosing instance method
202 |     guard let videoOutputURL = self.videoOutputURL else {
203 |       return handler(nil)
    :
205 |
206 |     PHPhotoLibrary.shared().performChanges({
207 |       PHAssetChangeRequest.creationRequestForAssetFromVideo(atFileURL: videoOutputURL)
    |                            |- error: 'creationRequestForAssetFromVideo(atFileURL:)' is only available in macOS 10.15 or newer
    |                            `- note: add 'if #available' version check
208 |     }, completionHandler: { _, error in
209 |       if let error = error {
BUILD FAILURE 6.0 macosSpm