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 StormGlass, reference 1.0.0 (917c32), with Swift 6.0 for macOS (SPM) on 1 Nov 2024 20:01:47 UTC.

Swift 6 data race errors: 3

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

Build Log

========================================
RunAll
========================================
Builder version: 4.56.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/cruisea-app/stormglass-swift.git
Reference: 1.0.0
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/cruisea-app/stormglass-swift
 * tag               1.0.0      -> FETCH_HEAD
HEAD is now at 917c32b Enable code coverage
Cloned https://github.com/cruisea-app/stormglass-swift.git
Revision (git rev-parse @):
917c32b003b0c5d16dcdbcb9f5784f07814df042
SUCCESS checkout https://github.com/cruisea-app/stormglass-swift.git at 1.0.0
========================================
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": "stormglass-swift",
      "name": "StormGlass",
      "url": "https://github.com/cruisea-app/stormglass-swift.git",
      "version": "unspecified",
      "path": "/Users/admin/builder/spi-builder-workspace/.resolve-product-dependencies/.build/checkouts/stormglass-swift",
      "dependencies": [
      ]
    }
  ]
}
Fetching https://github.com/cruisea-app/stormglass-swift.git
[4/357] Fetching stormglass-swift
Fetched https://github.com/cruisea-app/stormglass-swift.git from cache (0.87s)
Creating working copy for https://github.com/cruisea-app/stormglass-swift.git
Working copy of https://github.com/cruisea-app/stormglass-swift.git resolved at 1.0.0 (917c32b)
warning: '.resolve-product-dependencies': dependency 'stormglass-swift' 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/cruisea-app/stormglass-swift.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
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version--7754E27361AE5C74.txt
[3/20] Emitting module StormGlass
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/Endpoints/SGCoordinate.swift:12:25: warning: static property 'zero' is not concurrency-safe because non-'Sendable' type 'SGCoordinate' may have shared mutable state; this is an error in the Swift 6 language mode
 1 | import Foundation
 2 |
 3 | public struct SGCoordinate: Equatable {
   |               `- note: consider making struct 'SGCoordinate' conform to the 'Sendable' protocol
 4 |     public let latitude: Double
 5 |     public let longitude: Double
   :
10 |     }
11 |
12 |     internal static let zero = SGCoordinate(latitude: 0, longitude: 0)
   |                         |- warning: static property 'zero' is not concurrency-safe because non-'Sendable' type 'SGCoordinate' may have shared mutable state; this is an error in the Swift 6 language mode
   |                         |- note: annotate 'zero' 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
13 | }
14 |
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/SGConfiguration.swift:2:23: warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
1 | public class SGConfiguration {
2 |     public static var shared = SGConfiguration()
  |                       |- warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
  |                       |- note: convert 'shared' to a 'let' constant to make 'Sendable' shared state immutable
  |                       |- note: annotate 'shared' 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
3 |     private init() {}
4 |
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/SGServiceError.swift:81:16: warning: stored property 'errors' of 'Sendable'-conforming struct 'SGErrorResponse' has non-sendable type 'SGErrorResponse.Item'; this is an error in the Swift 6 language mode
74 |
75 | public struct SGErrorResponse: Error, Decodable, CustomStringConvertible {
76 |     public struct Item: Decodable {
   |                   `- note: consider making struct 'Item' conform to the 'Sendable' protocol
77 |         let key: String?
78 |         let params: [String]?
79 |     }
80 |
81 |     public let errors: Item
   |                `- warning: stored property 'errors' of 'Sendable'-conforming struct 'SGErrorResponse' has non-sendable type 'SGErrorResponse.Item'; this is an error in the Swift 6 language mode
82 |
83 |     public var description: String {
[4/21] Compiling StormGlass SGServiceError.swift
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/SGServiceError.swift:81:16: warning: stored property 'errors' of 'Sendable'-conforming struct 'SGErrorResponse' has non-sendable type 'SGErrorResponse.Item'; this is an error in the Swift 6 language mode
74 |
75 | public struct SGErrorResponse: Error, Decodable, CustomStringConvertible {
76 |     public struct Item: Decodable {
   |                   `- note: consider making struct 'Item' conform to the 'Sendable' protocol
