Since one of the last updates of XCode, there are two very annoying bugs in the simulator that just don't get fixed. What's going on Apple? You kill my productivity.
There is a red bar reading "rdar" and some numeric string at the top. You can get rid of it by going to Settings -> Developers -> Zoom -> Larger Text (then change it back). Took a while to find that.
I have a German laptop with a QWERTZ keyboard layout. Now when I type, it somehow sends keys from an US keyboard to the simulator. Since I don't have the labels, I don't know what the hell I'm typing. Very frustrating.
Please fix this.
Xcode
RSS for tagBuild, test, and submit your app using Xcode, Apple's integrated development environment.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
I've added NSAlarmKitUsageDescription to Info.plist and InfoPlist.xcstrings.
The localized string is being used when I run the app, but Xcode is marking the string as "stale" in InfoPlist.xcstrings.
This doesn't occur for any of the other UsageDescription strings in our app, such as NSPhotoLibraryUsageDescription and NSSiriUsageDescription.
This occurs in both Xcode 26.2 and Xcode 26.3 RC.
Is this a known issue? Should I just mark the string as being managed "Manually" instead of "Automatically" to make the warning go away?
Topic:
Developer Tools & Services
SubTopic:
Xcode
I'm importing SwiftUI, Foundation and Charts into an iOS app I'm writing in Swift in Xcode Playgrounds and am getting this error:
error: Couldn't look up symbols:
protocol witness table for Foundation.Date : Charts.Plottable in Charts
the code looks like this in just two example files:
file 1, the view
import Foundation
import SwiftUI
import Charts
import PlaygroundSupport
struct FirstChart_WithDates: View {
private let data = ChartDateAndDoubleModel.mockData(months: 3)
var body: some View {
Chart(data) { item in
BarMark(
x: .value("Label", item.date, unit: .month),
y: .value("Value", item.value)
)
}
.padding()
.aspectRatio(1, contentMode: .fit)
.dynamicTypeSize(.accessibility1)
ChartDateAndDoubleModelView(data: data)
}
}
struct ChartDateAndDoubleModelView: View {
var data: [ChartDateAndDoubleModel]
var body: some View {
VStack {
HeaderRowView(texts: ["date", "value"])
ForEach(data) { datum in
HStack {
Text(datum.date.formatted(date: .abbreviated, time: .omitted))
.frame(maxWidth: .infinity)
// TODO: Format for 2 decimal places.
Text(datum.value, format: .number.precision(.fractionLength(2)))
.frame(maxWidth: .infinity)
}
}
}
.padding(.bottom, 8)
.overlay(.quaternary, in: .rect(cornerRadius: 8).stroke())
.padding()
}
}
struct HeaderRowView: View {
var texts: [String]
var body: some View {
HStack(spacing: 2.0) {
ForEach(texts, id: \.self) { text in
Text(text)
.padding(4)
.frame(maxWidth: .infinity)
.background(.quaternary)
}
}
.font(.headline)
.mask(UnevenRoundedRectangle(topLeadingRadius: 8, topTrailingRadius: 8))
}
}
and file 2, the model:
import Foundation
import SwiftUI
import Charts
// ChartDateAndDoubleModel.swift
//
//
// Created by Michael Isbell on 2/10/26.
//
public struct ChartDateAndDoubleModel: Identifiable {
public let id = UUID()
public let date: Date
public let value: Double
}
public extension ChartDateAndDoubleModel {
static func mockData(months: Int = 5) -> [ChartDateAndDoubleModel] {
var data: [ChartDateAndDoubleModel] = []
let calendar = Calendar(identifier: .gregorian)
let currentDate = Date()
for month in 0..<months {
//add month to current date and append to data
data.append(
ChartDateAndDoubleModel(
date: calendar.date(byAdding: .month, value: month, to: currentDate)!,
value: Double.random(in: 0...1000)
)
)
}
return data
}
}
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags:
Foundation
Swift Playground
Playground Support
Swift Charts
Hi,
I’m seeing an unexpected change in how XCTFail behaves in UI tests after updating Xcode.
I use the following helper method:
`func waitForExistance(file: StaticString, line: UInt) -> Self {
if !(element.exists || element.waitForExistence(timeout: Configuration.current.predicateTimeout)) {
XCTFail("couldn't find element: \(element) after \(Configuration.current.predicateTimeout) seconds",
file: file,
line: line)
return self
} else {
return self
}
}`
In Xcode 16.4, this worked as expected:
– when an element wasn’t found, XCTFail was triggered, but the test continued running, allowing my retry logic to execute.
After updating to Xcode 26.1 / 26.2 - the test now immediately aborts after XCTFail, without executing the next retry.
The logs show:
`t = 113.22s Tear Down
t = 113.22s Terminate com.viessmann.care:81789
*** Assertion failure in -[UITests.Tests _caughtUnhandledDeveloperExceptionPermittingControlFlowInterruptions:caughtInterruptionException:whileExecutingBlock:], XCTestCase+IssueHandling.m:273
Test Case '-[UITests.Tests test_case]' failed (114.323 seconds).
Flushing outgoing messages to the IDE with timeout 600.00s
Received confirmation that IDE processed remaining outgoing messages`
It looks like XCTFail in Xcode 26 is now treated as an unhandled developer exception, which stops the test execution immediately, even when it’s called inside a helper method. This was not the case in earlier versions.
My questions:
Is this a regression in XCTest?
Or an intentional change in how XCTFail behaves in newer Xcode versions?
Should failures now be reported differently (e.g., using record(.init(type: .assertionFailure, …))) if I want to continue the test instead of aborting it?
I would like to restore the previous behavior where the failure is logged without terminating the entire test, so my retry mechanism can still run.
Has anyone else run into this after upgrading?
Thanks in advance!
If you’d like, I can also add recommended workarounds that actually work with Xcode 16.4 (e.g., replacing XCTFail with a non-terminating issue record).
I'm having troubles converting my string catalog to symbols because for partly translated languages there is no fallback to the reference language. Let me give you an example.
Example
Assume an app that supports two languages: English and Japanese. The app is very simple and has only two strings, using symbols in a String Catalog:
Key: .helloWorld → “Hello World!”
Key: .info → “Information”
Case 1: No Japanese translations
If I launch the app in Japanese and neither string is translated, English is used as a fallback.
The UI shows:
“Hello World!”
“Information”
This is exactly what I would expect.
Case 2: Only one string translated
Now assume I translate only one string into Japanese:
.helloWorld → “こんにちは世界”
When I launch the app in Japanese now:
.helloWorld correctly shows “こんにちは世界”
.info shows info, not “Information”
So instead of falling back to English, the key is displayed.
This issue does not pop up when I don't use symbols. Because then, my SwiftUI Text elements contain the English ideal text as a (kind of) key.
I assume for commercial apps all strings are always translated into all supported languages. But this is not the case for apps where translations happens through crowd translations. Check the following link. There you will see that only English (reference language) and German (my native language) are 100% translated. Others will follow over time.
https://poeditor.com/join/project/J2Qq2SUzYr
For now, I guess I'll have to avoid symbols. Or is there a better way to handle this?
When launching my app (and even a bran new app) on the simulator in debug, the app is installed on the simulator, launched but freezed. Even with a basic hello world app. Any idea?
I can only see 18.2 here:
https://developer.apple.com/download/all/?q=simulator%20runtime%20ios
But my Xcode is 26.2 and I need off-line installation for my laptop (WiFi is playing up).
Topic:
Developer Tools & Services
SubTopic:
Xcode
Hi there,
I just re-install 26.2, but I got many issues regarding to SwiftUI's components.
How can I fix it? Do I need download or install something else?
I use Claude Code with AWS Bedrock models. I see that Xcode 26.3 has a way to add model providers but I don't see the URL or API key in use with Claude Code. Is it possible, or are the protocols different and I have to convince my company to pay for an Anthropic subscription
Topic:
Developer Tools & Services
SubTopic:
Xcode
Hello!
I've been trying to automate tests using Appium/XCUITests in a React Native APP, but I'm finding many blockers.
They are related to the amount of nested elements in the "DOM" in which the XCUItest can not go deeper to get all the elements we need.
snapshotMaxDepth -> The XCUITest does not support more than 60 value, otherwise it returns the following error:
Got response with status 404: {"value":{"error":"stale element reference","message":"The previously found element "Application 'xyz.xxx.xxx'" is not present in the current view anymore. Make sure the application UI has the expected state. Original error: Error kAXErrorIllegalArgument getting snapshot for element <AXUIElementRef 0x600003aaf750> {pid=95967} {uid=[ID:1 hash:0x0]}","traceback":"(\n\t0 CoreFoundation 0x00007fff20405604 __exceptionPreprocess + 242\n\t1 libobjc.A.dylib 0x00007fff201a4a45 objc_exception_throw + 48\n\t2 WebDriverAgentLib 0x000000010a3caa53 -[XCUIElement(FBUtilities) fb_takeSnapshot] + 723\n\t3 WebDriverAgentLib 0x000000010a3cad07 -[XCUIElement(FBUtilities) fb_snapshotWithAttributes:maxDepth:] + 183\n\t4 WebDriverAgentLib 0x000000010a37baea +[FBXPath writeXmlWithRootElement:indexPath:elementStore:includedAttributes:writer:] + 778\n\t5 WebDriverAgentLib 0x000000010a37b12c +[FBXPath xmlRep...
But if I inform less than 60, the XCUITest is not able to get all the elements we need to automate:
There are many threads about this, all of them the issue is in the XCUITest:
https://github.com/appium/appium/issues/14825
https://discuss.appium.io/t/handling-staleelementreferenceexception/35095/11
https://github.com/appium/appium/issues/18085
https://discuss.appium.io/t/error-in-appium-desktop-refreshing-source-after-adding-snapshotmaxdepth-greater-than-62/34058
https://stackoverflow.com/questions/74235441/appium-cant-reach-elements-in-ios-source-tree-they-are-too-deep-works-fine-in
Tested all possible solutions suggested in the threads, but I will have the issue.
Hello! I'm using the new Xcode 26.3 RC and it's new MCP server:
However, I am repeatedly prompted to give access to Codex (both the new macOS app and the CLI).
And I'm seeing duplicates in the Xcode dropdown:
It's pretty blocking in my workflow as I have to keep Allowing over and over again.
Topic:
Developer Tools & Services
SubTopic:
Xcode
I am trying to create a .swiftpm for the swift student challenge and the only option that I see in the new menu is playground how do I make the .swiftpm?
Under Xcode -> Settings -> Intelligence -> Account it states "Not Signed In" An anthropic api key or claude.ai account is N/A
Is pretty sparse in actual details.
https://developer.apple.com/documentation/xcode/setting-up-coding-intelligence
Related:
https://developer.apple.com/forums/thread/814595
I'm trying to run my app on my iPhone and XCode is unable to detect it.
Versions (as of time of writing, these are all the latest versions)
XCode: 15.0.1
iOS: 17.1.2
macOS: Sonoma 14.1.2
What I've tried
Updating all hardware to the latest versions.
Restarting all hardware.
Clearing cache/derived data.
Using different USBC ports/cables.
Using the XCode 15.1-Beta 3 (the latest beta)
Clearing trusted computers and re-trusting
Disabling Multipath Networking (solution for someone else on the dev forums)
Creating a brand new xcode project.
Disabling all wifi/bluetooth and reconnecting
Using different wifi networks
Calling mac support (they directed me back here)
Scouring forums
What happens
I start by disconnecting my phone from my computer, clear trusted computers, restart xcode, and start (basically) from a completely blank slate. First I open XCode to my project. Then I connect my iPhone via USBC. I see that XCode says "iPhone not eligible while pairing in progress" (or something like that). I see on my phone that I must trust this computer, I hit trust, I enter my phone's passcode, then that disappears on my phone, and in XCode the message about eligibility disappears. I then click on the device selector to choose between either a simulator or a hardware device and under hardware I only see a message that says "No eligible devices connected to my mac". If I open the "Manage Run Destinations" organizer I see all the simulators there in the simulators tab, but when I go to the Devices tab, I see nothing. Sometimes when I go through this process, I can get a banner to appear up top, but still no device shows up on the left. The banner will show me that it is indeed my iPhone, but it will be missing information like "Serial Number" or "Capacity". Here's a screenshot of what I see. Keep in mind, this banner up top does not always show up when I go through this process.
iPhone CAN be detected on my other laptop
When I do this exact same thing on my other laptop, everything works just fine. Here are the specs I'm running on that laptop.
(using the same cable/wifi network/etc)
XCode 15.0.1
macOS: Ventura 13.6.1
iPhone 17.1.2 (I'm using the same iPhone)
The only difference here being the macOS version. However, the problem started on my "broken" computer while I was running a previous major macOS version. This problem is actually what prompted my to do a system update to Sonoma.
Please for the love of god, halp!!!
I am using the Xcode 26.3 Claude Agent feature. Claude Agent can’t access on my Desktop folder when they are specified as chat attachments because I accidentally denied access to that folder when it was first requested.
I had earlier read the Xcode 26.3 release notes, so I was somewhat aware of this known issue, but I didn't make the connection when the Desktop access prompt appeared. I wasn't expecting the permissions prompt, because the regular (non-agent) Xcode Claude is able to freely access Desktop files when they are specified as Xcode coding assistant chat session attachments.
Claude Agent isn’t listed in macOS Settings > Privacy & Security > Files and Folders, so I can’t fix the permissions there.
The TCC database contains these rows:
% sqlite3 ~/Library/Application\ Support/com.apple.TCC/TCC.db \
"SELECT service, client, datetime(last_modified, 'unixepoch', 'localtime') as last_modified
FROM access
ORDER BY last_modified DESC" | head -2
kTCCServiceSystemPolicyDownloadsFolder|/Users/drew/Library/Developer/Xcode/CodingAssistant/Agents/Versions/26.3/claude|2026-02-07 15:19:25
kTCCServiceSystemPolicyDesktopFolder|/Users/drew/Library/Developer/Xcode/CodingAssistant/Agents/Versions/26.3/claude|2026-02-07 13:38:07
but I can’t seem to reset them using tccutil, apparently because /Users/drew/Library/Developer/Xcode/CodingAssistant/Agents/Versions/26.3/claude is not a valid bundle identifier:
% tccutil reset all '/Users/drew/Library/Developer/Xcode/CodingAssistant/Agents/Versions/26.3/claude'
tccutil: No such bundle identifier "/Users/drew/Library/Developer/Xcode/CodingAssistant/Agents/Versions/26.3/claude": The operation couldn’t be completed. (OSStatus error -10814.)
I would like for Claude Agent to be able to access my Desktop folder.
What is an appropriate next step?
Thank you for any help you can provide.
My computer setup is I work from an account with regular (non-admin) privileges. I login into the admin account to install apps, update the OS, that kind of stuff, but work is from the reduced privileges account.
And, when in it, I cannot preview swiftUI views in Xcode. Incredibly frustrating, have tried everything including a complete wipeout of the disk and reinstall, but no luck.
Don't have any iOS simulator targets installed, it's macOS target I am working on. If I fire up xcode from the admin account it's all good, previes work and so on. Not so in the non-admin account, consistenly getting the "Cannot preview in this file. Failed to launch xxxx"
Also tried elevating the privileges of the account to Admin, rebooting, no luck. Tried creating a new account, non-admin or admin, no luck.
The detailed error repeats something along the lines of:
== PREVIEW UPDATE ERROR:
GroupRecordingError
Error encountered during update group #3
==================================
| FailedToLaunchAppError: Failed to launch GIIK.Mesh-One
|
| /Volumes/Glyph 2TB/Developer/M4Book/Mesh One/DerivedData/Mesh One/Build/Products/Debug/Mesh One.app
|
| ==================================
|
| | [Remote] JITError
| |
| | ==================================
| |
| | | [Remote] XOJITError
| | |
| | | XOJITError: Could not create code file directory for session: Permission denied
Most telling is the double space between directory and for on the last error line, it sounds like a failed string interpolation because the directory name was nil or empty?
This is very frustrating (I also filed FB21900410). Am I missing something obvious? I also dumped the build settings and diffed the admin and non-admin accounts and they are an exact match (save for the path names).
There has to be something that's preventing the non-admin accounts from previewing, anyone know what it might be/where to look?
Cheers,
Topic:
Developer Tools & Services
SubTopic:
Xcode
I’m trying to use MCP servers with Xcode 26.3 Coding Intelligence (Codex agent). With a project-scoped config file at /.codex/config.toml, MCP servers are not reliably loaded.
/.codex/config.toml
Example:
[mcp_servers.Notion]
url = "https://mcp.notion.com/mcp"
enabled = true
[mcp_servers.XcodeBuildMCP]
command = "/bin/zsh"
args = ["-lc", "/opt/homebrew/bin/npx -y xcodebuildmcp@beta mcp"]
enabled = true
tool_timeout_sec = 10000
Expected:
Xcode consistently loads MCP servers defined in /.codex/config.toml across restarts.
Actual:
Xcode often only exposes xcode-tools. In some sessions MCP servers appear, but after restarting Xcode they may disappear. The global file at ~/Library/Developer/Xcode/CodingAssistant/codex/config.toml also seems managed/rewritten by Xcode and isn’t reliable for custom MCP servers.
Questions
Is /.codex/config.toml the official/supported way to configure MCP servers for Codex in Xcode right now?
Are there any requirements for Xcode to load it (e.g. workspace must be Trusted, open .xcworkspace vs .xcodeproj, full restart/force quit, etc.)?
Is there any logging/diagnostics to understand why the MCP server is not starting or not being picked up?
I have configured Xcode 26.3RC to utilize Claude and Claude Agent. However, it does not seem to access Claude's config.json where I supply information for the MCP servers that I use with Claude.
If I manually tell Xcode to look in the config file it finds the appropriate API keys, but that's not really a usable experience.
Topic:
Developer Tools & Services
SubTopic:
Xcode
Hello,
I am facing a recurring issue with Xcode iOS simulator (preview). I want to preview a SwiftUI for iOS in Xcode, but the Simulator app fails to boot up.
I receive the following error in Xcode:
Cannot Preview in this file. Simulator was shutdown during an update.
I have tried the following:
Completely uninstalling XCode and deleting all developer data, then reinstalling everthing again.
Shutdown and restart
Deleting all developer data, deleting XCode cache
Reinstalling iOS Simulator runtimes and reconfiguration of simulators.
Tested using different simulator and runtime versions.
"xcrun simctl --set previews delete al"
My reported issues:
FB20987522
FB20485454
Thank you
Best regards,
Jens
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags:
Xcode Previews
Xcode
Simulator
Business and Enterprise
No eligible devices connected to 'My Mac