I am trying to add an XCUITest target to an existing application. When I try to run the tests, I get the error "Invalid configuration: MyProjectUITests sets both USES_XCTRUNNER and either TEST_HOST or RUNTIME_TEST_HOST".
I have seen information stating that it might be because I have multiple apps built from different build configurations in the same scheme, but I could not resolve the issue with any of the suggestions I saw.
I've attached a screenshot of the error message and a link to a project stripped down to just the existing configuration to help with diagnosing this issue. I would really love to be able to get some UI tests running.
My Project
Xcode
RSS for tagBuild, test, and submit your app using Xcode, Apple's integrated development environment.
Posts under Xcode tag
200 Posts
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
No coverage is generated for private xxxx.framework, but tests are running under this framework.
This was perfectly working before and started giving this error after updating to Xcode 16.
Failed to generate coverage for target xxxx.framework at paths (
"/Users/xxxxxx/Desktop/xcode/Debug-iphonesimulator/Common/xxxxxx.framework/xxxx"
):
No object file for requested architecture
The operation couldn’t be completed. (XCTHCoverageReportGenerationErrorDomain error 2.).
(Underlying Error: No object file for requested architecture)
I'm wondering if the tagging functionality which was added for Swift testing will be added to XCTest for UITests anytime soon.
I have a macOS application built via command line (xcodebuild) using Xcode 16.1. Developed on ARM but end user is on Intel (same macOS 15.1).
App crashed and they sent me a .IPS dump.
From what MacGPT tells me:
Reading an IPS (Incident Processing System) file from a macOS crash report in Xcode isn’t as straightforward as with iOS device logs.
I can open the dump using Console. I see the IPS dump is partially symbolicated.
Line in the dump says: Meteorologist 0x103e0348f 0x103d88000 + 504975
Referencing this article: Adding identifiable symbol names to a crash report | Apple Developer Documentation
I run this command and see the same UUID for x86_64 as in the dump.
dwarfdump --uuid /Users/ed/meteorologist/trunk/Build/Meteorologist.xcarchive/dSYMs/Meteorologist.app.dSYM/Contents/Resources/DWARF/Meteorologist
I run this command:
atos -arch x86_64 -o /Users/ed/meteorologist/trunk/Build/Meteorologist.xcarchive/dSYMs/Meteorologist.app.dSYM/Contents/Resources/DWARF/Meteorologist -l 0x103d88000 0x103e0348f
And it says: fg: no current job
Suggestions for what I’m missing?
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags:
Xcode
Universal Apps
Debugging
Xcode Sanitizers and Runtime Issues
I need to read results of a test in Xcode post-action of Test.
So the script that runs after tests contains
SUMMARY=$(xcrun xcresulttool get test-results summary --path $RESULT_FILE 2>> "$LOGS")
If I run my script from terminal, everything is ok but if I launch tests and the post-action is executed, I got
Warning: unknown environment variable SWIFT_DEBUG_INFORMATION_FORMAT
Warning: unknown environment variable SWIFT_DEBUG_INFORMATION_VERSION
Warning: unknown environment variable SWIFT_DEBUG_INFORMATION_FORMAT
Warning: unknown environment variable SWIFT_DEBUG_INFORMATION_VERSION
Error: Failed to create a new result bundle reader, underlying error: failed to read metadata with underlying error (type: FileSystemError: 3 - [:] - The operation couldn’t be completed. (MinimalTSCBasic.FileSystemError error 3.)
Usage: xcresulttool <subcommand>
See 'xcresulttool --help' for more information.
It might be that the environment set by Xcode is missing something but I cannot figure out what, any idea?
Hi Team,
I'm trying to set firebase flag as a launch arguments based on user choice and it is working fine in iOS 17 devices whereas not in iOS 18
Here is the sample
if true {
var arguments = ProcessInfo.processInfo.arguments
arguments.append("key")
ProcessInfo.processInfo.setValue(arguments, forKey: "arguments")
}
We are seeing a crash on Big Sur 11.7.10 after switching the build system to use Xcode 15
Excerpt from crash
Time Awake Since Boot: 1700 seconds
System Integrity Protection: enabled
Crashed Thread: 0
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Termination Reason: DYLD, [0x4] Symbol missing
Application Specific Information:
dyld: launch, loading dependent libraries
Dyld Error Message:
Symbol not found: __ZNSt3__17codecvtIDiDu11__mbstate_tE2idE
Referenced from: /Applications/SecureworksTaegis.app/Contents/MacOS/com.secureworks.agent.daemon.app/Contents/MacOS/com.secureworks.agent.daemon
Expected in: /usr/lib/libc++.1.dylib
in /Applications/SecureworksTaegis.app/Contents/MacOS/com.secureworks.agent.daemon.app/Contents/MacOS/com.secureworks.agent.daemon
Build system has the following specs :
ProductName: macOS
ProductVersion: 14.3.1
BuildVersion: 23D60
Xcode 15.2
Build version 15C500b
CMAKE PROPS
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_EXTENSIONS OFF)
set(CMAKE_OSX_DEPLOYMENT_TARGET 11.0)
Hello everyone,
I’m working on adding a Safari extension as an application extension to an iOS app created using Capacitor (generated from a React app). My goal is to bundle the Safari extension within the Capacitor app, allowing it to serve as a companion app for the extension. However, I’ve run into issues where the extension does not show up in Safari's extension settings when I run the app on a device or simulator.
Here's an overview of what I’ve done so far:
I initially used Capacitor’s command line tools to generate the iOS app from my React project. This app runs fine on its own.
To add the Safari extension, I’m not developing a platform-specific extension from scratch; instead, I used the Xcode command line to convert a Chrome extension to a Safari iOS extension. The converted extension functions correctly if paired with the default Swift app that comes with the conversion.
Right now, I effectively have two products:
The base Capacitor app (without the extension), which I want as my main app.
The standalone Safari extension bundled with the Swift app (from the conversion process).
My question is: How can I merge these two products so that the Capacitor app becomes the companion app for the Safari extension, allowing the extension to show up in Safari's settings? Are there specific configurations I should adjust in Xcode or within the manifest files to make this work seamlessly?
Any guidance or best practices from others who have integrated Safari extensions into non-Xcode-based projects would be much appreciated!
Thank you!
Hello,
WatchOS crown not producing any effects in Preview window of Xcode. I tried lower version (10.5) and currently using 11.0 . I tried different faces, sizes, models but none is working, even though it rotates beautifully in preview.
Thanks,
hi
i want create a commande line tool for arm64 et intel x86-64
Xcode 16 macbook pro M3
my setting :
and
but my application compile only for arm64
who can explain to me ?
The data displayed about a child’s apps can be outdated (DeviceActivityReport), leading to misinformation for the user. When I access the “Screen Time” section (for child in the parent device) in the iPhone settings, I see there is an update functionality to force load the actual data.
I have tried various workarounds, such as attempting to force an update on the child’s device to call DeviceActivityReport and opening system settings, but none of these have been successful :(
How can I implement something similar? Is there a way to force update this data ?
Topic:
App & System Services
SubTopic:
General
Tags:
Xcode
Device Activity
Family Controls
Screen Time
APP有一個UI是輸入數字的TextField,每輸入一個數字會自動跳至下一個TextField,總共有6個Textfield,但是用戶輸入時,畫面顯示的數字會自動縮小,並取不到Textfield的值,非常奇怪!!
Hello community,
I'm an iOS developer from VW group, I was doing some proof of concepts around an automaker app, and I've found a big blocker. When I was trying to summon a keyboard, it wasn't displayed.
So is it even possible?
Do I have to do some workaround with Carplay templates in order to be able to have the native keyboard from Carplay, or is there a special component that I need to introduce in my code to summon the keyboard?
Thank you very much.
David Cosialls.
Hi everyone,
I'm trying to find out if there's a way to mock Screen Time for a specific app (either on a real device or in a simulator). Specifically, I need to set the usage time of an app to something like 15 minutes. I'm not looking to alter the total Screen Time, just the usage time for a single app.
Currently, I'm manually keeping the app open for 15 minutes before I can start testing to see if the desired behavior occurs, but this process is slow and frustrating. Unfortunately, I can't reduce the 15-minute threshold, as Apple doesn't allow it for this particular use case.
Any advice or solutions would be greatly appreciated!
When I try to delete an iPhone 16 Pro iOS 18.1 Simulator in XCode 16.1, I get an error message "“data” couldn’t be moved because you don’t have permission to access “Deleting-8366D3CC-37EC-49C0-8674-0599BCE1DA12”.". I had that same issue with iOS 18.0 Simulator but never with previous versions (17.5).
Note that I'm stuck using the iOS 18.1 Simulator because iCloud synchronization is paused (potentially due to low data mode).
And I cannot use iOS 18.0 Simulator as well because unit tests run hangs for some other mysterious reason.
The fallback to iOS 17.5 Simulator is not satisfactory.
When I run the following code in XCode iOS Simulator on Safari (connecting via Safari DevTools):
navigator.serviceWorker.ready.then((reg) => reg.pushManager.subscribe({ userVisibleOnly: true, applicationServiceKey: "..." }).then((sub) => console.log(sub.toJSON())))
I get the response:
{ keys: { p256dh: "", auth: "" } }
But I'm expecting p256dh and auth (and endpoint) to be filled out. Why is it not?
Hi there,
when I run any app on the Xcode 16/16.1 with iOS/tvOS 18/18.1,
it generates a crash on the AccessibilityControlsExtension process.
0x1048b8000 - 0x10493bfff dyld (*) <6beafde4-b011-3e47-8aae-4d7b6e4bb7e8> /usr/lib/dyld
0x1047fc000 - 0x104803fff com.apple.AccessibilityUIServer.AccessibilityControlsExtension (1.0) <a67e159b-253d-306c-b6fb-dd3fec38bd0f> /Volumes/VOLUME/*/AccessibilityUIServer.app/PlugIns/AccessibilityControlsExtension.appex/AccessibilityControlsExtension
If run in Catalist mode - there are no crash reports.
I also made a clean install of macOS 15.1 + Xcode and received that error again.
Device: Mac15,13
Any suggestions on how to fix it?
Full crash log in attach.
AccessibilityControlsExtension-crash.log
When running a simple C++ OpenGL project in Xcode, multiple instances of the program are created and launched by Xcode when I build and run...I am not sure why it happens, does anyone know how can I stop this?
My macos update automatically and the new macos SDK are not fit for my program, so how to use a lower version macos SDK?
And I have another problem, once I installed Xcode, the SDK will be set path to Xcode path, also I have a command line path which is /Library/Developer/CommandlineTools. In this path, there is also a SDKs directory which contains some different versions of macos SDK? How to set a default SDK path?
func setupUDPSocket() {
stopSearch()
udpSocket = GCDAsyncUdpSocket(delegate: self, delegateQueue: DispatchQueue.main)
do {
try udpSocket?.bind(toPort: 4012)
try udpSocket?.beginReceiving()
try udpSocket?.joinMulticastGroup("239.255.255.250")
} catch let error {
DispatchQueue.main.async {
print(Thread.current)
print(error)
print(error)
}
}
}
private func search() {
guard let udpSocket = udpSocket else {
print("not set udpSocket")
stopSearch()
return
}
let message = "M-SEARCH * HTTP/1.1\r\n" +
"HOST: 239.255.255.250:1900\r\n" +
"MAN: \"ssdp:discover\"\r\n" +
"MX: 3\r\n" +
"ST: ssdp:all\r\n" +
"\r\n"
let data = message.data(using: .utf8)!
udpSocket.send(data, toHost: "239.255.255.250", port: 1900, withTimeout: -1, tag: 0)
}
This is my send SSDP code, my project was inited in Objective-C, recently I update xcode to 16, I get Error Domain=NSPOSIXErrorDomain Code=65 "No route to host", when I send UPD data in iOS 18, but iOS 17 is ok.
Even I found, if I init a new project in Swift, this bug is disappear.
Topic:
App & System Services
SubTopic:
Networking
Tags:
App Tracking Transparency
Xcode Server
Xcode
Network