tuist icon indicating copy to clipboard operation
tuist copied to clipboard

Warnings when generating SPM dependencies projects

Open kapitoshka438 opened this issue 6 months ago • 5 comments

What happened?

I'm getting a bunch of warnings when generating my app project using tuist generate --no-binary cache or tuist cache. They probably belong to different issues but I believe you guys will figure it out. Mentioned files do exist at those paths. It maybe related to platform filters described in Package.swift, not sure about what's wrong with xcprivacy and bundles.

How do we reproduce it?

Here is a part of the Package.swift to pay attention:

// swift-tools-version: 5.9
import PackageDescription

#if TUIST
    import ProjectDescription

    let packageSettings = PackageSettings(
        platforms: [.iOS]
    )

#endif

let package = Package(
    name: "PackageName",
    dependencies: [
        .package(url: "https://github.com/firebase/firebase-ios-sdk", exact: "10.21.0"),
        .package(url: "https://github.com/kasketis/netfox", exact: "1.21.0"),
        .package(url: "https://github.com/SVProgressHUD/SVProgressHUD", exact: "2.3.1"),
        ...
    ]
)

Error log

The following warnings need attention:
 · No files found at: {PROJECT_ROOT}/.build/checkouts/netfox/netfox/OSX/NetfoxWindow.xib
 · No files found at: {PROJECT_ROOT}/.build/checkouts/SVProgressHUD/SVProgressHUD/PrivacyInfo.xcprivacy
 · '{PROJECT_ROOT}/.build/checkouts/DateTools/DateToolsSwift/DateTools/DateTools.bundle' is a directory, try using: '{PROJECT_ROOT}/.build/checkouts/DateTools/DateToolsSwift/DateTools/DateTools.bundle/**' to list its files
 · '{PROJECT_ROOT}/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets' is a directory, try using: '{PROJECT_ROOT}/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets/**' to list its files
 · No files found at: {PROJECT_ROOT}/.build/checkouts/netfox/netfox/OSX/NFXResponseTypeCell_OSX.xib
 · No files found at: {PROJECT_ROOT}/.build/checkouts/netfox/netfox/OSX/NFXListCell_OSX.xib

macOS version

14.2.1

Tuist version

4.1.2

Xcode version

15.2

kapitoshka438 avatar Feb 13 '24 22:02 kapitoshka438

I still have similar warnings with Tuist 4.7.0: 'src/app/apple/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets' is a directory, try using: 'src/app/apple/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets/**' to list its files

ammerzon avatar Mar 19 '24 18:03 ammerzon

I also have the similar one with Tuist 4.7.0 😥

The following warnings need attention:
 · '{My Proejct Path}/Tuist/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets' is a directory, try using: '{My Proejct Path}/Tuist/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets/**' to list its files

hk-bae avatar Mar 22 '24 06:03 hk-bae

Thanks for reporting this folks 🙏🏼. Quick question, is the project that you get valid? (i.e., you can build it, run it, and test it).

pepicrft avatar Mar 31 '24 02:03 pepicrft

@pepicrft yes, It seems valid for now.

hk-bae avatar Mar 31 '24 14:03 hk-bae

Also getting the same: /Users/kekearif/Documents/MyCompany/MyApp/Tuist/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets' is a directory, try using: '/Users/kekearif/Documents/MyCompany/MyApp/Tuist/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets/**' to list its files

Tuist version is 4.9.0

kekearif avatar Apr 10 '24 09:04 kekearif

I also get similar warning on firebase and netfox:

The following warnings need attention:
 · No files found at: /~/../../Tuist/.build/checkouts/netfox/netfox/OSX/NetfoxWindow.xib
 · No files found at: /~/../../Tuist/.build/checkouts/netfox/netfox/OSX/NFXListCell_OSX.xib
 · No files found at: /~/../../Tuist/.build/checkouts/netfox/netfox/OSX/NFXResponseTypeCell_OSX.xib
 · '/~/../../Tuist/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets' is a directory, try using: '/~/../../Tuist/.build/checkouts/firebase-ios-sdk/FirebaseSessions/Tests/TestApp/Shared/Assets.xcassets/**' to list its files

In netfox package manifest, they already exclude OSX directory:

// swift-tools-version:5.3
import PackageDescription

let package = Package(
    name: "netfox",
    platforms: [
        .iOS(.v9)
    ],
    products: [
        .library(
            name: "netfox",
            targets: ["netfox"]
        ),
    ],
    targets: [
        .target(name: "netfox",
                path: "netfox/",
                exclude: ["OSX"])
    ],
    swiftLanguageVersions: [.v5]
)

Project was generated. But always show this warning

Tuist version: 4.11.0 Xcode version: 15.3

98prabowo avatar May 14 '24 04:05 98prabowo