This is a staging environment. For live and up-to-date package information, visit swiftpackageindex.com.

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 DictionaryEncoder with Swift 6.0 for macOS (SPM).

Swift 6 data race errors: 3

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/adam-fowler/dictionary-encoder.git
Reference: master
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/adam-fowler/dictionary-encoder
 * branch            master     -> FETCH_HEAD
 * [new branch]      master     -> origin/master
HEAD is now at 87eef97 Travis config update
Cloned https://github.com/adam-fowler/dictionary-encoder.git
Revision (git rev-parse @):
87eef97292dc2f058e02a1d4b30c9419e1c99e72
SUCCESS checkout https://github.com/adam-fowler/dictionary-encoder.git at master
========================================
Build
========================================
Selected platform:         macosSpm
Swift version:             6.0
Building package at path:  $workDir
https://github.com/adam-fowler/dictionary-encoder.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/4] Emitting module DictionaryEncoder
/Users/admin/builder/spi-builder-workspace/Sources/DictionaryEncoder/DictionaryEncoder.swift:75:27: warning: static property 'prettyPrinted' is not concurrency-safe because non-'Sendable' type 'DictionaryEncoder.OutputFormatting' may have shared mutable state; this is an error in the Swift 6 language mode
  63 |
  64 |     /// The formatting of the output dictionary data.
  65 |     public struct OutputFormatting : OptionSet {
     |                   `- note: consider making struct 'OutputFormatting' conform to the 'Sendable' protocol
  66 |         /// The format's default value.
  67 |         public let rawValue: UInt
     :
  73 |
  74 |         /// Produce human-readable text in dictionary with indented output.
  75 |         public static let prettyPrinted = OutputFormatting(rawValue: 1 << 0)
     |                           |- warning: static property 'prettyPrinted' is not concurrency-safe because non-'Sendable' type 'DictionaryEncoder.OutputFormatting' may have shared mutable state; this is an error in the Swift 6 language mode
     |                           |- note: annotate 'prettyPrinted' 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
  76 |
  77 |         /// Produce JSON with dictionary keys sorted in lexicographic order.
/Users/admin/builder/spi-builder-workspace/Sources/DictionaryEncoder/DictionaryEncoder.swift:79:27: warning: static property 'sortedKeys' is not concurrency-safe because non-'Sendable' type 'DictionaryEncoder.OutputFormatting' may have shared mutable state; this is an error in the Swift 6 language mode
  63 |
  64 |     /// The formatting of the output dictionary data.
  65 |     public struct OutputFormatting : OptionSet {
     |                   `- note: consider making struct 'OutputFormatting' conform to the 'Sendable' protocol
  66 |         /// The format's default value.
  67 |         public let rawValue: UInt
     :
  77 |         /// Produce JSON with dictionary keys sorted in lexicographic order.
  78 |         @available(macOS 10.13, iOS 11.0, watchOS 4.0, tvOS 11.0, *)
  79 |         public static let sortedKeys    = OutputFormatting(rawValue: 1 << 1)
     |                           |- warning: static property 'sortedKeys' is not concurrency-safe because non-'Sendable' type 'DictionaryEncoder.OutputFormatting' may have shared mutable state; this is an error in the Swift 6 language mode
     |                           |- note: annotate 'sortedKeys' 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
  80 |     }
  81 |
