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

Successful build of LoggerAPI, reference 2.0.0 (4e6b45), with Swift 6.0 for Linux on 28 Nov 2024 03:41:49 UTC.

Swift 6 data race errors: 4

Build Command

bash -c docker run --pull=always --rm -v "checkouts-4609320-2":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:basic-6.0-latest swift build --triple x86_64-unknown-linux-gnu -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 2>&1

Build Log

========================================
RunAll
========================================
Builder version: 4.58.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/Kitura/LoggerAPI.git
Reference: 2.0.0
Initialized empty Git repository in /host/spi-builder-workspace/.git/
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: 	git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: 	git branch -m <name>
From https://github.com/Kitura/LoggerAPI
 * tag               2.0.0      -> FETCH_HEAD
HEAD is now at 4e6b45e Update CI config; minimum Swift version is now 5.0 (#59)
Cloned https://github.com/Kitura/LoggerAPI.git
Revision (git rev-parse @):
4e6b45e850ffa275e8e26a24c6454fd709d5b6ac
SUCCESS checkout https://github.com/Kitura/LoggerAPI.git at 2.0.0
========================================
Build
========================================
Selected platform:         linux
Swift version:             6.0
Building package at path:  $PWD
https://github.com/Kitura/LoggerAPI.git
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4609320-2":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:basic-6.0-latest swift build --triple x86_64-unknown-linux-gnu -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 2>&1
basic-6.0-latest: Pulling from finestructure/spi-images
Digest: sha256:47d26c99ca4f1ac0a332c85fd5b13ff4390e72115219984a57a68fe9d1063a05
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:basic-6.0-latest
Fetching https://github.com/apple/swift-log.git
[1/3702] Fetching swift-log
Fetched https://github.com/apple/swift-log.git from cache (0.35s)
Computing version for https://github.com/apple/swift-log.git
Computed https://github.com/apple/swift-log.git at 1.6.2 (0.73s)
Creating working copy for https://github.com/apple/swift-log.git
Working copy of https://github.com/apple/swift-log.git resolved at 1.6.2
Building for debugging...
[0/3] Write sources
[2/3] Write swift-version-24593BA9C3E375BF.txt
[4/8] Compiling Logging Locks.swift
[5/8] Emitting module Logging
[6/8] Compiling Logging LogHandler.swift
[7/8] Compiling Logging Logging.swift
[8/8] Compiling Logging MetadataProvider.swift
[10/11] Emitting module LoggerAPI
/host/spi-builder-workspace/Sources/LoggerAPI/Logger.swift:83:24: warning: static property '_logger' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 81 | public class Log {
 82 |
 83 |     private static var _logger: Logger?
    |                        |- warning: static property '_logger' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: convert '_logger' to a 'let' constant to make 'Sendable' shared state immutable
    |                        |- note: annotate '_logger' 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
 84 |     private static var _loggerLock: NSLock = NSLock()
 85 |
/host/spi-builder-workspace/Sources/LoggerAPI/Logger.swift:84:24: warning: static property '_loggerLock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 82 |
 83 |     private static var _logger: Logger?
 84 |     private static var _loggerLock: NSLock = NSLock()
    |                        |- warning: static property '_loggerLock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: convert '_loggerLock' to a 'let' constant to make 'Sendable' shared state immutable
    |                        |- note: annotate '_loggerLock' 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
 85 |
 86 |     /// An instance of the logger. It should usually be the one and only reference
/host/spi-builder-workspace/Sources/LoggerAPI/Logger.swift:99:24: warning: static property '_swiftLogger' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 97 |     }
 98 |
 99 |     private static var _swiftLogger: Logging.Logger?
    |                        |- warning: static property '_swiftLogger' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: convert '_swiftLogger' to a 'let' constant to make 'Sendable' shared state immutable
    |                        |- note: annotate '_swiftLogger' 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
100 |     private static var _swiftLoggerLock: NSLock = NSLock()
101 |
/host/spi-builder-workspace/Sources/LoggerAPI/Logger.swift:100:24: warning: static property '_swiftLoggerLock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 98 |
 99 |     private static var _swiftLogger: Logging.Logger?
100 |     private static var _swiftLoggerLock: NSLock = NSLock()
    |                        |- warning: static property '_swiftLoggerLock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: convert '_swiftLoggerLock' to a 'let' constant to make 'Sendable' shared state immutable
    |                        |- note: annotate '_swiftLoggerLock' 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
101 |
102 |     /// An instance of a swift-log Logger. If set, LoggerAPI will direct log messages
[11/11] Compiling LoggerAPI Logger.swift
/host/spi-builder-workspace/Sources/LoggerAPI/Logger.swift:83:24: warning: static property '_logger' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 81 | public class Log {
 82 |
 83 |     private static var _logger: Logger?
    |                        |- warning: static property '_logger' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: convert '_logger' to a 'let' constant to make 'Sendable' shared state immutable
    |                        |- note: annotate '_logger' 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
 84 |     private static var _loggerLock: NSLock = NSLock()
 85 |
/host/spi-builder-workspace/Sources/LoggerAPI/Logger.swift:84:24: warning: static property '_loggerLock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 82 |
 83 |     private static var _logger: Logger?
 84 |     private static var _loggerLock: NSLock = NSLock()
    |                        |- warning: static property '_loggerLock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: convert '_loggerLock' to a 'let' constant to make 'Sendable' shared state immutable
    |                        |- note: annotate '_loggerLock' 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
 85 |
 86 |     /// An instance of the logger. It should usually be the one and only reference
/host/spi-builder-workspace/Sources/LoggerAPI/Logger.swift:99:24: warning: static property '_swiftLogger' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 97 |     }
 98 |
 99 |     private static var _swiftLogger: Logging.Logger?
    |                        |- warning: static property '_swiftLogger' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: convert '_swiftLogger' to a 'let' constant to make 'Sendable' shared state immutable
    |                        |- note: annotate '_swiftLogger' 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
100 |     private static var _swiftLoggerLock: NSLock = NSLock()
101 |
/host/spi-builder-workspace/Sources/LoggerAPI/Logger.swift:100:24: warning: static property '_swiftLoggerLock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
 98 |
 99 |     private static var _swiftLogger: Logging.Logger?
100 |     private static var _swiftLoggerLock: NSLock = NSLock()
    |                        |- warning: static property '_swiftLoggerLock' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
    |                        |- note: convert '_swiftLoggerLock' to a 'let' constant to make 'Sendable' shared state immutable
    |                        |- note: annotate '_swiftLoggerLock' 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
101 |
102 |     /// An instance of a swift-log Logger. If set, LoggerAPI will direct log messages
Build complete! (11.64s)
Build complete.
{
  "dependencies" : [
    {
      "identity" : "swift-log",
      "requirement" : {
        "range" : [
          {
            "lower_bound" : "1.0.0",
            "upper_bound" : "2.0.0"
          }
        ]
      },
      "type" : "sourceControl",
      "url" : "https://github.com/apple/swift-log.git"
    }
  ],
  "manifest_display_name" : "LoggerAPI",
  "name" : "LoggerAPI",
  "path" : "/host/spi-builder-workspace",
  "platforms" : [
  ],
  "products" : [
    {
      "name" : "LoggerAPI",
      "targets" : [
        "LoggerAPI"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "LoggerAPI",
      "module_type" : "SwiftTarget",
      "name" : "LoggerAPI",
      "path" : "Sources/LoggerAPI",
      "product_dependencies" : [
        "Logging"
      ],
      "product_memberships" : [
        "LoggerAPI"
      ],
      "sources" : [
        "Logger.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.0"
}
basic-6.0-latest: Pulling from finestructure/spi-images
Digest: sha256:47d26c99ca4f1ac0a332c85fd5b13ff4390e72115219984a57a68fe9d1063a05
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:basic-6.0-latest
Done.