Hi, I've just migrated to Swift Tools 6.2 and package traits, and I'm encountering an issue when using traits with multiple targets in the same Xcode workspace.
Setup:
Main iOS app target
App Clip target
Both consume the same local packages (e.g., UIComponents)
What I'm trying to achieve:
Main app imports packages without the COMPACT_BUILD trait
App Clip imports packages with the COMPACT_BUILD trait enabled
Package configuration (simplified):
// UIComponents/Package.swift
let package = Package(
name: "UIComponents",
platforms: [.iOS(.v18)],
traits: [
.trait(name: "COMPACT_BUILD", description: "Minimal build for App Clips"),
],
// ...
targets: [
.target(
name: "UIComponents",
dependencies: [...],
swiftSettings: [
.define("COMPACT_BUILD", .when(traits: ["COMPACT_BUILD"])),
]
),
]
)
In the code:
#if COMPACT_BUILD
// Excluded from App Clip
#endif
The consumer packages:
Main app's package imports without trait:
.package(path: "../UIComponents")
App Clip's package imports with trait:
.package(path: "../UIComponents", traits: ["COMPACT_BUILD"])
The problem:
When building the main app target, the COMPACT_BUILD compiler condition is unexpectedly active — even though the main app's dependency chain never enables that trait. It seems like the trait enabled by the App Clip target is "leaking" into the main app build.
I confirmed this by adding #error("COMPACT_BUILD is active") — it triggers when building the main app, which shouldn't happen.
If I disable the App Clip target from the build scheme, the main app builds correctly with COMPACT_BUILD not defined.
I am also able to build the App Clip separately.
Environment:
Xcode 26.2
swift-tools-version: 6.2
iOS 26.2
Questions:
Is this expected behavior with Xcode's SPM integration? Are traits resolved workspace-wide rather than per-target?
Is there a workaround to have different trait configurations for different targets consuming the same package?
Or do I need to fall back to separate package targets (e.g., UIComponents and UIComponentsCompact) to achieve this?
Any guidance would be appreciated. Thanks!
Swift Packages
RSS for tagCreate reusable code, organize it in a lightweight way, and share it across Xcode projects and with other developers using Swift Packages.
Posts under Swift Packages tag
185 Posts
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
We are facing a DNS resolution issue with a specific ISP, where our domain name does not resolve correctly using the system DNS. However, the same domain works as expected when a custom DNS resolver is used.
On Android, this is straightforward to handle by configuring a custom DNS implementation using OkHttp / Retrofit. I am trying to implement a functionally equivalent solution in native iOS (Swift / SwiftUI).
**Android Reference (Working Behavior) : **
val dns = DnsOverHttps.Builder()
.client(OkHttpClient())
.url("https://cloudflare-dns.com/dns-query".toHttpUrl()) .bootstrapDnsHosts(InetAddress.getByName("1.1.1.1")).build()
OkHttpClient.Builder().dns(dns).build()
**Attempted iOS Approach **
I attempted the following approach :
Resolve the domain to an IP address programmatically (using DNS over HTTPS)
Connect directly to the resolved IP address
Set the original domain in the Host HTTP header
**DNS Resolution via DoH : **
func resolveDomain(domain: String) async throws -> String {
guard let url = URL(
string: "https://cloudflare-dns.com/dns-query?name=\(domain)&type=A"
) else {
throw URLError(.badURL)
}
var request = URLRequest(url: url)
request.setValue("application/dns-json", forHTTPHeaderField: "accept")
let (data, _) = try await URLSession.shared.data(for: request)
let response = try JSONDecoder().decode(DNSResponse.self, from: data)
guard let ip = response.Answer?.first?.data else {
throw URLError(.cannotFindHost)
}
return ip
}
**API Call Using Resolved IP : **
func callAPIUsingCustomDNS() async throws {
let ip = try await resolveDomain(domain: "example.com")
guard let url = URL(string: "https://\(ip)") else {
throw URLError(.badURL)
}
let configuration = URLSessionConfiguration.ephemeral
let session = URLSession(
configuration: configuration,
delegate: CustomURLSessionDelegate(originalHost: "example.com"),
delegateQueue: .main
)
var request = URLRequest(url: url)
request.setValue("example.com", forHTTPHeaderField: "Host")
let (_, response) = try await session.data(for: request)
print("Success: \(response)")
}
**Problem Encountered **
When connecting via the IP address, the TLS handshake fails with the following error:
Error Domain=NSURLErrorDomain Code=-1200
"A TLS error caused the secure connection to fail."
This appears to happen because iOS sends the IP address as the Server Name Indication (SNI) during the TLS handshake, while the server’s certificate is issued for the domain name.
**Custom URLSessionDelegate Attempt : **
class CustomURLSessionDelegate: NSObject, URLSessionDelegate {
let originalHost: String
init(originalHost: String) {
self.originalHost = originalHost
}
func urlSession(
_ session: URLSession,
didReceive challenge: URLAuthenticationChallenge,
completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
) {
guard challenge.protectionSpace.authenticationMethod == NSURLAuthenticationMethodServerTrust,
let serverTrust = challenge.protectionSpace.serverTrust else {
completionHandler(.performDefaultHandling, nil)
return
}
let sslPolicy = SecPolicyCreateSSL(true, originalHost as CFString)
let basicPolicy = SecPolicyCreateBasicX509()
SecTrustSetPolicies(serverTrust, [sslPolicy, basicPolicy] as CFArray)
var error: CFError?
if SecTrustEvaluateWithError(serverTrust, &error) {
completionHandler(.useCredential, URLCredential(trust: serverTrust))
} else {
completionHandler(.cancelAuthenticationChallenge, nil)
}
}
}
However, TLS validation still fails because the SNI remains the IP address, not the domain.
I would appreciate guidance on the supported and App Store–compliant way to handle ISP-specific DNS resolution issues on iOS. If custom DNS or SNI configuration is not supported, what alternative architectural approaches are recommended by Apple?
Currently, if as a library author you are shipping dependencies as code, you can use the #if DEBUG preprocessor check to execute logic based on whether app is being built for Debug or Release.
My concern is more about the approach that should be taken when distributing frameworks/xcframeworks. One approach I am thinking of using is checking the presence of {CFBundleName}.debug.dylib in the main bundle. Is this approach reliable? Do you suggest any other approach?
Topic:
Developer Tools & Services
SubTopic:
General
Tags:
Swift Packages
Frameworks
Debugging
App Binary
Does Bluetooth work in the background in iOS 26?
We are facing a DNS resolution issue with a specific ISP, where our domain name does not resolve correctly using the system DNS. However, the same domain works as expected when a custom DNS resolver is used.
On Android, this is straightforward to handle by configuring a custom DNS implementation using OkHttp / Retrofit. I am trying to implement a functionally equivalent solution in native iOS (Swift / SwiftUI).
Android Reference (Working Behavior) :
val dns = DnsOverHttps.Builder()
.client(OkHttpClient())
.url("https://cloudflare-dns.com/dns-query".toHttpUrl())
.bootstrapDnsHosts(InetAddress.getByName("1.1.1.1"))
.build()
OkHttpClient.Builder()
.dns(dns)
.build()
Attempted iOS Approach
I attempted the following approach :
Resolve the domain to an IP address programmatically (using DNS over HTTPS)
Connect directly to the resolved IP address
Set the original domain in the Host HTTP header
DNS Resolution via DoH :
func resolveDomain(domain: String) async throws -> String {
guard let url = URL(
string: "https://cloudflare-dns.com/dns-query?name=\(domain)&type=A"
) else {
throw URLError(.badURL)
}
var request = URLRequest(url: url)
request.setValue("application/dns-json", forHTTPHeaderField: "accept")
let (data, _) = try await URLSession.shared.data(for: request)
let response = try JSONDecoder().decode(DNSResponse.self, from: data)
guard let ip = response.Answer?.first?.data else {
throw URLError(.cannotFindHost)
}
return ip
}
API Call Using Resolved IP :
func callAPIUsingCustomDNS() async throws {
let ip = try await resolveDomain(domain: "example.com")
guard let url = URL(string: "https://(ip)") else {
throw URLError(.badURL)
}
let configuration = URLSessionConfiguration.ephemeral
let session = URLSession(
configuration: configuration,
delegate: CustomURLSessionDelegate(originalHost: "example.com"),
delegateQueue: .main
)
var request = URLRequest(url: url)
request.setValue("example.com", forHTTPHeaderField: "Host")
let (_, response) = try await session.data(for: request)
print("Success: (response)")
}
Problem Encountered
When connecting via the IP address, the TLS handshake fails with the following error:
Error Domain=NSURLErrorDomain Code=-1200
"A TLS error caused the secure connection to fail."
This appears to happen because iOS sends the IP address as the Server Name Indication (SNI) during the TLS handshake, while the server’s certificate is issued for the domain name.
Custom URLSessionDelegate Attempt :
class CustomURLSessionDelegate: NSObject, URLSessionDelegate {
let originalHost: String
init(originalHost: String) {
self.originalHost = originalHost
}
func urlSession(
_ session: URLSession,
didReceive challenge: URLAuthenticationChallenge,
completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void
) {
guard challenge.protectionSpace.authenticationMethod == NSURLAuthenticationMethodServerTrust,
let serverTrust = challenge.protectionSpace.serverTrust else {
completionHandler(.performDefaultHandling, nil)
return
}
let sslPolicy = SecPolicyCreateSSL(true, originalHost as CFString)
let basicPolicy = SecPolicyCreateBasicX509()
SecTrustSetPolicies(serverTrust, [sslPolicy, basicPolicy] as CFArray)
var error: CFError?
if SecTrustEvaluateWithError(serverTrust, &error) {
completionHandler(.useCredential, URLCredential(trust: serverTrust))
} else {
completionHandler(.cancelAuthenticationChallenge, nil)
}
}
}
However, TLS validation still fails because the SNI remains the IP address, not the domain.
I would appreciate guidance on the supported and App Store–compliant way to handle ISP-specific DNS resolution issues on iOS. If custom DNS or SNI configuration is not supported, what alternative architectural approaches are recommended by Apple?
I have a view inside a Swift Package that relies on an external Swift Package. My Preview Canvas breaks as soon as I use code from the external package:
import ComplexModule // From swift-numerics
import SwiftUI
struct MyView: View {
// Commenting out this line will make Previews work
let number: Complex<Double> = 123
var body: some View {
Text("Hello World")
}
}
#Preview {
MyView()
}
This is part of the error the preview emits:
== PREVIEW UPDATE ERROR:
GroupRecordingError
Error encountered during update group #33
==================================
| [Remote] JITError: Runtime linking failure
|
| Additional Link Time Errors:
| Symbols not found: [ _$sSd10RealModule0A0AAMc, _$s13ComplexModule0A0VMn, _$s13ComplexModule0A0V14integerLiteralACyxG07IntegerD4TypeQz_tcfC ]
|
| ==================================
|
| | [Remote] LLVMError
| |
| | LLVMError: LLVMError(description: "Failed to materialize symbols: { (static-MyTarget, { __replacement_tag$1 }) }")
Did anyone else see this before?
腾龙公司位置于南亚果敢老街双凤塔附近,---TL9655.com---腾龙公司成立于2015年9月11日,公司主要经营游戏,腾龙公司属于一家实体企业公司,下面是公司经理微信《tle584》 下面是公司浏览官网,可以把这个复制到浏览器粘贴打开,注册一个自己喜欢的账号,注册好以后再点击下面APP下载安装,然后输入自己的账号登录就可以舒畅游戏
When using a Swift Build Plugin, the generated code definitions are available through autocomplete, but it is currently not possible to view them directly in Xcode using Option+click.
An example of such a plugin is swift-openapi-generator.
According to information from "Meet Swift Package plugins" from WWDC22
the generated code is stored with other build artifacts.
It would be immensely helpful if there was support for viewing these intermediate files in read-only mode using Option+click. Currently, I have to resort to opening these files through Finder, or opening the project in VS Code where viewing the generated files using Cmd+click works without a problem.
Am I missing something? If not, it seems like a big oversight that this is not supported to the same extent in Apple's own tools.
in my xcode project, i created a new package by going through File > New > Package, just like they said in https://developer.apple.com/documentation/xcode/organizing-your-code-with-local-packages
I have a package, but the problem is, whenever I made any changes in the package's source code, it never showed in the main project. I can import the package just fine, but the package does not show anything. no added apis, functions, nothing.
Im using Xcode 26.0.1
Hi all...
The app I'm building is not really a beginner level test app, it's intended to be published so I want everything to be done properly while I'm both learning and building the app. I'm new to swift ecosystem but well experienced with python and JS ecosystems.
These two models are causing my app to crash
@Model
final class CustomerModel {
var id: String = UUID().uuidString
var name: String = ""
var email: String = ""
var phone: String = ""
var address: String = ""
var city: String = ""
var postalCode: String = ""
var country: String = ""
@Relationship(deleteRule: .nullify)
var orders: [OrderModel]?
@Relationship(deleteRule: .nullify)
var invoices: [InvoiceModel]?
init() {}
}
@Model
final class OrderModel {
var id: String = UUID().uuidString
var total: Double = 0
var status: String = "processing"
var tracking_id: String = ""
var order_date: Date = Date.now
var updated: Date = Date.now
var delivery_date: Date?
var active: Bool = true
var createdAt: Date = Date.now
var items: [OrderItem]?
@Relationship(deleteRule: .nullify)
var invoice: InvoiceModel?
@Relationship(deleteRule: .nullify)
var customer: CustomerModel?
init() {}
}
both referenced in this model:
@Model
final class InvoiceModel{
var id: String = UUID().uuidString
var status: String = "Pending"
var comment: String = ""
var dueDate: Date = Date.now
var createdAt: Date = Date.now
var updated: Date = Date.now
var amount: Double = 0.0
var paymentTerms: String = "Once"
var paymentMethod: String = ""
var paymentDates: [Date] = []
var numOfPayments: Int = 1
@Relationship(deleteRule: .nullify, inverse: \OrderModel.invoice)
var order: OrderModel?
@Relationship(deleteRule: .nullify)
var customer: CustomerModel?
init() {}
}
This is my modelContainer in my index structure:
@main
struct Aje: App {
var appContainer: ModelContainer = {
let schema = Schema([UserModel.self, TaskModel.self, SubtaskModel.self, InventoryModel.self, SupplierModel.self])
let config = ModelConfiguration(schema: schema, isStoredInMemoryOnly: false, allowsSave: true, groupContainer: .automatic, cloudKitDatabase: .automatic)
do{
return try ModelContainer(for: schema, configurations: [config])
}catch{
fatalError("An error has occured: \(error)")
}
}()
var body: some Scene {
WindowGroup {
ContentView()
}
.modelContainer(appContainer)
}
}
This works fine but the below after adding the problematic models crashes the app unless CloudKit is disabled
@main
struct Aje: App {
var appContainer: ModelContainer = {
let schema = Schema([UserModel.self, TaskModel.self, SubtaskModel.self, InventoryModel.self, SupplierModel.self, InvoiceModel.self, OrderModel.self, CustomerModel.self])
let config = ModelConfiguration(schema: schema, isStoredInMemoryOnly: false, allowsSave: true, groupContainer: .automatic, cloudKitDatabase: .automatic)
do{
return try ModelContainer(for: schema, configurations: [config])
}catch{
fatalError("An error has occured: \(error)")
}
}()
var body: some Scene {
WindowGroup {
ContentView()
}
.modelContainer(appContainer)
}
}
Topic:
Developer Tools & Services
SubTopic:
Xcode Cloud
Tags:
Swift Packages
CloudKit
SwiftUI
SwiftData
Where are the instructions for this process
Hello - I’m the Account Holder for an individual Apple Developer Program account. I’m working with freelance junior developers who are building my app in React Native mainly in TypeScript (.tsx) with some JavaScript, with code in GitHub. The app currently runs in Expo Go now.
I’ve been directed to this forum for step-by-step guidance. Specifically I need clear, sequential instructions I can give my developers (and what I personally must do on my Mac) so they can produce a properly signed iOS build for TestFlight (internal testing), and Upload that build to App Store Connect and then submit the release to the App Store.
Context:
This is an individual developer account (not an organization).
I am the only person with a Mac. I added them as developers but was told I need to be the one to upload the final build (is this true, and if so, what do they send me to do that, and when they send it to me, can you please tell me exactly what I need to do from there?)
I was told about Swift Playground, possible SwiftUI conversion if needed, APK file, and using my Xcode for final submission, but not sure what to make of this that will get it on TestFlight from the current React Native.
What I would like to ask for help with is a concise, step-by-step checklist (including exact menu names / commands or tools like EAS Submit, Transporter, or Xcode) of the developers' steps and my admin/account holder steps, so I can hand it to the developers and make sure nothing is missed to get on TestFlight.
I’m on a tight timeline, so any clear, detailed guidance would be extremely appreciated.
Thank you so much. I have looked everywhere and cannot find a step-by-step!
I need to paste a string to the findNavigator of a TextEditor
I just updated to Xcode 26 and some of my Swift Packages have been getting strange build errors that I have not been able to resolve. When I try to build my Swift Package in Xcode I get the following error
Module dependency cycle: 'UIKit.swiftmodule -> .swiftmodule -> SafariServices.swiftmodule -> UIKit.swiftmodule'
It seems like it is related to the change in Xcode 26 that states "Swift explicit modules will be the default mode for building all Swift targets". I see that you can disable this with the build setting SWIFT_ENABLE_EXPLICIT_MODULES=NO, but I don't see a way to do this in Package.swift, as you can't include value assignments like this .define("SWIFT_ENABLE_EXPLICIT_MODULES=NO").
Our private SPM repos use CI/CD and so we need to be able to build them independently of any use in a project. I would appreciate any help on fixing our Swift Package builds in Xcode 26, thanks!
We have the following step before running any tests on CI machine:
xcrun simctl shutdown all && xcrun simctl erase all
It was working perfectly before Xcode 26.1.
On Beta 3 it was doing it for 15 min every time.
When updated to RC1, the tests with cached build are fast (clean goes up to 10 sec), but the package tests clean is still going up to 15 min every time.
We did
xcrun simctl runtime dyld_shared_cache update --all
as advised but it's helping only temporarily. Is this going to be fixed in the official release?
Good day,
I've uploaded a build to TestFlight, but received an automated response with the following error:
ITMS-90426: Invalid Swift Support - The SwiftSupport folder is missing. Rebuild your app using the current public (GM) version of Xcode and resubmit it.
Our project started in Objective-C and have mixed swift class and pods. The last uploaded build without any automated response was Nov 8, 2023.
I'm using XCode Version 26.0.1 (17A400). I've tried every way i found in internet and i'm not able to find any solution for this.
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES
use_frameworks! :linkage => :dynamic (in pods)
We would appreciate any assistance in clarifying why this issue is occurring and how we should proceed to address it. Your guidance would mean a lot.
Thank you.
Topic:
App Store Distribution & Marketing
SubTopic:
TestFlight
Tags:
Swift Packages
App Store
iOS
App Submission
Xcode SPM (Swift Package Manager) Error
I added the "Apple App Store Server Swift Library" library to Xcode using Swift Package Manager.
Both the project and target are set to iOS 14 or higher.
However, when I build after adding the library, an error occurs with the library.
A message appears stating that the target is set to iOS 12.
I'm using Xcode 26.0.1.
Even after adding it to all my projects, the build continues with the same error.
I've tried building the library from version 1.0.0 to the latest version, but the same error persists.
Even after completely cleaning the project and running it, the same error persists.
Does anyone know how to fix this?
Hello,
I'm trying to remove a localization from a String Catalog in a Swift Package. How can I do that?
I tried to remove the file and create a new one, but all the languages are back. The only place where I've found a reference to the languages is in Package/.swiftpm/xcode/package.xcworkspace/xcuserdata/user.xcuserdatad/UserInterfaceState.xcuserstate
But I don't know how to edit this file to remove a language.
Thank you,
Axel
Hello,
I’ve created a custom SDK from my iOS application to be integrated into another app. The SDK depends on Google Maps and payment gateway libraries.
If I exclude these third-party libraries from the SDK, I encounter multiple errors. However, if I include them, the host app throws errors due to duplicate dependencies, since it already integrates the same libraries.
I understand that third-party dependencies can be downloaded separately by adding them through Swift Package Manager (SPM). However, the issue is that if I exclude these dependencies from my SDK, I get compilation errors wherever I’ve used import GoogleMaps or similar statements in my code.
Could you please guide me — or share documentation — on the correct approach to create an SDK that excludes third-party libraries?
How can you distribute an XCFramework via Swift Package Manager when it has dependencies on other Swift packages? We accomplished this with CocoaPods in order to distribute our closed source SDK that has dependencies, but need to migrate to SPM. Note none of the types from the dependencies are used as part of our module’s public interface - usage is purely internal.
I’ve made a lot of progress following these steps for a simple example:
Create Framework Project
Create a new iOS Framework project in Xcode and name it WallpaperKit
In the project settings select the target and verify in Build Settings that Build Libraries for Distribution is Yes then set Skip Install to No
Create a new UIViewController subclass, name it WallpaperPreviewViewController, make it public, and add some functionality to it to show a UIImageView
Add a new Package Dependency in the project settings, for this example we’ll use https://github.com/onevcat/Kingfisher, and specify exact version 8.5.0
Add internal import Kingfisher and use it in WallpaperPreviewViewController to download and show an image from the web
Close the WallpaperKit project
Create Hosting App Project (this makes it easier to develop the framework functionality and test it in an app with Xcode building both in the same workspace)
Create a new iOS app project and name it WallpaperApp
Create a new workspace named WallpaperApp
Close the WallpaperApp project
Drag and drop WallpaperApp.xcodeproj into the workspace’s sidebar
Drag and drop WallpaperKit.xcodeproj into the workspace’s sidebar
Switch the scheme to WallpaperKit and build
Select WallpaperApp project, then with WallpaperApp target selected, in the General tab under Frameworks, Libraries, and Embedded Content, click + and add WallpaperKit.framework
In ViewController.swift, import WallpaperKit and add functionality to present an instance of WallpaperPreviewViewController
Run the app and verify it works
Create XCFramework
In Terminal, cd into WallpaperKit and run xcodebuild archive -scheme WallpaperKit -configuration Release -destination 'generic/platform=iOS' -archivePath './build/WallpaperKit.framework-iphoneos.xcarchive' SKIP_INSTALL=NO BUILD_LIBRARIES_FOR_DISTRIBUTION=YES DEFINES_MODULE=YES
Run xcodebuild archive -scheme WallpaperKit -configuration Release -destination 'generic/platform=iOS Simulator' -archivePath './build/WallpaperKit.framework-iphonesimulator.xcarchive' SKIP_INSTALL=NO BUILD_LIBRARIES_FOR_DISTRIBUTION=YES DEFINES_MODULE=YES
Run xcodebuild -create-xcframework -framework './build/WallpaperKit.framework-iphonesimulator.xcarchive/Products/Library/Frameworks/WallpaperKit.framework' -framework './build/WallpaperKit.framework-iphoneos.xcarchive/Products/Library/Frameworks/WallpaperKit.framework' -output './build/WallpaperKit.xcframework'
Open the build folder and retrieve the XCFramework
Create Swift Package
Create a new package in Xcode, select Library, and name it WallpaperKitDist
Drag and drop WallpaperKit.xcframework into Sources
Create a new directory in Sources called WallpaperKitDependencies
Create a new Swift file in WallpaperKitDependencies called WallpaperKitDependencies (SPM requires a Swift file to recognize WallpaperKitDependencies as a valid target and fetch dependencies)
Open Package.swift and change it to
import PackageDescription
let package = Package(
name: "WallpaperKit",
platforms: [
.iOS(.v18)
],
products: [
.library(
name: "WallpaperKit",
targets: ["WallpaperKit", "WallpaperKitDependencies"]
),
],
dependencies: [
.package(
url: "https://github.com/onevcat/Kingfisher.git",
exact: "8.5.0"
)
],
targets: [
.binaryTarget(
name: "WallpaperKit",
path: "./Sources/WallpaperKit.xcframework"
),
.target(
name: "WallpaperKitDependencies",
dependencies: [
"Kingfisher"
],
path: "./Sources/WallpaperKitDependencies"
)
]
)
Create Test App (to simulate a third-party app using the package)
Create a new iOS app project and name it TestApp
Add a new Local package selecting the WallpaperKitDist directory that contains Package.swift
Import WallpaperKit and use it to present a WallpaperPreviewViewController
This works! Though the console logs
objc[39953]: Class _TtC10KingfisherP33_6AA794C9C370CDB07604B4D8B99AEAA312BundleFinder is implemented in both /Users/Name/Library/Developer/Xcode/DerivedData/TestApp-capvhjiqxrdgdnbevpkajicnjpcs/Build/Products/Debug-iphonesimulator/WallpaperKit.framework/WallpaperKit (0x100e8bbf8) and /Users/Name/Library/Developer/CoreSimulator/Devices/E0AF13C2-874C-47B9-B864-72AF3E4D5D4B/data/Containers/Bundle/Application/AF32011A-92E7-4E26-9A97-9F0C25C07863/TestApp.app/TestApp.debug.dylib (0x101a543b0). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
I thought using internal import Kingfisher (or @_implementationOnly import Kingfisher) would have resolved this, but seems to make no difference compared to just import Kingfisher. I suspect it might not be an issue as long as the Kingfisher version number specified in the distribution Package.swift matches the version used in the framework project (and the app does not add a different version as a dependency), but not positive.
Can these warnings be resolved, or is it not a concern in this setup? Is this the best solution to distribute an XCFramework via Swift Package Manager that has dependencies on other Swift packages for now or is there a better approach? Thanks!