The Swift Package Index logo.Swift Package Index

Build Information

Failed to build Realtime with Swift 5.7 for Linux.

Build Command

bash -c docker run --rm -v "checkouts-4609320-1":/host -w "$PWD/checkout" registry.gitlab.com/finestructure/spi-images:basic-5.7-latest swift build 2>&1

Build Log

========================================
RunAll
========================================
Builder version: 4.25.4
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/supabase-community/realtime-swift.git
Reference: main
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/supabase-community/realtime-swift
 * branch            main       -> FETCH_HEAD
 * [new branch]      main       -> origin/main
HEAD is now at 5ea1fd2 Update README.md
Cloned https://github.com/supabase-community/realtime-swift.git
Revision (git rev-parse @):
5ea1fd24469191d5dd7421d3dbf42c88c5c0d5ba
SUCCESS checkout https://github.com/supabase-community/realtime-swift.git at main
========================================
Build
========================================
Selected platform:         linux
Swift version:             5.7
Building package at path:  $PWD/checkout
Running build ...
bash -c docker run --rm -v "checkouts-4609320-1":/host -w "$PWD/checkout" registry.gitlab.com/finestructure/spi-images:basic-5.7-latest swift build 2>&1
Building for debugging...
[1/11] Compiling Realtime StateChangeCallbacks.swift
[2/12] Compiling Realtime Transport.swift
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:138:21: error: cannot find type 'URLSessionWebSocketTask' in scope
  private var task: URLSessionWebSocketTask?
                    ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:209:22: error: cannot find type 'URLSessionWebSocketTask' in scope
    webSocketTask _: URLSessionWebSocketTask,
                     ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:222:22: error: cannot find type 'URLSessionWebSocketTask' in scope
    webSocketTask _: URLSessionWebSocketTask,
                     ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:223:29: error: cannot find type 'URLSessionWebSocketTask' in scope
    didCloseWith closeCode: URLSessionWebSocketTask.CloseCode,
                            ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:130:56: error: cannot find type 'URLSessionWebSocketDelegate' in scope
