SwiftLint icon indicating copy to clipboard operation
SwiftLint copied to clipboard

SwiftLint v0.54.0 fails in CI with the error ComputeTargetDependencyGraph failed

Open sree127 opened this issue 2 years ago • 2 comments

New Issue Checklist

Describe the bug

Our CI fails to build the project after updating the SwiftLint version to 0.54.0. SwiftLint is the only package which we updated and the error seems to originate from this updation. Resolving the SwiftLint package to 0.53.0 seems to work fine.

We get the following error from the log:

Resolving Package Graph
Resolved source packages
SWXMLHash - https://github.com/drmohundro/SWXMLHash.git @ 7.0.2
Alamofire - https://github.com/Alamofire/Alamofire @ 5.8.1
Mocker - https://github.com/WeTransfer/Mocker @ 3.0.1
Nimble - https://github.com/Quick/Nimble @ 11.2.1
swift-syntax - https://github.com/apple/swift-syntax.git @ 509.0.2
Segment - https://github.com/segmentio/analytics-ios @ 4.1.8
PLCrashReporter - https://github.com/microsoft/plcrashreporter.git @ 1.11.1
swift-argument-parser - https://github.com/apple/swift-argument-parser.git @ 1.2.3
Yams - https://github.com/jpsim/Yams.git @ 5.0.6
SwiftyTextTable - https://github.com/scottrhoyt/SwiftyTextTable.git @ 0.9.0
CryptoSwift - https://github.com/krzyzanowskim/CryptoSwift.git @ 1.8.0
swift-collections - https://github.com/apple/swift-collections.git @ 1.0.5
CwlCatchException - https://github.com/mattgallagher/CwlCatchException.git @ 2.1.2
SourceKitten - https://github.com/jpsim/SourceKitten.git @ 0.34.1
Datadog - https://github.com/DataDog/dd-sdk-ios @ 2.5.0
SwiftLint - https://github.com/realm/SwiftLint @ 0.54.0
Lottie - https://github.com/airbnb/lottie-ios @ 4.3.3
CollectionConcurrencyKit - https://github.com/JohnSundell/CollectionConcurrencyKit.git @ 0.2.0
Quick - https://github.com/Quick/Quick @ 6.1.0
CwlPreconditionTesting - https://github.com/mattgallagher/CwlPreconditionTesting.git @ 2.2.0
Clean Succeeded
....
** ARCHIVE FAILED **


The following build commands failed:
	ComputeTargetDependencyGraph

PS: Unfortunately this is the only error that we get.

Environment

  • SwiftLint version v0.54.0
  • Installation method used: SPM
  • Which Xcode version are you using: Xcode 15.0

What did I try so far?

  • Downgrading the version to v0.53.0 seems to work

Please let me know if you need any further information. Thanks in advance. 🙏🏽

sree127 avatar Nov 15 '23 10:11 sree127

Can you please share the full log output I suspect there's some useful. You can get the full logs by clicking the "Export" button in the Xcode log window

image

jpsim avatar Nov 15 '23 15:11 jpsim

I'm also having the same issue on CI (GitHub actions) after updating to 0.54.0

AlvesQM avatar Dec 15 '23 11:12 AlvesQM

If you're using GitHub actions, SwiftLint v0.53.0 is installed on their macos-13 and macos-14 runners:

https://github.com/actions/runner-images/blob/main/images/macos/macos-13-Readme.md#linters https://github.com/actions/runner-images/blob/main/images/macos/macos-14-Readme.md#linters

mike-ghes avatar Apr 16 '24 16:04 mike-ghes

Hello. I am having the same issue

