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 Inject, reference main (94c4d4), with Swift 6.1 for macOS (SPM) on 27 Apr 2025 09:39:15 UTC.

Swift 6 data race errors: 3

Build Command

env DEVELOPER_DIR=/Applications/Xcode-16.3.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.61.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/MaximBazarov/Inject.git
Reference: main
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/MaximBazarov/Inject
 * branch            main       -> FETCH_HEAD
 * [new branch]      main       -> origin/main
HEAD is now at 94c4d40 Update README.md
Cloned https://github.com/MaximBazarov/Inject.git
Revision (git rev-parse @):
94c4d40a5e09606f078720c4cc6aa194defb5d3d
SPI manifest file found: $PWD/.spi.yml
SUCCESS checkout https://github.com/MaximBazarov/Inject.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": "inject",
      "name": "Inject",
      "url": "https://github.com/MaximBazarov/Inject.git",
      "version": "unspecified",
      "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/Inject",
      "dependencies": [
      ]
    }
  ]
}
Fetching https://github.com/MaximBazarov/Inject.git
[4/194] Fetching inject
Fetched https://github.com/MaximBazarov/Inject.git from cache (0.67s)
Creating working copy for https://github.com/MaximBazarov/Inject.git
Working copy of https://github.com/MaximBazarov/Inject.git resolved at main (94c4d40)
warning: '.resolve-product-dependencies': dependency 'inject' is not used by any target
Found 0 product dependencies
========================================
Build
========================================
Selected platform:         macosSpm
Swift version:             6.1
Building package at path:  $PWD
https://github.com/MaximBazarov/Inject.git
https://github.com/MaximBazarov/Inject.git
{
  "dependencies" : [
  ],
  "manifest_display_name" : "Inject",
  "name" : "Inject",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
    {
      "name" : "macos",
      "version" : "12.0"
    },
    {
      "name" : "ios",
      "version" : "13.0"
    },
    {
      "name" : "watchos",
      "version" : "8.0"
    },
    {
      "name" : "tvos",
      "version" : "15.0"
    }
  ],
  "products" : [
    {
      "name" : "Inject",
      "targets" : [
        "Inject"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "Tests",
      "module_type" : "SwiftTarget",
      "name" : "Tests",
      "path" : "Tests",
      "sources" : [
        "Override_Tests.swift",
        "Strategy_Tests.swift"
      ],
      "target_dependencies" : [
        "Inject"
      ],
      "type" : "test"
    },
    {
      "c99name" : "Inject",
      "module_type" : "SwiftTarget",
      "name" : "Inject",
      "path" : "Sources",
      "product_memberships" : [
        "Inject"
      ],
      "sources" : [
        "Deprecating/DefaultValues.swift",
        "Deprecating/Dependency.swift",
        "Deprecating/DependencyKey.swift",
        "Deprecating/Injectable.swift",
        "Deprecating/Injected-PropertyWrapper.swift",
        "Deprecating/Lifespan.swift",
        "Deprecating/Scope.swift",
        "Injection.swift",
        "Instance.swift",
        "Strategy.swift",
        "Telemetry/Context.swift",
        "Telemetry/Telemetry.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.7"
}
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-16.3.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-2F0A5646E1D333AE.txt
[3/14] Compiling Inject DefaultValues.swift
[4/14] Compiling Inject Dependency.swift
[5/14] Emitting module Inject
/Users/admin/builder/spi-builder-workspace/Sources/Strategy.swift:53:16: warning: static property 'singleton' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
17 | /// ``Injection`` uses Strategy to define the way instances should be created,
18 | /// shared and when they should be deallocated.
19 | public struct Strategy {
   |               `- note: consider making struct 'Strategy' conform to the 'Sendable' protocol
20 |     let create: InstantiationStrategy
21 |     let destroy: DeallocationStrategy
   :
51 | public extension Strategy {
52 |     /// Instance is shared and never deallocated
53 |     static let singleton = Strategy(create: .shared, destroy: .neverDeallocated)
   |                |- warning: static property 'singleton' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
   |                |- note: add '@MainActor' to make static property 'singleton' part of global actor 'MainActor'
   |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
54 |
55 |     /// Instance is shared but deallocates when no one is using(referring) it.
/Users/admin/builder/spi-builder-workspace/Sources/Strategy.swift:56:16: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
17 | /// ``Injection`` uses Strategy to define the way instances should be created,
18 | /// shared and when they should be deallocated.
19 | public struct Strategy {
   |               `- note: consider making struct 'Strategy' conform to the 'Sendable' protocol
20 |     let create: InstantiationStrategy
21 |     let destroy: DeallocationStrategy
   :
54 |
55 |     /// Instance is shared but deallocates when no one is using(referring) it.
56 |     static let shared = Strategy(create: .shared, destroy: .whenLastConsumerLeave)
   |                |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
   |                |- note: add '@MainActor' to make static property 'shared' part of global actor 'MainActor'
   |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
57 |
58 |     /// A new instance created for every consumer and deallocates when this consumer deallocates.
/Users/admin/builder/spi-builder-workspace/Sources/Strategy.swift:59:16: warning: static property 'onDemand' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
17 | /// ``Injection`` uses Strategy to define the way instances should be created,
18 | /// shared and when they should be deallocated.
19 | public struct Strategy {
   |               `- note: consider making struct 'Strategy' conform to the 'Sendable' protocol
20 |     let create: InstantiationStrategy
21 |     let destroy: DeallocationStrategy
   :
57 |
58 |     /// A new instance created for every consumer and deallocates when this consumer deallocates.
59 |     static let onDemand = Strategy(create: .perConsumer, destroy: .whenLastConsumerLeave)
   |                |- warning: static property 'onDemand' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
   |                |- note: add '@MainActor' to make static property 'onDemand' part of global actor 'MainActor'
   |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
60 | }
61 |
[6/14] Compiling Inject Strategy.swift
/Users/admin/builder/spi-builder-workspace/Sources/Strategy.swift:53:16: warning: static property 'singleton' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
17 | /// ``Injection`` uses Strategy to define the way instances should be created,
18 | /// shared and when they should be deallocated.
19 | public struct Strategy {
   |               `- note: consider making struct 'Strategy' conform to the 'Sendable' protocol
20 |     let create: InstantiationStrategy
21 |     let destroy: DeallocationStrategy
   :
51 | public extension Strategy {
52 |     /// Instance is shared and never deallocated
53 |     static let singleton = Strategy(create: .shared, destroy: .neverDeallocated)
   |                |- warning: static property 'singleton' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
   |                |- note: add '@MainActor' to make static property 'singleton' part of global actor 'MainActor'
   |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
54 |
55 |     /// Instance is shared but deallocates when no one is using(referring) it.
/Users/admin/builder/spi-builder-workspace/Sources/Strategy.swift:56:16: warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
17 | /// ``Injection`` uses Strategy to define the way instances should be created,
18 | /// shared and when they should be deallocated.
19 | public struct Strategy {
   |               `- note: consider making struct 'Strategy' conform to the 'Sendable' protocol
20 |     let create: InstantiationStrategy
21 |     let destroy: DeallocationStrategy
   :
54 |
55 |     /// Instance is shared but deallocates when no one is using(referring) it.
56 |     static let shared = Strategy(create: .shared, destroy: .whenLastConsumerLeave)
   |                |- warning: static property 'shared' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
   |                |- note: add '@MainActor' to make static property 'shared' part of global actor 'MainActor'
   |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
57 |
58 |     /// A new instance created for every consumer and deallocates when this consumer deallocates.
/Users/admin/builder/spi-builder-workspace/Sources/Strategy.swift:59:16: warning: static property 'onDemand' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
17 | /// ``Injection`` uses Strategy to define the way instances should be created,
18 | /// shared and when they should be deallocated.
19 | public struct Strategy {
   |               `- note: consider making struct 'Strategy' conform to the 'Sendable' protocol
20 |     let create: InstantiationStrategy
21 |     let destroy: DeallocationStrategy
   :
57 |
58 |     /// A new instance created for every consumer and deallocates when this consumer deallocates.
59 |     static let onDemand = Strategy(create: .perConsumer, destroy: .whenLastConsumerLeave)
   |                |- warning: static property 'onDemand' is not concurrency-safe because non-'Sendable' type 'Strategy' may have shared mutable state; this is an error in the Swift 6 language mode
   |                |- note: add '@MainActor' to make static property 'onDemand' part of global actor 'MainActor'
   |                `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
60 | }
61 |
[7/14] Compiling Inject Context.swift
[8/14] Compiling Inject Injected-PropertyWrapper.swift
[9/14] Compiling Inject Lifespan.swift
[10/14] Compiling Inject Scope.swift
[11/14] Compiling Inject DependencyKey.swift
[12/14] Compiling Inject Injectable.swift
[13/14] Compiling Inject Instance.swift
[14/14] Compiling Inject Injection.swift
[15/15] Compiling Inject Telemetry.swift
Build complete! (5.69s)
Build complete.
{
  "dependencies" : [
  ],
  "manifest_display_name" : "Inject",
  "name" : "Inject",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
    {
      "name" : "macos",
      "version" : "12.0"
    },
    {
      "name" : "ios",
      "version" : "13.0"
    },
    {
      "name" : "watchos",
      "version" : "8.0"
    },
    {
      "name" : "tvos",
      "version" : "15.0"
    }
  ],
  "products" : [
    {
      "name" : "Inject",
      "targets" : [
        "Inject"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "Tests",
      "module_type" : "SwiftTarget",
      "name" : "Tests",
      "path" : "Tests",
      "sources" : [
        "Override_Tests.swift",
        "Strategy_Tests.swift"
      ],
      "target_dependencies" : [
        "Inject"
      ],
      "type" : "test"
    },
    {
      "c99name" : "Inject",
      "module_type" : "SwiftTarget",
      "name" : "Inject",
      "path" : "Sources",
      "product_memberships" : [
        "Inject"
      ],
      "sources" : [
        "Deprecating/DefaultValues.swift",
        "Deprecating/Dependency.swift",
        "Deprecating/DependencyKey.swift",
        "Deprecating/Injectable.swift",
        "Deprecating/Injected-PropertyWrapper.swift",
        "Deprecating/Lifespan.swift",
        "Deprecating/Scope.swift",
        "Injection.swift",
        "Instance.swift",
        "Strategy.swift",
        "Telemetry/Context.swift",
        "Telemetry/Telemetry.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.7"
}
✅  Doc result (pending) reported
========================================
GenerateDocs
========================================
Generating docs at path:  $PWD/.docs/maximbazarov/inject/main
Repository:               MaximBazarov/Inject
Swift version used:       6.1
Target:                   Inject
Extracting symbol information for 'Inject'...
Finished extracting symbol information for 'Inject'. (3.37s)
Building documentation for 'Inject'...
warning: Parameter 'column' is missing documentation
  --> Sources/Injection.swift:34:72-34:72
32 |     ///   - strategy: ``Strategy``
33 |     ///   - instance: an instance of the object.
34 +     ///   Will be used or not depending on the `strategy` and `storage`
   |                                                                        ╰─suggestion: Document 'column' parameter
35 |     public init(
36 |         strategy: Strategy,
warning: Parameter 'fileID' is missing documentation
  --> Sources/Injection.swift:34:72-34:72
32 |     ///   - strategy: ``Strategy``
33 |     ///   - instance: an instance of the object.
34 +     ///   Will be used or not depending on the `strategy` and `storage`
   |                                                                        ╰─suggestion: Document 'fileID' parameter
35 |     public init(
36 |         strategy: Strategy,
warning: Parameter 'line' is missing documentation
  --> Sources/Injection.swift:34:72-34:72
32 |     ///   - strategy: ``Strategy``
33 |     ///   - instance: an instance of the object.
34 +     ///   Will be used or not depending on the `strategy` and `storage`
   |                                                                        ╰─suggestion: Document 'line' parameter
35 |     public init(
36 |         strategy: Strategy,
warning: Parameter 'file' is missing documentation
  --> Sources/Injection.swift:34:72-34:72
32 |     ///   - strategy: ``Strategy``
33 |     ///   - instance: an instance of the object.
34 +     ///   Will be used or not depending on the `strategy` and `storage`
   |                                                                        ╰─suggestion: Document 'file' parameter
35 |     public init(
36 |         strategy: Strategy,
warning: Parameter 'function' is missing documentation
  --> Sources/Injection.swift:34:72-34:72
32 |     ///   - strategy: ``Strategy``
33 |     ///   - instance: an instance of the object.
34 +     ///   Will be used or not depending on the `strategy` and `storage`
   |                                                                        ╰─suggestion: Document 'function' parameter
35 |     public init(
36 |         strategy: Strategy,
warning: Parameter 'context' not found in instance method declaration
  --> Sources/Telemetry/Telemetry.swift:48:11-48:64
46 |     ///   - injection: injection that was overridden.
47 |     ///   - override: a new injection it was overridden with.
48 +     ///   - context: context where override was initiated from.
   |           ╰─suggestion: Remove 'context' parameter documentation
49 |     func log<O>(injection: Injection<O>, overridden override: Injection<O>)
50 |
warning: Parameter 'override' not found in instance method declaration
  --> Sources/Telemetry/Telemetry.swift:63:11-63:62
61 |     /// - Parameters:
62 |     ///   - injection: injection that was overridden.
63 +     ///   - override: a new injection it was overridden with.
   |           ╰─suggestion: Remove 'override' parameter documentation
64 |     ///   - context: context where override was initiated from.
65 |     func log<O>(injection: Injection<O>, overriddenLocally instance: O, context: Context)
warning: Parameter 'instance' is missing documentation
  --> Sources/Telemetry/Telemetry.swift:64:64-64:64
62 |     ///   - injection: injection that was overridden.
63 |     ///   - override: a new injection it was overridden with.
64 +     ///   - context: context where override was initiated from.
   |           ╰─suggestion: Document 'instance' parameter
65 |     func log<O>(injection: Injection<O>, overriddenLocally instance: O, context: Context)
66 |
Finished building documentation for 'Inject' (0.13s)
Generated documentation archive at:
  /Users/admin/builder/spi-builder-workspace/.docs/maximbazarov/inject/main
Fetching https://github.com/swiftlang/swift-docc-plugin from cache
Fetched https://github.com/swiftlang/swift-docc-plugin from cache (0.46s)
Computing version for https://github.com/swiftlang/swift-docc-plugin
Computed https://github.com/swiftlang/swift-docc-plugin at 1.4.3 (1.04s)
Fetching https://github.com/swiftlang/swift-docc-symbolkit from cache
Fetched https://github.com/swiftlang/swift-docc-symbolkit from cache (0.68s)
Computing version for https://github.com/swiftlang/swift-docc-symbolkit
Computed https://github.com/swiftlang/swift-docc-symbolkit at 1.0.0 (1.32s)
Creating working copy for https://github.com/swiftlang/swift-docc-plugin
Working copy of https://github.com/swiftlang/swift-docc-plugin resolved at 1.4.3
Creating working copy for https://github.com/swiftlang/swift-docc-symbolkit
Working copy of https://github.com/swiftlang/swift-docc-symbolkit resolved at 1.0.0
Building for debugging...
[0/8] Write sources
[3/8] Write snippet-extract-tool-entitlement.plist
[4/8] Write swift-version-2F0A5646E1D333AE.txt
[6/53] Emitting module SymbolKit
[7/57] Compiling SymbolKit SemanticVersion.swift
[8/57] Compiling SymbolKit AccessControl.swift
[9/57] Compiling SymbolKit Availability.swift
[10/57] Compiling SymbolKit AvailabilityItem.swift
[11/57] Compiling SymbolKit Domain.swift
[12/57] Compiling Snippets SnippetParser.swift
[13/57] Emitting module Snippets
[14/57] Compiling Snippets Snippet.swift
[15/57] Compiling SymbolKit Symbol.swift
[16/57] Compiling SymbolKit SymbolKind.swift
[17/57] Compiling SymbolKit SymbolGraph.swift
[18/57] Compiling SymbolKit GraphCollector.swift
[19/57] Compiling SymbolKit DeclarationFragments.swift
[20/57] Compiling SymbolKit Fragment.swift
[21/57] Compiling SymbolKit FragmentKind.swift
[22/57] Compiling SymbolKit FunctionParameter.swift
[23/57] Compiling SymbolKit FunctionSignature.swift
[24/57] Compiling SymbolKit Names.swift
[25/57] Compiling SymbolKit SPI.swift
[26/57] Compiling SymbolKit Snippet.swift
[27/57] Compiling SymbolKit Extension.swift
[28/57] Compiling SymbolKit GenericConstraint.swift
[29/57] Compiling SymbolKit GenericParameter.swift
[30/57] Compiling SymbolKit Generics.swift
[31/57] Compiling SymbolKit Namespace.swift
[32/57] Compiling SymbolKit Relationship.swift
[33/57] Compiling SymbolKit RelationshipKind.swift
[34/57] Compiling SymbolKit SourceOrigin.swift
[35/57] Compiling SymbolKit GenericConstraints.swift
[36/57] Compiling SymbolKit Swift.swift
[37/57] Compiling SymbolKit Identifier.swift
[38/57] Compiling SymbolKit KindIdentifier.swift
[39/57] Compiling SymbolKit Location.swift
[40/57] Compiling SymbolKit Mutability.swift
[41/57] Compiling SymbolKit SourceRange.swift
[42/57] Compiling SymbolKit Metadata.swift
[43/57] Compiling SymbolKit Module.swift
[44/57] Compiling SymbolKit OperatingSystem.swift
[45/57] Compiling SymbolKit Platform.swift
[46/57] Compiling SymbolKit Mixin+Equals.swift
[47/57] Compiling SymbolKit Mixin+Hash.swift
[48/57] Compiling SymbolKit Mixin.swift
[49/57] Compiling SymbolKit LineList.swift
[50/57] Compiling SymbolKit Position.swift
[51/57] Compiling SymbolKit UnifiedSymbol+Encodable.swift
[52/57] Compiling SymbolKit UnifiedSymbol.swift
[53/57] Compiling SymbolKit UnifiedSymbolGraph+Encodable.swift
[54/57] Compiling SymbolKit UnifiedSymbolGraph.swift
[55/61] Compiling snippet_extract URL+Status.swift
[56/61] Compiling snippet_extract SymbolGraph+Snippet.swift
[57/61] Emitting module snippet_extract
[58/61] Compiling snippet_extract SnippetBuildCommand.swift
[58/61] Write Objects.LinkFileList
[59/61] Linking snippet-extract-tool
[60/61] Applying snippet-extract-tool
Build of product 'snippet-extract' complete! (4.26s)
Building for debugging...
[0/1] Write swift-version-2F0A5646E1D333AE.txt
[2/13] Compiling Inject Instance.swift
[3/14] Compiling Inject Strategy.swift
[4/14] Compiling Inject Context.swift
[5/14] Compiling Inject Scope.swift
[6/14] Compiling Inject Injected-PropertyWrapper.swift
[7/14] Compiling Inject Injection.swift
[8/14] Compiling Inject Lifespan.swift
[9/14] Compiling Inject DefaultValues.swift
[10/14] Compiling Inject Dependency.swift
[11/14] Compiling Inject DependencyKey.swift
[12/14] Compiling Inject Injectable.swift
[13/14] Emitting module Inject
[14/14] Compiling Inject Telemetry.swift
Build of target: 'Inject' complete! (1.42s)
     166
2	/Users/admin/builder/spi-builder-workspace/.docs/maximbazarov/inject/main
✅  Doc result (uploading) reported
========================================
SyncDocs
========================================
Doc archive source directory: $PWD/.docs/maximbazarov/inject/main
File count: 166
Doc size:   2.0MB
Preparing doc bundle ...
Uploading prod-maximbazarov-inject-main-afaaa3f4.zip to s3://spi-docs-inbox/prod-maximbazarov-inject-main-afaaa3f4.zip
Copying... [15%]
Copying... [29%]
Copying... [44%]
Copying... [58%]
Copying... [73%]
Copying... [87%]
Copying... [100%]
Done.