Same error happens not only from CLI, but also when archiving and validating the app directly using Xcode 13.0 from App Store and latest Xcode 13.2 (13C90) from Apple Developer.
Tried several times, using different WiFi networks and also tethering from my iPhone, but I got the same error.
Post
Replies
Boosts
Views
Activity
Using the workaround suggested by Skyler_S and Nekitosss works! The only scenario in which it doesn't is when you are using the bundle in UI Tests. I've found that it's sufficient to add:
swift
Bundle(for: CurrentBundleFinder.self).resourceURL?.deletingLastPathComponent()
to the list of candidates:
swift
let candidates = [
/* Bundle should be present here when the package is linked into an App. */
Bundle.main.resourceURL,
/* Bundle should be present here when the package is linked into a framework. */
Bundle(for: CurrentBundleFinder.self).resourceURL,
/* Bundle should be present here when the package is used in UI Tests. */
Bundle(for: CurrentBundleFinder.self).resourceURL?.deletingLastPathComponent(),
/* For command-line tools. */
Bundle.main.bundleURL,
/* Bundle should be present here when running previews from a different package (this is the path to "…/Debug-iphonesimulator/"). */
Bundle(for: CurrentBundleFinder.self).resourceURL?.deletingLastPathComponent().deletingLastPathComponent().deletingLastPathComponent(),
Bundle(for: CurrentBundleFinder.self).resourceURL?.deletingLastPathComponent().deletingLastPathComponent()
]