The Swift Package Index logo.Swift Package Index

Build Information

Failed to build AWSLambdaSwift, reference 0.2.0 (007267), with Swift 6.1 for Wasm on 27 May 2025 15:46:46 UTC.

Build Command

bash -c docker run --pull=always --rm -v "checkouts-4609320-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest swift build --swift-sdk wasm32-unknown-wasi 2>&1

Build Log

========================================
RunAll
========================================
Builder version: 4.63.1
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/tonisuter/aws-lambda-swift.git
Reference: 0.2.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/tonisuter/aws-lambda-swift
 * tag               0.2.0      -> FETCH_HEAD
HEAD is now at 0072674 Update for Swift 5.1
Cloned https://github.com/tonisuter/aws-lambda-swift.git
Revision (git rev-parse @):
00726748c8de14d4ca0bff540d9dc8d5bc7a900f
SUCCESS checkout https://github.com/tonisuter/aws-lambda-swift.git at 0.2.0
========================================
Build
========================================
Selected platform:         wasm
Swift version:             6.1
Building package at path:  $PWD
https://github.com/tonisuter/aws-lambda-swift.git
https://github.com/tonisuter/aws-lambda-swift.git
WARNING: environment variable SUPPRESS_SWIFT_6_FLAGS is not set
{
  "dependencies" : [
  ],
  "manifest_display_name" : "AWSLambdaSwift",
  "name" : "AWSLambdaSwift",
  "path" : "/host/spi-builder-workspace",
  "platforms" : [
  ],
  "products" : [
    {
      "name" : "AWSLambdaSwift",
      "targets" : [
        "AWSLambdaSwift"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "AWSLambdaSwift",
      "module_type" : "SwiftTarget",
      "name" : "AWSLambdaSwift",
      "path" : "Sources/AWSLambdaSwift",
      "product_memberships" : [
        "AWSLambdaSwift"
      ],
      "sources" : [
        "CodableHandlers.swift",
        "Context.swift",
        "JSONHandlers.swift",
        "Runtime.swift",
        "RuntimeError.swift",
        "Types.swift",
        "URLSession+Utils.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.1"
}
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4609320-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest swift build --swift-sdk wasm32-unknown-wasi -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
wasm-6.1-latest: Pulling from finestructure/spi-images
Digest: sha256:7e37457820e5f17452a98118754f345f2619722c485f2db0d8b666940a83afd2
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-24593BA9C3E375BF.txt
[3/10] Compiling AWSLambdaSwift RuntimeError.swift
[4/10] Compiling AWSLambdaSwift Types.swift
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Types.swift:28:33: error: cannot find 'DispatchGroup' in scope
26 |         case .async(let handler):
27 |             var handlerResult: HandlerResult?
28 |             let dispatchGroup = DispatchGroup()
   |                                 `- error: cannot find 'DispatchGroup' in scope
29 |             dispatchGroup.enter()
30 |             handler.apply(inputData: inputData, context: context) { result in
[5/10] Compiling AWSLambdaSwift URLSession+Utils.swift
/host/spi-builder-workspace/Sources/AWSLambdaSwift/URLSession+Utils.swift:6:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
 4 | #endif
 5 |
 6 | extension URLSession {
   | `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
 7 |     func synchronousDataTask(with url: URL) -> (Data?, URLResponse?, Error?) {
 8 |         let urlRequest = URLRequest(url: url)
/host/spi-builder-workspace/Sources/AWSLambdaSwift/URLSession+Utils.swift:12:47: error: cannot find type 'URLRequest' in scope
10 |     }
11 |
12 |     func synchronousDataTask(with urlRequest: URLRequest) -> (Data?, URLResponse?, Error?) {
   |                                               `- error: cannot find type 'URLRequest' in scope
13 |         var data: Data?
14 |         var response: URLResponse?
[6/10] Compiling AWSLambdaSwift JSONHandlers.swift
[7/10] Compiling AWSLambdaSwift Runtime.swift
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:20:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 18 |
 19 | public class Runtime {
 20 |     let urlSession: URLSession
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 21 |     let awsLambdaRuntimeAPI: String
 22 |     let handlerName: String
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:26:27: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 24 |
 25 |     public init() throws {
 26 |         self.urlSession = URLSession(configuration: .default)
    |                           `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 27 |         self.handlers = [:]
 28 |
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:26:54: error: cannot infer contextual base in reference to member 'default'
 24 |
 25 |     public init() throws {
 26 |         self.urlSession = URLSession(configuration: .default)
    |                                                      `- error: cannot infer contextual base in reference to member 'default'
 27 |         self.handlers = [:]
 28 |
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:45:59: error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 43 |     func getNextInvocation() throws -> (inputData: Data, responseHeaderFields: [AnyHashable: Any]) {
 44 |         let getNextInvocationEndpoint = URL(string: "http://\(awsLambdaRuntimeAPI)/2018-06-01/runtime/invocation/next")!
 45 |         let (optData, optResponse, optError) = urlSession.synchronousDataTask(with: getNextInvocationEndpoint)
    |                                                           `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 46 |
 47 |         guard optError == nil else {
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:61:26: error: cannot find 'URLRequest' in scope
 59 |     func postInvocationResponse(for requestId: String, httpBody: Data) {
 60 |         let postInvocationResponseEndpoint = URL(string: "http://\(awsLambdaRuntimeAPI)/2018-06-01/runtime/invocation/\(requestId)/response")!
 61 |         var urlRequest = URLRequest(url: postInvocationResponseEndpoint)
    |                          `- error: cannot find 'URLRequest' in scope
 62 |         urlRequest.httpMethod = "POST"
 63 |         urlRequest.httpBody = httpBody
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:64:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 62 |         urlRequest.httpMethod = "POST"
 63 |         urlRequest.httpBody = httpBody
 64 |         _ = urlSession.synchronousDataTask(with: urlRequest)
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 65 |     }
 66 |
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:74:26: error: cannot find 'URLRequest' in scope
 72 |
 73 |         let postInvocationErrorEndpoint = URL(string: "http://\(awsLambdaRuntimeAPI)/2018-06-01/runtime/invocation/\(requestId)/error")!
 74 |         var urlRequest = URLRequest(url: postInvocationErrorEndpoint)
    |                          `- error: cannot find 'URLRequest' in scope
 75 |         urlRequest.httpMethod = "POST"
 76 |         urlRequest.httpBody = httpBody
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:77:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 75 |         urlRequest.httpMethod = "POST"
 76 |         urlRequest.httpBody = httpBody
 77 |         _ = urlSession.synchronousDataTask(with: urlRequest)
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 78 |     }
 79 |
error: emit-module command failed with exit code 1 (use -v to see invocation)
[8/10] Compiling AWSLambdaSwift CodableHandlers.swift
[9/10] Compiling AWSLambdaSwift Context.swift
[10/10] Emitting module AWSLambdaSwift
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:20:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 18 |
 19 | public class Runtime {
 20 |     let urlSession: URLSession
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 21 |     let awsLambdaRuntimeAPI: String
 22 |     let handlerName: String
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/AWSLambdaSwift/URLSession+Utils.swift:6:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
 4 | #endif
 5 |
 6 | extension URLSession {
   | `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
 7 |     func synchronousDataTask(with url: URL) -> (Data?, URLResponse?, Error?) {
 8 |         let urlRequest = URLRequest(url: url)
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4609320-1":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest swift build --swift-sdk wasm32-unknown-wasi 2>&1
wasm-6.1-latest: Pulling from finestructure/spi-images
Digest: sha256:7e37457820e5f17452a98118754f345f2619722c485f2db0d8b666940a83afd2
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:wasm-6.1-latest
[0/1] Planning build
Building for debugging...
[0/1] Write swift-version-24593BA9C3E375BF.txt
[2/9] Compiling AWSLambdaSwift URLSession+Utils.swift
/host/spi-builder-workspace/Sources/AWSLambdaSwift/URLSession+Utils.swift:6:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
 4 | #endif
 5 |
 6 | extension URLSession {
   | `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
 7 |     func synchronousDataTask(with url: URL) -> (Data?, URLResponse?, Error?) {
 8 |         let urlRequest = URLRequest(url: url)
/host/spi-builder-workspace/Sources/AWSLambdaSwift/URLSession+Utils.swift:12:47: error: cannot find type 'URLRequest' in scope
10 |     }
11 |
12 |     func synchronousDataTask(with urlRequest: URLRequest) -> (Data?, URLResponse?, Error?) {
   |                                               `- error: cannot find type 'URLRequest' in scope
13 |         var data: Data?
14 |         var response: URLResponse?
[3/9] Compiling AWSLambdaSwift Types.swift
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Types.swift:28:33: error: cannot find 'DispatchGroup' in scope
26 |         case .async(let handler):
27 |             var handlerResult: HandlerResult?
28 |             let dispatchGroup = DispatchGroup()
   |                                 `- error: cannot find 'DispatchGroup' in scope
29 |             dispatchGroup.enter()
30 |             handler.apply(inputData: inputData, context: context) { result in
[4/9] Compiling AWSLambdaSwift RuntimeError.swift
[5/9] Compiling AWSLambdaSwift Runtime.swift
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:20:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 18 |
 19 | public class Runtime {
 20 |     let urlSession: URLSession
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 21 |     let awsLambdaRuntimeAPI: String
 22 |     let handlerName: String
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:26:27: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 24 |
 25 |     public init() throws {
 26 |         self.urlSession = URLSession(configuration: .default)
    |                           `- error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
 27 |         self.handlers = [:]
 28 |
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:26:54: error: cannot infer contextual base in reference to member 'default'
 24 |
 25 |     public init() throws {
 26 |         self.urlSession = URLSession(configuration: .default)
    |                                                      `- error: cannot infer contextual base in reference to member 'default'
 27 |         self.handlers = [:]
 28 |
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:45:59: error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 43 |     func getNextInvocation() throws -> (inputData: Data, responseHeaderFields: [AnyHashable: Any]) {
 44 |         let getNextInvocationEndpoint = URL(string: "http://\(awsLambdaRuntimeAPI)/2018-06-01/runtime/invocation/next")!
 45 |         let (optData, optResponse, optError) = urlSession.synchronousDataTask(with: getNextInvocationEndpoint)
    |                                                           `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 46 |
 47 |         guard optError == nil else {
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:61:26: error: cannot find 'URLRequest' in scope
 59 |     func postInvocationResponse(for requestId: String, httpBody: Data) {
 60 |         let postInvocationResponseEndpoint = URL(string: "http://\(awsLambdaRuntimeAPI)/2018-06-01/runtime/invocation/\(requestId)/response")!
 61 |         var urlRequest = URLRequest(url: postInvocationResponseEndpoint)
    |                          `- error: cannot find 'URLRequest' in scope
 62 |         urlRequest.httpMethod = "POST"
 63 |         urlRequest.httpBody = httpBody
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:64:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 62 |         urlRequest.httpMethod = "POST"
 63 |         urlRequest.httpBody = httpBody
 64 |         _ = urlSession.synchronousDataTask(with: urlRequest)
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 65 |     }
 66 |
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:74:26: error: cannot find 'URLRequest' in scope
 72 |
 73 |         let postInvocationErrorEndpoint = URL(string: "http://\(awsLambdaRuntimeAPI)/2018-06-01/runtime/invocation/\(requestId)/error")!
 74 |         var urlRequest = URLRequest(url: postInvocationErrorEndpoint)
    |                          `- error: cannot find 'URLRequest' in scope
 75 |         urlRequest.httpMethod = "POST"
 76 |         urlRequest.httpBody = httpBody
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:77:24: error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 75 |         urlRequest.httpMethod = "POST"
 76 |         urlRequest.httpBody = httpBody
 77 |         _ = urlSession.synchronousDataTask(with: urlRequest)
    |                        `- error: value of type 'URLSession' (aka 'AnyObject') has no member 'synchronousDataTask'
 78 |     }
 79 |
error: emit-module command failed with exit code 1 (use -v to see invocation)
[6/9] Emitting module AWSLambdaSwift
/host/spi-builder-workspace/Sources/AWSLambdaSwift/Runtime.swift:20:21: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 18 |
 19 | public class Runtime {
 20 |     let urlSession: URLSession
    |                     `- error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
 21 |     let awsLambdaRuntimeAPI: String
 22 |     let handlerName: String
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
1 | @available(*, unavailable, message: "This type has moved to the FoundationNetworking module. Import that module to use it.")
2 | public typealias URLSession = AnyObject
  |                  `- note: 'URLSession' has been explicitly marked unavailable here
/host/spi-builder-workspace/Sources/AWSLambdaSwift/URLSession+Utils.swift:6:1: error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
 4 | #endif
 5 |
 6 | extension URLSession {
   | `- error: non-nominal type 'URLSession' (aka 'AnyObject') cannot be extended
 7 |     func synchronousDataTask(with url: URL) -> (Data?, URLResponse?, Error?) {
 8 |         let urlRequest = URLRequest(url: url)
[7/9] Compiling AWSLambdaSwift CodableHandlers.swift
[8/9] Compiling AWSLambdaSwift JSONHandlers.swift
[9/9] Compiling AWSLambdaSwift Context.swift
BUILD FAILURE 6.1 wasm