Build Information
Failed to build WWNetworkClient, reference main (715545), with Swift 6.2 for macOS (SPM) on 12 Aug 2026 22:32:06 UTC.
Build Command
env DEVELOPER_DIR=/Applications/Xcode-26.3.0.app xcrun swift build --arch arm64Build Log
========================================
RunAll
========================================
Builder version: undefined version: run 'make version' to update
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/William-Weng/WWNetworkClient.git
Reference: main
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/William-Weng/WWNetworkClient
* branch main -> FETCH_HEAD
* [new branch] main -> origin/main
HEAD is now at 715545c - 整理程式碼
Cloned https://github.com/William-Weng/WWNetworkClient.git
Revision (git rev-parse @):
715545cea5a24ea498a56fc05d5ad63b1b60f55f
SUCCESS checkout https://github.com/William-Weng/WWNetworkClient.git at main
========================================
Build
========================================
Selected platform: macosSpm
Swift version: 6.2
Building package at path: $PWD
https://github.com/William-Weng/WWNetworkClient.git
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-26.3.0.app xcrun swift build --arch arm64
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version--3CB7CFEC50E0D141.txt
[3/7] Compiling WWNetworkClient WWNetworkClient.swift
/Users/admin/builder/spi-builder-workspace/Sources/WWNetworkClient/WWNetworkClient.swift:42:33: error: 'appending(queryItems:)' is only available in macOS 13.0 or newer
21 |
22 | // MARK: - 公開API
23 | public extension WWNetworkClient {
| `- note: add '@available' attribute to enclosing extension
24 |
25 | /// 發送網路請求(核心方法:使用標準 URL 物件發送)
:
34 | /// - Throws: `CustomError.invalidResponse` 代表伺服器回傳的回應無法識別為標準的 `HTTPURLResponse`
35 | /// - Returns: 包含 `HTTPURLResponse` 與原始 `Data` 的網路回傳結果
36 | func request(_ httpMethod: HTTPMethod = .get, url: URL, contentType: ContentType = .json, parameters: [String : String] = [:], headers: [HTTPHeaderField: String] = [:], httpBody: HTTPBobyType? = nil) async throws -> ResponseResult {
| `- note: add '@available' attribute to enclosing instance method
37 |
38 | var finalURL = url
:
40 | if !parameters.isEmpty {
41 | let queryItems = parameters.map { URLQueryItem(name: $0.key, value: $0.value) }
42 | finalURL = finalURL.appending(queryItems: queryItems)
| |- error: 'appending(queryItems:)' is only available in macOS 13.0 or newer
| `- note: add 'if #available' version check
43 | }
44 |
/Users/admin/builder/spi-builder-workspace/Sources/WWNetworkClient/WWNetworkClient.swift:55:50: error: 'data(for:delegate:)' is only available in macOS 12.0 or newer
21 |
22 | // MARK: - 公開API
23 | public extension WWNetworkClient {
| `- note: add '@available' attribute to enclosing extension
24 |
25 | /// 發送網路請求(核心方法:使用標準 URL 物件發送)
:
34 | /// - Throws: `CustomError.invalidResponse` 代表伺服器回傳的回應無法識別為標準的 `HTTPURLResponse`
35 | /// - Returns: 包含 `HTTPURLResponse` 與原始 `Data` 的網路回傳結果
36 | func request(_ httpMethod: HTTPMethod = .get, url: URL, contentType: ContentType = .json, parameters: [String : String] = [:], headers: [HTTPHeaderField: String] = [:], httpBody: HTTPBobyType? = nil) async throws -> ResponseResult {
| `- note: add '@available' attribute to enclosing instance method
37 |
38 | var finalURL = url
:
53 | if request.contentType == nil { request.contentType = contentType }
54 |
55 | let (data, response) = try await session.data(for: request)
| |- error: 'data(for:delegate:)' is only available in macOS 12.0 or newer
| `- note: add 'if #available' version check
56 |
57 | guard let httpResponse = response as? HTTPURLResponse else {
[4/7] Compiling WWNetworkClient Extension.swift
[5/7] Compiling WWNetworkClient Model.swift
[6/7] Emitting module WWNetworkClient
[7/7] Compiling WWNetworkClient Constant.swift
BUILD FAILURE 6.2 macosSpm