public class URLSessionTransport: NSObject, Transport, URLSessionWebSocketDelegate {
                                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:177:61: error: argument type 'URLSessionTransport' does not conform to expected type 'URLSessionDelegate'
    session = URLSession(configuration: .default, delegate: self, delegateQueue: OperationQueue())
                                                            ^
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:177:61: note: add missing conformance to 'URLSessionDelegate' to class 'URLSessionTransport'
    session = URLSession(configuration: .default, delegate: self, delegateQueue: OperationQueue())
                                                            ^
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:178:21: error: value of type 'URLSession' has no member 'webSocketTask'
    task = session?.webSocketTask(with: url)
           ~~~~~~~~ ^~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:191:27: error: cannot find 'URLSessionWebSocketTask' in scope
    guard let closeCode = URLSessionWebSocketTask.CloseCode(rawValue: code) else {
                          ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:200:17: error: cannot infer contextual base in reference to member 'data'
    task?.send(.data(data)) { _ in
               ~^~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:245:11: error: type of expression is ambiguous without more context
    task?.receive { result in
    ~~~~~~^~~~~~~~~~~~~~~~~~~
[3/12] Compiling Realtime RealtimeClient.swift
/host/spi-builder-workspace/Sources/Realtime/RealtimeClient.swift:715:4: error: Objective-C interoperability is disabled
  @objc func sendHeartbeat() {
  ~^~~~~

[4/12] Compiling Realtime Channel.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)[5/12] Compiling Realtime Defaults.swift
[6/12] Compiling Realtime Delegated.swift
[7/12] Compiling Realtime HeartbeatTimer.swift
[8/12] Compiling Realtime Message.swift
[9/12] Compiling Realtime Push.swift
[10/12] Emitting module Realtime
/host/spi-builder-workspace/Sources/Realtime/RealtimeClient.swift:715:4: error: Objective-C interoperability is disabled
  @objc func sendHeartbeat() {
  ~^~~~~

/host/spi-builder-workspace/Sources/Realtime/Transport.swift:138:21: error: cannot find type 'URLSessionWebSocketTask' in scope
  private var task: URLSessionWebSocketTask?
                    ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:209:22: error: cannot find type 'URLSessionWebSocketTask' in scope
    webSocketTask _: URLSessionWebSocketTask,
                     ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:222:22: error: cannot find type 'URLSessionWebSocketTask' in scope
    webSocketTask _: URLSessionWebSocketTask,
                     ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:223:29: error: cannot find type 'URLSessionWebSocketTask' in scope
    didCloseWith closeCode: URLSessionWebSocketTask.CloseCode,
                            ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:130:56: error: cannot find type 'URLSessionWebSocketDelegate' in scope
public class URLSessionTransport: NSObject, Transport, URLSessionWebSocketDelegate {
                                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~
[11/12] Compiling Realtime SocketError.swift
[12/12] Compiling Realtime TimeoutTimer.swift
[0/1] Planning build
Building for debugging...
[1/3] Compiling Realtime Transport.swift
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:138:21: error: cannot find type 'URLSessionWebSocketTask' in scope
  private var task: URLSessionWebSocketTask?
                    ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:209:22: error: cannot find type 'URLSessionWebSocketTask' in scope
    webSocketTask _: URLSessionWebSocketTask,
                     ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:222:22: error: cannot find type 'URLSessionWebSocketTask' in scope
    webSocketTask _: URLSessionWebSocketTask,
                     ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:223:29: error: cannot find type 'URLSessionWebSocketTask' in scope
    didCloseWith closeCode: URLSessionWebSocketTask.CloseCode,
                            ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:130:56: error: cannot find type 'URLSessionWebSocketDelegate' in scope
public class URLSessionTransport: NSObject, Transport, URLSessionWebSocketDelegate {
                                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:177:61: error: argument type 'URLSessionTransport' does not conform to expected type 'URLSessionDelegate'
    session = URLSession(configuration: .default, delegate: self, delegateQueue: OperationQueue())
                                                            ^
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:177:61: note: add missing conformance to 'URLSessionDelegate' to class 'URLSessionTransport'
    session = URLSession(configuration: .default, delegate: self, delegateQueue: OperationQueue())
                                                            ^
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:178:21: error: value of type 'URLSession' has no member 'webSocketTask'
    task = session?.webSocketTask(with: url)
           ~~~~~~~~ ^~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:191:27: error: cannot find 'URLSessionWebSocketTask' in scope
    guard let closeCode = URLSessionWebSocketTask.CloseCode(rawValue: code) else {
                          ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:200:17: error: cannot infer contextual base in reference to member 'data'
    task?.send(.data(data)) { _ in
               ~^~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:245:11: error: type of expression is ambiguous without more context
    task?.receive { result in
    ~~~~~~^~~~~~~~~~~~~~~~~~~
error: emit-module command failed with exit code 1 (use -v to see invocation)[2/3] Emitting module Realtime
/host/spi-builder-workspace/Sources/Realtime/RealtimeClient.swift:715:4: error: Objective-C interoperability is disabled
  @objc func sendHeartbeat() {
  ~^~~~~

/host/spi-builder-workspace/Sources/Realtime/Transport.swift:138:21: error: cannot find type 'URLSessionWebSocketTask' in scope
  private var task: URLSessionWebSocketTask?
                    ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:209:22: error: cannot find type 'URLSessionWebSocketTask' in scope
    webSocketTask _: URLSessionWebSocketTask,
                     ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:222:22: error: cannot find type 'URLSessionWebSocketTask' in scope
    webSocketTask _: URLSessionWebSocketTask,
                     ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:223:29: error: cannot find type 'URLSessionWebSocketTask' in scope
    didCloseWith closeCode: URLSessionWebSocketTask.CloseCode,
                            ^~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/Realtime/Transport.swift:130:56: error: cannot find type 'URLSessionWebSocketDelegate' in scope
public class URLSessionTransport: NSObject, Transport, URLSessionWebSocketDelegate {
                                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~
[3/3] Compiling Realtime RealtimeClient.swift
/host/spi-builder-workspace/Sources/Realtime/RealtimeClient.swift:715:4: error: Objective-C interoperability is disabled
  @objc func sendHeartbeat() {
  ~^~~~~

BUILD FAILURE 5.7 linux

Build Machine: Linux 2