INFO [2024-06-03 09:32:48.68]: ▸ Resolving Package Graph INFO [2024-06-03 09:32:53.21]: ▸ Resolved source packages INFO [2024-06-03 09:32:53.21]: ▸ AppCheck - https://github.com/google/app-check.git @ 10.19.1 INFO [2024-06-03 09:32:53.21]: ▸ swift-log - https://github.com/apple/swift-log @ 1.5.4 INFO [2024-06-03 09:32:53.21]: ▸ gRPC - https://github.com/google/grpc-binary.git @ 1.62.2 INFO [2024-06-03 09:32:53.21]: ▸ Firebase - https://github.com/firebase/firebase-ios-sdk @ 10.27.0 INFO [2024-06-03 09:32:53.21]: ▸ Lottie - https://github.com/airbnb/lottie-spm.git @ 4.4.3 INFO [2024-06-03 09:32:53.21]: ▸ Promises - https://github.com/google/promises.git @ 2.4.0 INFO [2024-06-03 09:32:53.21]: ▸ CryptorRSA - https://github.com/Kitura/BlueRSA.git @ 1.0.201 INFO [2024-06-03 09:32:53.21]: ▸ swift-system - https://github.com/apple/swift-system.git @ 1.3.0 INFO [2024-06-03 09:32:53.21]: ▸ KituraContracts - https://github.com/Kitura/KituraContracts.git @ 2.0.1 INFO [2024-06-03 09:32:53.21]: ▸ swift-async-algorithms - https://github.com/apple/swift-async-algorithms @ 1.0.0 INFO [2024-06-03 09:32:53.22]: ▸ leveldb - https://github.com/firebase/leveldb.git @ 1.22.5 INFO [2024-06-03 09:32:53.22]: ▸ GoogleUtilities - https://github.com/google/GoogleUtilities.git @ 7.13.3 INFO [2024-06-03 09:32:53.22]: ▸ swift-collections - https://github.com/apple/swift-collections @ 1.1.0 INFO [2024-06-03 09:32:53.22]: ▸ swift-nio-ssl - https://github.com/apple/swift-nio-ssl.git @ 2.26.0 INFO [2024-06-03 09:32:53.22]: ▸ swift-nio - https://github.com/apple/swift-nio.git @ 2.65.0 INFO [2024-06-03 09:32:53.22]: ▸ swift-nio-extras - https://github.com/apple/swift-nio-extras.git @ 1.22.0 INFO [2024-06-03 09:32:53.22]: ▸ KeychainSwift - https://github.com/evgenyneu/keychain-swift @ 24.0.0 INFO [2024-06-03 09:32:53.22]: ▸ SwiftProtobuf - https://github.com/apple/swift-protobuf.git @ 1.25.2 INFO [2024-06-03 09:32:53.22]: ▸ InteropForGoogle - https://github.com/google/interop-ios-for-google-sdks.git @ 100.0.0 INFO [2024-06-03 09:32:53.22]: ▸ nanopb - https://github.com/firebase/nanopb.git @ 2.30910.0 INFO [2024-06-03 09:32:53.22]: ▸ GoogleAppMeasurement - https://github.com/google/GoogleAppMeasurement.git @ 10.27.0 INFO [2024-06-03 09:32:53.22]: ▸ SFSymbolsMacro - https://github.com/lukepistrol/SFSymbolsMacro.git @ 0.5.2 INFO [2024-06-03 09:32:53.22]: ▸ swift-atomics - https://github.com/apple/swift-atomics.git @ 1.2.0 INFO [2024-06-03 09:32:53.22]: ▸ Cryptor - https://github.com/Kitura/BlueCryptor.git @ 2.0.2 INFO [2024-06-03 09:32:53.22]: ▸ LoggerAPI - https://github.com/Kitura/LoggerAPI.git @ 2.0.0 INFO [2024-06-03 09:32:53.22]: ▸ grpc-swift - https://github.com/grpc/grpc-swift.git @ 1.21.1 INFO [2024-06-03 09:32:53.22]: ▸ CryptorECC - https://github.com/Kitura/BlueECC.git @ 1.2.201 INFO [2024-06-03 09:32:53.22]: ▸ swift-http-types - https://github.com/apple/swift-http-types @ 1.1.0 INFO [2024-06-03 09:32:53.22]: ▸ Nuke - https://github.com/kean/Nuke @ 12.7.1 INFO [2024-06-03 09:32:53.22]: ▸ swift-nio-transport-services - https://github.com/apple/swift-nio-transport-services.git @ 1.21.0 INFO [2024-06-03 09:32:53.22]: ▸ GoogleDataTransport - https://github.com/google/GoogleDataTransport.git @ 9.4.0 INFO [2024-06-03 09:32:53.23]: ▸ abseil - https://github.com/google/abseil-cpp-binary.git @ 1.2024011601.1 INFO [2024-06-03 09:32:53.23]: ▸ WrappingHStack - https://github.com/dkk/WrappingHStack @ 2.2.11 INFO [2024-06-03 09:32:53.23]: ▸ swift-syntax - https://github.com/apple/swift-syntax.git @ 509.1.1 INFO [2024-06-03 09:32:53.23]: ▸ swift-nio-http2 - https://github.com/apple/swift-nio-http2.git @ 1.31.0 INFO [2024-06-03 09:32:53.23]: ▸ GTMSessionFetcher - https://github.com/google/gtm-session-fetcher.git @ 3.4.1 INFO [2024-06-03 09:32:53.23]: ▸ SwiftJWT - https://github.com/Kitura/Swift-JWT @ 4.0.1 INFO [2024-06-03 09:32:57.90]: ▸ ** ARCHIVE FAILED ** INFO [2024-06-03 09:32:57.90]: ▸ The following build commands failed: INFO [2024-06-03 09:32:57.91]: ▸ ComputeTargetDependencyGraph INFO [2024-06-03 09:32:57.91]: ▸ (1 failure)

+----------------------------------------------+ 387| Build environment | 388+---------------+------------------------------+ 389| xcode_path | /Applications/Xcode_15.4.app | 390| gym_version | 2.220.0 | 391| export_method | app-store | 392| sdk | iPhoneOS17.5.sdk

christoschadjikyriakou avatar Jun 03 '24 11:06 christoschadjikyriakou

Might be a version conflict as SwiftLint requires SwiftSyntax starting from version 510.0.2 while the log lists 509.1.1.

SimplyDanny avatar Jun 08 '24 22:06 SimplyDanny

In case you are using the SwiftLint plugin in your builds, please consume it from this dedicated repository. It comes without any dependencies and so doesn't cause such issues (given that I'm right with my previous comment).

Anyway, since there hasn't been any activity in this thread for a while, I consider it resolved in one or the other way.

SimplyDanny avatar Jun 25 '24 17:06 SimplyDanny