/Users/admin/builder/spi-builder-workspace/Sources/DictionaryEncoder/DictionaryEncoder.swift:2545:17: warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
2543 | // NOTE: This value is implicitly lazy and _must_ be lazy. We're compiled against the latest SDK (w/ ISO8601DateFormatter), but linked against whichever Foundation the user has. ISO8601DateFormatter might not exist, so we better not hit this code path on an older OS.
2544 | @available(macOS 10.12, iOS 10.0, watchOS 3.0, tvOS 10.0, *)
2545 | fileprivate var _iso8601Formatter: ISO8601DateFormatter = {
     |                 |- warning: var '_iso8601Formatter' 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 '_iso8601Formatter' to a 'let' constant to make 'Sendable' shared state immutable
     |                 |- note: annotate '_iso8601Formatter' 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
2546 |     let formatter = ISO8601DateFormatter()
2547 |     formatter.formatOptions = .withInternetDateTime
[4/4] Compiling DictionaryEncoder DictionaryEncoder.swift
/Users/admin/builder/spi-builder-workspace/Sources/DictionaryEncoder/DictionaryEncoder.swift:75:27: warning: static property 'prettyPrinted' is not concurrency-safe because non-'Sendable' type 'DictionaryEncoder.OutputFormatting' may have shared mutable state; this is an error in the Swift 6 language mode
  63 |
  64 |     /// The formatting of the output dictionary data.
  65 |     public struct OutputFormatting : OptionSet {
     |                   `- note: consider making struct 'OutputFormatting' conform to the 'Sendable' protocol
  66 |         /// The format's default value.
  67 |         public let rawValue: UInt
     :
  73 |
  74 |         /// Produce human-readable text in dictionary with indented output.
  75 |         public static let prettyPrinted = OutputFormatting(rawValue: 1 << 0)
     |                           |- warning: static property 'prettyPrinted' is not concurrency-safe because non-'Sendable' type 'DictionaryEncoder.OutputFormatting' may have shared mutable state; this is an error in the Swift 6 language mode
     |                           |- note: annotate 'prettyPrinted' 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
  76 |
  77 |         /// Produce JSON with dictionary keys sorted in lexicographic order.
/Users/admin/builder/spi-builder-workspace/Sources/DictionaryEncoder/DictionaryEncoder.swift:79:27: warning: static property 'sortedKeys' is not concurrency-safe because non-'Sendable' type 'DictionaryEncoder.OutputFormatting' may have shared mutable state; this is an error in the Swift 6 language mode
  63 |
  64 |     /// The formatting of the output dictionary data.
  65 |     public struct OutputFormatting : OptionSet {
     |                   `- note: consider making struct 'OutputFormatting' conform to the 'Sendable' protocol
  66 |         /// The format's default value.
  67 |         public let rawValue: UInt
     :
  77 |         /// Produce JSON with dictionary keys sorted in lexicographic order.
  78 |         @available(macOS 10.13, iOS 11.0, watchOS 4.0, tvOS 11.0, *)
  79 |         public static let sortedKeys    = OutputFormatting(rawValue: 1 << 1)
     |                           |- warning: static property 'sortedKeys' is not concurrency-safe because non-'Sendable' type 'DictionaryEncoder.OutputFormatting' may have shared mutable state; this is an error in the Swift 6 language mode
     |                           |- note: annotate 'sortedKeys' 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
  80 |     }
  81 |
/Users/admin/builder/spi-builder-workspace/Sources/DictionaryEncoder/DictionaryEncoder.swift:2545:17: warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
2543 | // NOTE: This value is implicitly lazy and _must_ be lazy. We're compiled against the latest SDK (w/ ISO8601DateFormatter), but linked against whichever Foundation the user has. ISO8601DateFormatter might not exist, so we better not hit this code path on an older OS.
2544 | @available(macOS 10.12, iOS 10.0, watchOS 3.0, tvOS 10.0, *)
2545 | fileprivate var _iso8601Formatter: ISO8601DateFormatter = {
     |                 |- warning: var '_iso8601Formatter' 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 '_iso8601Formatter' to a 'let' constant to make 'Sendable' shared state immutable
     |                 |- note: annotate '_iso8601Formatter' 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
2546 |     let formatter = ISO8601DateFormatter()
2547 |     formatter.formatOptions = .withInternetDateTime
Build complete! (18.82s)
Build complete.
{
  "dependencies" : [
  ],
  "manifest_display_name" : "DictionaryEncoder",
  "name" : "DictionaryEncoder",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
  ],
  "products" : [
    {
      "name" : "DictionaryEncoder",
      "targets" : [
        "DictionaryEncoder"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "DictionaryEncoderTests",
      "module_type" : "SwiftTarget",
      "name" : "DictionaryEncoderTests",
      "path" : "Tests/DictionaryEncoderTests",
      "sources" : [
        "DictionaryEncoderTests.swift"
      ],
      "target_dependencies" : [
        "DictionaryEncoder"
      ],
      "type" : "test"
    },
    {
      "c99name" : "DictionaryEncoder",
      "module_type" : "SwiftTarget",
      "name" : "DictionaryEncoder",
      "path" : "Sources/DictionaryEncoder",
      "product_memberships" : [
        "DictionaryEncoder"
      ],
      "sources" : [
        "DictionaryEncoder.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.0"
}
Done.
This is a staging environment. For live and up-to-date package information, visit swiftpackageindex.com.