77 |         let key: String?
78 |         let params: [String]?
79 |     }
80 |
81 |     public let errors: Item
   |                `- warning: stored property 'errors' of 'Sendable'-conforming struct 'SGErrorResponse' has non-sendable type 'SGErrorResponse.Item'; this is an error in the Swift 6 language mode
82 |
83 |     public var description: String {
[5/21] Compiling StormGlass SGParameterEncodable.swift
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/SGConfiguration.swift:2:23: warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
1 | public class SGConfiguration {
2 |     public static var shared = SGConfiguration()
  |                       |- warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
  |                       |- note: convert 'shared' to a 'let' constant to make 'Sendable' shared state immutable
  |                       |- note: annotate 'shared' 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
3 |     private init() {}
4 |
[6/21] Compiling StormGlass SGConfiguration.swift
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/SGConfiguration.swift:2:23: warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
1 | public class SGConfiguration {
2 |     public static var shared = SGConfiguration()
  |                       |- warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
  |                       |- note: convert 'shared' to a 'let' constant to make 'Sendable' shared state immutable
  |                       |- note: annotate 'shared' 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
3 |     private init() {}
4 |
[7/21] Compiling StormGlass SGDataSource.swift
[8/21] Compiling StormGlass SGElevationPointRequest.swift
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/Endpoints/SGCoordinate.swift:12:25: warning: static property 'zero' is not concurrency-safe because non-'Sendable' type 'SGCoordinate' may have shared mutable state; this is an error in the Swift 6 language mode
 1 | import Foundation
 2 |
 3 | public struct SGCoordinate: Equatable {
   |               `- note: consider making struct 'SGCoordinate' conform to the 'Sendable' protocol
 4 |     public let latitude: Double
 5 |     public let longitude: Double
   :
10 |     }
11 |
12 |     internal static let zero = SGCoordinate(latitude: 0, longitude: 0)
   |                         |- warning: static property 'zero' is not concurrency-safe because non-'Sendable' type 'SGCoordinate' may have shared mutable state; this is an error in the Swift 6 language mode
   |                         |- note: annotate 'zero' 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
