Simulator

RSS for tag

Rapidly prototype and test builds of your app during the development process using Simulator.

Posts under Simulator tag

200 Posts

Post

Replies

Boosts

Views

Activity

Resolving a "Simulator runtime is not available" error
Some Macs recently received a macOS system update which disabled the simulator runtimes used by Xcode 15, including the simulators for iOS, tvOS, watchOS, and visionOS. If your Mac received this update, you will receive the following error message and will be unable to use the simulator: The com.apple.CoreSimulator.SimRuntime.iOS-17-2 simulator runtime is not available. Domain: com.apple.CoreSimulator.SimError Code: 401 Failure Reason: runtime profile not found using "System" match policy Recovery Suggestion: Download the com.apple.CoreSimulator.SimRuntime.iOS-17-2 simulator runtime from the Xcode To resume using the simulator, please reboot your Mac. After rebooting, check Xcode Preferences → Platforms to ensure that the simulator runtime you would like to use is still installed. If it is missing, use the Get button to download it again. The Xcode 15.3 Release Notes are also updated with this information.
0
0
9.7k
May ’24
In Simulator on status bar red banner with rdar:45025538
Out of nowhere I got some red banner on top of my iPhone 13 mini / iOS 17.5. I cannot pin point the root cause of this. What I can say is that it only happens to Simulators of a certain type, e.g. iPhone 12 and 13 mini, but not iPhone 14 for example. I have installed Xcode 26.1.0 and 26.1.1, out of which 26.1.0 is selected: $ xcode-select -p /Applications/Xcode-26.1.0.app/Contents/Developer And following runtimes: $ xcrun simctl runtime list == Disk Images == -- iOS -- iOS 17.5 (21F79) - CF933623-A258-44F8-B248-C0F25C0C343B (Ready) iOS 26.1 (23B80) - D11C3CDC-EE3D-44CC-8B92-9B7D00B54B0B (Ready) Total Disk Images: 2 (14.6G) Installing the newer 26.1 23B86 runtime doesn't help either.
18
2
1.8k
3d
Unable to Download iOS Simulator Runtime 26.1 on Xcode — Bad URL Error (Code 49)
Hi everyone, I’m experiencing a persistent issue when trying to download the iOS Simulator Runtime 26.1 on Xcode (version 26.1). The download always fails with the following error Download failed due to a bad URL. (Catalog download for com.apple.MobileAsset.iOSSimulatorRuntime) Domain: com.apple.MobileAssetError.Download Code: 49 I’m located in Brazil, so I initially thought it might be region-related, but I’ve already tried several attempts to fix it, including: Using VPNs for the US and Europe Installing the Xcode 26.2 beta Downgrading Xcode to earlier versions Reinstalling the same version of Xcode Restarting Xcode and my Mac Switching networks Clearing simulator support/device files Unfortunately, nothing has resolved the issue. Is anyone else facing this problem? Does anyone know a workaround or a manual way to download/install the iOS 26.1 simulator runtime? Thanks in advance!
6
8
1k
3d
Whether SSC can be connected to the iPad real machine with Xcode to run the evaluation
👋Hi This problem is related to SSC. I remember that the form submitted last year needed to be filled in with Xcode or Playground test, and it seems that it was also mentioned: • If you use Xcode, the judges may use Simulator to run. • If you use Playground, it's a real machine. But my work this time will encounter two limitations: It will use the framework/API only available in iPadOS 26 (so if it is a Playground environment, it may not run, playground can't use iPadOS 26 SDK) It will also use some content that must be real to run (such as ARKit), which means that Xcode Simulator is not good. So I would like to ask: Does this year's review allow you to compile and connect the iPad to the real machine? Or did I misremember last year's regulations? If the judge's environment is fixed (for example, only Playground or only Simulator), how should I adjust the submission method or implement the scheme? Looking forward to your reply, thank you.
2
3
248
4d
Simulator is not working.
Hi, I am a UI designer and a total newbie with coding, so I have been using AI in Xcode to do all my coding for my personal project. Everything was working fine until this morning, when I tried to run my app in the simulator (I didn't even change any code from the last time I ran the simulator) and now the simulator is crashing and freezing and I have been trying to fix it with the AI recommendations, but it seems way too complicated for me to handle even with AI's help. I feel like I need to talk to an expert and guide me out of this hole. Please help. Thank you!
3
0
306
5d
iOS Simulator fails to boot (18.6 / 26.1 / 26.2) – launchd_sim could not bind to session
Hi, I’m facing a consistent simulator boot issue that appears to start after iOS 18.2 simulator runtimes and persists in 18.6, 26.1, and 26.2. Observed behavior iOS 18.2 simulator works fine iOS 18.6 simulator does NOT boot iOS 26.1 / 26.2 simulators do NOT boot Tried everything reinstall/clear cache and all and event formatted the system Unable to boot the Simulator NSPOSIXErrorDomain Code: 4 Failure Reason: Interrupted system call Failed to start launchd_sim: could not bind to session, launchd_sim may have crashed or quit responding macOS: Sequoia Xcode: 26.1, 26.2 Machine: Apple Silicon Unable to boot the Simulator. Domain: NSPOSIXErrorDomain Code: 4 Failure Reason: Interrupted system call User Info: { DVTErrorCreationDateKey = "2025-12-26 02:19:27 +0000"; IDERunOperationFailingWorker = "_IDEInstalliP.honeSimulatorWorker", Session = "com apple CoreSimulator.SimDevice CCDECA56-4A59-491B-A830-0F3928FCD957"; } Failed to start launchd_sim: could not bind to session, launchd_sim may have crashed or quit responding Domain: com.apple.SimLaunchHostService.RequestError Code: 4 Event Metadata: com.apple. dt. DERunOperationWorkerFinished : { "device_identifier" = "CCDECAE6-4A59-491B-A830-0E3928FCD957"; "device_model" = "iPhone18, 1"; "device_osBuild" = "26.1 (23B86)"; "device_osBuild_monotonic" = 2301008600; "device_os_variant" = 1; "device_platform" = "com apple.platform.iohonesimulator"; "device_platform_family" = 2; "device_reality" = 2; "device_thinningType" = "iPhone18,1"; "device_transport" = 4; "launchSession_schemeCommand" = Run; "launchSession_schemeCommand_enum" = 1; "launchSession_targetArch" = arm64; "launchSession_targetArch_enum" = 6; "operation_duration_ms" = 1183; "operation_errorCode" = 4; "operation_errorDomain" = NSPOSIXErrorDomain; "operation_errorWorker" = "_IDEInstalliPhoneSimulatorWorker"; "operation_error_reportable" = 1; "operation_name" = IDERunOperationWorkerGroup; "param_consoleMode" = 1; "param_debugger_attachToExtensions" = 0; "param_debugger_attachToXPC" = 1; "param_debugger_type" = 3; "param_destination_isProxy" = 0; "param_destination_platform" = "com apple platform Please help on this as it got stuck. Thanks
3
4
503
5d
Orphaned 9GB Simulator Runtime in /System/Library/AssetsV2 - Cannot Delete (SIP protected)
I have an orphaned asset folder taking up 9.13GB located at: /System/Library/AssetsV2/com_apple_MobileAsset_iOSSimulatorRuntime/c0d3fd05106683ba0b3680d4d1afec65f098d700.asset It contains SimulatorRuntimeAsset version 18.5 (Build 22F77). Active Version: My current Xcode setup is using version 26.2 (Build 23C54). I checked the plist files in the directory and found what seems to be the cause of the issue: The "Never Collected" Flag: The Info.plist inside the orphaned asset folder explicitly sets the garbage collection behavior to "NeverCollected": <key>__AssetDefaultGarbageCollectionBehavior</key> <string>NeverCollected</string> The Catalog Mismatch: The master catalog file (com_apple_MobileAsset_iOSSimulatorRuntime.xml) in the parent directory only lists the new version (26.2). Because the old version (18.5) is missing from this XML, Xcode and mobileassetd seem to have lost track of it entirely. What I Have Tried (All Failed) Xcode Components: The version 18.5 does not appear in Settings -> Components, so I cannot delete it via the GUI. Simctl: xcrun simctl list runtimes does not list this version. Running xcrun simctl runtime delete 22F77 fails with: "No runtime disk images or bundles found matching '22F77'." Manual Deletion: sudo rm -rf [path] fails with "Operation not permitted", presumably because /System/Library/AssetsV2 is SIP-protected. Third-party Tools: Apps like DevCleaner do not detect this runtime (likely because they only scan ~/Library or /Library, not /System/Library). Has anyone found a way to force the system (perhaps via mobileassetd or a specific xcrun flag) to re-evaluate this folder and respect a deletion request? I am trying to avoid booting into Recovery Mode just to delete a cache file. Any insights on how AssetsV2 handles these "orphaned" files would be appreciated.
5
3
321
6d
Liquid glass segment view freezes when dragging handle to a disabled segment
Setup: I have a segment view with 3 segments, and the last on (at index 2) is disabled. Issue: When I drag the liquid glass handle of the segment view from what was previously selected to the disabled segment, the liquid glass handle freezes mid-air. Workaround: I can still interact with the handle and manually restore its position, or tap on any other segment to restore its position. Notes: I'm using UIKit, and no extra customizations are applied. class ViewController: UIViewController { @IBOutlet weak var segmentView: UISegmentedControl! override func viewDidLoad() { super.viewDidLoad() segmentView.removeAllSegments() let segments = ["Option 1", "Option 2", "Option 3"] for (index, title) in segments.enumerated() { segmentView.insertSegment(withTitle: title, at: index, animated: false) } // Select the first one by default segmentView.selectedSegmentIndex = 0 // Disable the last segment segmentView.setEnabled(false, forSegmentAt: 2) } }
0
0
51
1w
Has Apple officially not noticed this issue? can't download iOS 26.2 Simulator
I’m using macOS Tahoe 26, and Xcode is version 26.2. I’ve tried all the methods suggested online, but I still can’t download it. In addition, iOS 26.* and iOS 18.* simulators also fail to download. The error messages are shown below. Download failed. Domain: DVTDownloadableErrorDomain Code: 41 User Info: { DVTErrorCreationDateKey = "2026-01-06 01:25:11 +0000"; } Download failed. Domain: DVTDownloadableErrorDomain Code: 41 Failed fetching catalog for assetType (com.apple.MobileAsset.iOSSimulatorRuntime), serverParameters ({ RequestedBuild = 23C54; }) Domain: DVTDownloadsUtilitiesErrorDomain Code: -1 Download failed due to a general networking error. (Catalog download for com.apple.MobileAsset.iOSSimulatorRuntime) Domain: com.apple.MobileAssetError.Download Code: 47 User Info: { tryAgainLater = 1; } System Information macOS Version 26.0 (Build 25A354) Xcode 26.2 (24553) (Build 17C52) Timestamp: 2026-01-06T09:25:11+08:00
1
3
318
1w
How to delete iOS simulator runtimes?
There are multiple iOS simulator runtimes located at /System/Library/AssetsV2/com_apple_MobileAsset_iOSSimulatorRuntime which I don't need. I tried the following approaches to delete them but not working. Xcode > Settings > Components > Delete (It can delete some but not all of them) xcrun simctl runtime list (It doesn't show the old runtimes) sudo rm (Operation not permitted) sudo rm -rf cc1f035290d244fca4f74d9d243fcd02d2876c27.asset Password: rm: cc1f035290d244fca4f74d9d243fcd02d2876c27.asset/AssetData/096-69246-684.dmg: Operation not permitted rm: cc1f035290d244fca4f74d9d243fcd02d2876c27.asset/AssetData: Operation not permitted rm: cc1f035290d244fca4f74d9d243fcd02d2876c27.asset/Info.plist: Operation not permitted rm: cc1f035290d244fca4f74d9d243fcd02d2876c27.asset/version.plist: Operation not permitted rm: cc1f035290d244fca4f74d9d243fcd02d2876c27.asset: Operation not permitted I have two questions: Why "xcrun simctl runtime list" is unable to list some old runtimes? How to delete them?
1
1
207
1w
CarPlay navigation issue, maximum depth
Hi everyone, I am working on a CarPlay integration, and need open a two level list opened from a root template. However, I am always receiving an error message when opening the 2nd pushed template. To narrow it down not to have an issue with some app specific code I created the CarPlay scene below. I am aware that there is a limit, but two levels I understand are supported on all CarPlay integrations, the maximum seems to be 5. The app is just crashing right after showing the 2nd template. Any ideas? Any hints are much appreciated. Thanks a lot! Regards, Michael class CarPlaySceneDelegate2: UIResponder, CPTemplateApplicationSceneDelegate { // [...] private func createRootTemplate() -> CPListTemplate { let pushToAItem = CPListItem(text: "Push to Template A", detailText: "Level 1 → Level 2") pushToAItem.handler = {[weak self] (pushToAItem, completion) in guard let self = self else { completion() return } self.interfaceController?.pushTemplate( self.pushTemplateA(), animated: true, completion: { (didPresent, error) in completion() } ) } let section = CPListSection(items: [pushToAItem]) let template = CPListTemplate(title: "Root Template", sections: [section]) return template } private func pushTemplateA() -> CPListTemplate { let pushToBItem = CPListItem(text: "Push to Template B", detailText: "Level 2 → Level 3") pushToBItem.handler = {[weak self] (pushToBItem, completion) in guard let self = self else { completion() return } self.interfaceController?.pushTemplate( self.pushTemplateB(), animated: true, completion: { (didPresent, error) in completion() } ) } let backToRootItem = CPListItem(text: "Pop to Root", detailText: "Go back to root") backToRootItem.handler = { [weak self] _, completion in self?.interfaceController?.popToRootTemplate(animated: true, completion: nil) completion(); } let infoItem = CPListItem(text: "Current Depth", detailText: "2 (Template A)") let stackCountItem = CPListItem( text: "Stack Count", detailText: "\((interfaceController?.templates.count ?? 0) + 1)" ) let section = CPListSection(items: [pushToBItem, backToRootItem, infoItem, stackCountItem]) let template = CPListTemplate(title: "Template A", sections: [section]) return template } private func pushTemplateB() -> CPListTemplate { let pushToCItem = CPListItem(text: "Push to Template C", detailText: "Level 3 → Level 4") pushToCItem.handler = {[weak self] (pushToCItem, completion) in guard let self = self else { completion() return } self.interfaceController?.pushTemplate( self.pushTemplateC(), animated: true, completion: { (didPresent, error) in completion() } ) } let backToRootItem = CPListItem(text: "Pop to Root", detailText: "Go back to root") backToRootItem.handler = { [weak self] _, completion in self?.interfaceController?.popToRootTemplate(animated: true, completion: nil) completion() } let popOneItem = CPListItem(text: "Pop One", detailText: "Go back to Template A") popOneItem.handler = { [weak self] _, completion in self?.interfaceController?.popTemplate(animated: true, completion: nil) completion() } let infoItem = CPListItem(text: "Current Depth", detailText: "3 (Template B)") let stackCountItem = CPListItem( text: "Stack Count", detailText: "\((interfaceController?.templates.count ?? 0) + 1)" ) let section = CPListSection(items: [pushToCItem, popOneItem, backToRootItem, infoItem, stackCountItem]) let template = CPListTemplate(title: "Template B", sections: [section]) return template } private func pushTemplateC() -> CPListTemplate { let backToRootItem = CPListItem(text: "Pop to Root", detailText: "Go back to root") backToRootItem.handler = { [weak self] _, completion in self?.interfaceController?.popToRootTemplate(animated: true, completion: nil) completion() } let popOneItem = CPListItem(text: "Pop One", detailText: "Go back to Template B") popOneItem.handler = { [weak self] _, completion in self?.interfaceController?.popTemplate(animated: true, completion: nil) completion() } let infoItem = CPListItem(text: "Current Depth", detailText: "4 (Template C)") let stackCountItem = CPListItem( text: "Stack Count", detailText: "\((interfaceController?.templates.count ?? 0) + 1)" ) let section = CPListSection(items: [popOneItem, backToRootItem, infoItem, stackCountItem]) let template = CPListTemplate(title: "Template C", sections: [section]) return template } }
2
0
1.6k
1w
Xcode Simulator causes Mac audio crackling and distortion
[Submitted as FB20950954] Xcode Simulator causes crackling and distortion in audio playback across all apps (Apple Podcasts, Music, third-party). REPRO STEPS Open any audio app and start playback Note the audio quality Launch Xcode Simulator After a few seconds, note audio quality again Quit Xcode Simulator Audio returns to normal CURRENT Audio has crackling and distortion while Simulator is running. EXPECTED Clean audio playback regardless of whether Simulator is running. SYSTEM INFO macOS 26.1 (25B78) Xcode 26.1 (17B55) Simulator 26.0 (1058)
3
2
252
1w
Unable to download iOS simulator runtime 26.x on Xcode
Hi everyone, I'm experiencing a persistent issue for months now where I'm unable to download the iOS 26 simulator Runtime. I've tried reinstalling Xcode and also Xcode Beta but same issue. iOS 26 Simulator is also not on developers download page, so manual installation is impossible. And sadly I can't compile any code without having iOS 26 simulator installed. Anyone able to get passed this? Hardware: M1 Pro OS: Tahoe 26.1 Heres the error Download failed. Domain: DVTDownloadableErrorDomain Code: 41 User Info: { DVTErrorCreationDateKey = "2026-01-07 11:35:35 +0000"; } -- Download failed. Domain: DVTDownloadableErrorDomain Code: 41 -- Failed fetching catalog for assetType (com.apple.MobileAsset.iOSSimulatorRuntime), serverParameters ({ RequestedBuild = 23C54; }) Domain: DVTDownloadsUtilitiesErrorDomain Code: -1 -- Download failed due to not being able to connect to the host. (Catalog download for com.apple.MobileAsset.iOSSimulatorRuntime) Domain: com.apple.MobileAssetError.Download Code: 60 User Info: { checkNetwork = 1; } -- System Information macOS Version 26.1 (Build 25B78) Xcode 26.2 (24553) (Build 17C52) Timestamp: 2026-01-07T12:35:35+01:00
6
4
942
1w
Failed to download iOS 26.2 (23C53) SDK + iOS 26.2 (23C54) Simulator (Components absent)
for detailed Download failed. Domain: DVTDownloadableErrorDomain Code: 41 User Info: { DVTErrorCreationDateKey = "2026-01-17 08:51:49 +0000"; } Download failed. Domain: DVTDownloadableErrorDomain Code: 41 Failed fetching catalog for assetType (com.apple.MobileAsset.iOSSimulatorRuntime), serverParameters ({ RequestedBuild = 23C54; }) Domain: DVTDownloadsUtilitiesErrorDomain Code: -1 Download failed due to not being able to connect to the host. (Catalog download for com.apple.MobileAsset.iOSSimulatorRuntime) Domain: com.apple.MobileAssetError.Download Code: 60 User Info: { checkNetwork = 1; } System Information macOS Version 15.7.3 (Build 24G419) Xcode 26.2 (24553) (Build 17C52) Timestamp: 2026-01-17T16:51:49+08:00
0
0
70
2w
hapticpatternlibrary.plist error with Text entry fields in Simulator only
When I have a TextField or TextEditor, tapping into it produces these two console entries about 18 times each: CHHapticPattern.mm:487 +[CHHapticPattern patternForKey:error:]: Failed to read pattern library data: Error Domain=NSCocoaErrorDomain Code=260 "The file “hapticpatternlibrary.plist” couldn’t be opened because there is no such file." UserInfo={NSFilePath=/Library/Audio/Tunings/Generic/Haptics/Library/hapticpatternlibrary.plist, NSURL=file:///Library/Audio/Tunings/Generic/Haptics/Library/hapticpatternlibrary.plist, NSUnderlyingError=0x600000ca1b30 {Error Domain=NSPOSIXErrorDomain Code=2 "No such file or directory"}} <_UIKBFeedbackGenerator: 0x600003505290>: Error creating CHHapticPattern: Error Domain=NSCocoaErrorDomain Code=260 "The file “hapticpatternlibrary.plist” couldn’t be opened because there is no such file." UserInfo={NSFilePath=/Library/Audio/Tunings/Generic/Haptics/Library/hapticpatternlibrary.plist, NSURL=file:///Library/Audio/Tunings/Generic/Haptics/Library/hapticpatternlibrary.plist, NSUnderlyingError=0x600000ca1b30 {Error Domain=NSPOSIXErrorDomain Code=2 "No such file or directory"}} My app does not use haptics. This doesn't appear to cause any issues, although entering text can feel a bit sluggish (even on device), but I am unable to determine relatedness. None-the-less, it definitely is a lot of log noise. Code to reproduce in simulator (xcode 26.2; ios 26 or 18, with iPhone 16 Pro or iPhone 17 Pro): import SwiftUI struct ContentView: View { @State private var textEntered: String = "" @State private var textEntered2: String = "" @State private var textEntered3: String = "" var body: some View { VStack { Spacer() TextField("Tap Here", text: $textEntered) TextField("Tap Here Too", text: $textEntered2) TextEditor(text: $textEntered3) .overlay(RoundedRectangle(cornerRadius: 8).strokeBorder(.primary, lineWidth: 1)) .frame(height: 100) Spacer() } } } #Preview { ContentView() } Tapping back and forth in these fields generates the errors each time. Thanks, Steve
2
0
250
2w
iPhone mini simulator error Xcode 26.2
Hello, I just updated my Xcode to 26.2 and downloaded the relevant simulator for it to test how my app looks in general. I use the newest iPhone and mini version, in this case, iPhone 13 mini, and the SE (3rd generation). Everything is working as expected, but for the iPhone mini simulator, this weird red line is showing. Is anyone having this issue?
1
0
118
2w
Extremely slow download speed for iOS 26.2 Simulator Runtime in Xcode
I am located in Taiwan and recently updated my Mac to the latest OS and installed the newest Xcode. However, I’m experiencing extremely slow download speeds when trying to add the iOS 26.2 Simulator Runtime (approx. 8GB) via Xcode > Settings > Platforms. It is currently downloading at a rate of only 500MB per hour, which is impractical. I have checked the official downloads page but couldn't find a standalone DMG link for this specific version. My questions are: Is there a direct download link (DMG) available on the Apple Developer portal for the iOS 26.2 Simulator? If no direct link exists, are there any recommended methods to accelerate the download? (e.g., using terminal commands or changing DNS settings). Any help or direct URLs would be greatly appreciated. Thank you!
0
0
186
2w
XCUIDevice.shared.appearance = .dark no longer works when running UI tests via xcodebuild on newer iOS versions
I am seeing a regression with XCUIDevice.shared.appearance = .dark in UI tests that only affects xcodebuild, not Xcode’s UI test runner. Setup • UI tests written using XCTest • Dark mode forced in setUp() using: XCUIDevice.shared.appearance = .dark • Tests target an iOS simulator • Same test target, same scheme Expected behavior The app launches in Dark Mode for UI tests, as it did previously. Actual behavior • When running UI tests from Xcode (Product > Test), Dark Mode is applied correctly. • When running the same UI tests via xcodebuild test, Dark Mode is ignored and the app launches in Light Mode. • No test failures, no warnings, no logs indicating the appearance override was skipped. Regression details • This used to work on older iOS versions when running via xcodebuild. • The regression appears after updating iOS simulators (exact version boundary still unclear). • No relevant changes were made to the test code, scheme, or CI configuration. • xcodebuild otherwise launches and runs UI tests normally. Notes • The issue is specific to XCUIDevice.shared.appearance. • Other UI test functionality behaves as expected. • This makes CI results inconsistent with local Xcode runs and breaks visual assumptions in snapshot and layout-based tests. Question Is this a known regression or an intentional behavior change in recent iOS / Xcode versions? If intentional, what is the supported way to reliably force Dark Mode in UI tests when running via xcodebuild? This currently makes xcodebuild-based CI UI testing unreliable compared to Xcode’s test runner.
1
0
65
2w
Xcode Using 90GB with ~/Library/Developer — What Can I Safely Clean?
Hi everyone, I’m an iOS developer working on a Mac with limited storage (256 GB). I’ve noticed that the ~/Library/Developer folder is taking up almost 90 GB, mainly due to Xcode-related content. Inside it I see folders like: Xcode/DerivedData DocumentationCache iOS DeviceSupport UserData CoreSimulator/Devices Before deleting anything, I’d like to understand which of these folders are safe to clean up, and what the potential side effects might be (for example, rebuild times, simulator re-downloads, etc.). What is the recommended best practice to manage disk space when using Xcode on a low-storage machine? Thanks in advance for your help.
2
0
148
2w