13 | }
14 |
[9/21] Compiling StormGlass SGCoordinate.swift
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/Endpoints/SGCoordinate.swift:12:25: warning: static property 'zero' is not concurrency-safe because non-'Sendable' type 'SGCoordinate' may have shared mutable state; this is an error in the Swift 6 language mode
 1 | import Foundation
 2 |
 3 | public struct SGCoordinate: Equatable {
   |               `- note: consider making struct 'SGCoordinate' conform to the 'Sendable' protocol
 4 |     public let latitude: Double
 5 |     public let longitude: Double
   :
10 |     }
11 |
12 |     internal static let zero = SGCoordinate(latitude: 0, longitude: 0)
   |                         |- warning: static property 'zero' is not concurrency-safe because non-'Sendable' type 'SGCoordinate' may have shared mutable state; this is an error in the Swift 6 language mode
   |                         |- note: annotate 'zero' 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
13 | }
14 |
[10/21] Compiling StormGlass SGEndpoint.swift
[11/21] Compiling StormGlass SGResponseMetadata.swift
[12/21] Compiling StormGlass SGTideExtremesPointRequest.swift
[13/21] Compiling StormGlass SGTideSeaLevelPointRequest.swift
[14/21] Compiling StormGlass SGSolarPointRequest.swift
[15/21] Compiling StormGlass SGTideDatum.swift
[16/21] Compiling StormGlass SGWeatherPointRequest.swift
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/SGConfiguration.swift:2:23: warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
1 | public class SGConfiguration {
2 |     public static var shared = SGConfiguration()
  |                       |- warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
  |                       |- note: convert 'shared' to a 'let' constant to make 'Sendable' shared state immutable
  |                       |- note: annotate 'shared' 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
3 |     private init() {}
4 |
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/Networking/SGNetworking.swift:75:21: warning: capture of 'completion' with non-sendable type '(Result<Endpoint.Response, any Error>) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
 73 |
 74 |                 if let error = error {
 75 |                     completion(.failure(error))
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<Endpoint.Response, 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'
 76 |                     return
 77 |                 }
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/Networking/SGNetworking.swift:86:37: warning: capture of 'self' with non-sendable type 'SGRequest<Endpoint>' in a `@Sendable` closure; this is an error in the Swift 6 language mode
  5 | #endif
  6 |
  7 | public struct SGRequest<Endpoint: SGEndpoint> {
    |               `- note: consider making generic struct 'SGRequest' conform to the 'Sendable' protocol
  8 |     internal let endpoint: Endpoint
  9 |     internal let apiKeyOverride: String?
    :
 84 |                 // Error Handling
 85 |
 86 |                 if let error = try? self.decoder.decode(SGErrorResponse.self, from: data) {
    |                                     `- warning: capture of 'self' with non-sendable type 'SGRequest<Endpoint>' in a `@Sendable` closure; this is an error in the Swift 6 language mode
 87 |                     completion(.failure(error))
 88 |                     return
[17/21] Compiling StormGlass SGNetworking.swift
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/SGConfiguration.swift:2:23: warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
1 | public class SGConfiguration {
2 |     public static var shared = SGConfiguration()
  |                       |- warning: static property 'shared' is not concurrency-safe because it is nonisolated global shared mutable state; this is an error in the Swift 6 language mode
  |                       |- note: convert 'shared' to a 'let' constant to make 'Sendable' shared state immutable
  |                       |- note: annotate 'shared' 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
3 |     private init() {}
4 |
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/Networking/SGNetworking.swift:75:21: warning: capture of 'completion' with non-sendable type '(Result<Endpoint.Response, any Error>) -> Void' in a `@Sendable` closure; this is an error in the Swift 6 language mode
 73 |
 74 |                 if let error = error {
 75 |                     completion(.failure(error))
    |                     |- warning: capture of 'completion' with non-sendable type '(Result<Endpoint.Response, 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'
 76 |                     return
 77 |                 }
/Users/admin/builder/spi-builder-workspace/Sources/StormGlass/Networking/SGNetworking.swift:86:37: warning: capture of 'self' with non-sendable type 'SGRequest<Endpoint>' in a `@Sendable` closure; this is an error in the Swift 6 language mode
  5 | #endif
  6 |
  7 | public struct SGRequest<Endpoint: SGEndpoint> {
    |               `- note: consider making generic struct 'SGRequest' conform to the 'Sendable' protocol
  8 |     internal let endpoint: Endpoint
  9 |     internal let apiKeyOverride: String?
    :
 84 |                 // Error Handling
 85 |
 86 |                 if let error = try? self.decoder.decode(SGErrorResponse.self, from: data) {
    |                                     `- warning: capture of 'self' with non-sendable type 'SGRequest<Endpoint>' in a `@Sendable` closure; this is an error in the Swift 6 language mode
 87 |                     completion(.failure(error))
 88 |                     return
[18/21] Compiling StormGlass SGTideStationsAreaRequest.swift
[19/21] Compiling StormGlass SGTideStationsListRequest.swift
[20/21] Compiling StormGlass SGAstronomyPointRequest.swift
[21/21] Compiling StormGlass SGBioPointRequest.swift
Build complete! (16.24s)
Build complete.
{
  "dependencies" : [
  ],
  "manifest_display_name" : "StormGlass",
  "name" : "StormGlass",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
    {
      "name" : "ios",
      "version" : "9.0"
    },
    {
      "name" : "macos",
      "version" : "10.10"
    },
    {
      "name" : "tvos",
      "version" : "9.0"
    },
    {
      "name" : "watchos",
      "version" : "2.0"
    }
  ],
  "products" : [
    {
      "name" : "StormGlass",
      "targets" : [
        "StormGlass"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "StormGlassTests",
      "module_type" : "SwiftTarget",
      "name" : "StormGlassTests",
      "path" : "Tests/StormGlassTests",
      "resources" : [
        {
          "path" : "/Users/admin/builder/spi-builder-workspace/Tests/StormGlassTests/Fixtures",
          "rule" : {
            "copy" : {
            }
          }
        }
      ],
      "sources" : [
        "SGAstronomyPointRequestTests.swift",
        "SGBaseTests.swift",
        "SGBioPointRequestTests.swift",
        "SGElevationPointRequestTests.swift",
        "SGIntegrationTests.swift",
        "SGSolarPointRequestTests.swift",
        "SGTideExtremesPointRequestTests.swift",
        "SGTideSeaLevelPointRequestTests.swift",
        "SGTideStationsAreaRequestTests.swift",
        "SGTideStationsListRequestTests.swift",
        "SGWeatherPointRequestTests.swift"
      ],
      "target_dependencies" : [
        "StormGlass"
      ],
      "type" : "test"
    },
    {
      "c99name" : "StormGlass",
      "module_type" : "SwiftTarget",
      "name" : "StormGlass",
      "path" : "Sources/StormGlass",
      "product_memberships" : [
        "StormGlass"
      ],
      "sources" : [
        "Endpoints/Astronomy/SGAstronomyPointRequest.swift",
        "Endpoints/Bio/SGBioPointRequest.swift",
        "Endpoints/Elevation/SGElevationPointRequest.swift",
        "Endpoints/SGCoordinate.swift",
        "Endpoints/SGEndpoint.swift",
        "Endpoints/SGResponseMetadata.swift",
        "Endpoints/Solar/SGSolarPointRequest.swift",
        "Endpoints/Tide/SGTideDatum.swift",
        "Endpoints/Tide/SGTideExtremesPointRequest.swift",
        "Endpoints/Tide/SGTideSeaLevelPointRequest.swift",
        "Endpoints/Tide/SGTideStationsAreaRequest.swift",
        "Endpoints/Tide/SGTideStationsListRequest.swift",
        "Endpoints/Weather/SGWeatherPointRequest.swift",
        "Networking/SGNetworking.swift",
        "Networking/SGParameterEncodable.swift",
        "SGConfiguration.swift",
        "SGDataSource.swift",
        "SGServiceError.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.3"
}
Done.