Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Duplicate iPhone Simulators Appeared on My Xcode

Tags:

A duplicate iPhone simulator just appeared after I deleted ~/Library/Developer/Xcode/CoreSimulator folder

Duplicate iPhone Simulators

How to solve this problem?

I've tried to delete ~/Library/Developer/Xcode folder and ~/Library/Application Support/iPhoneSimulator folder. But all failed.

like image 774
WeZZard Avatar asked Dec 23 '14 04:12

WeZZard


People also ask

Where are iOS simulators stored?

type: ~/Library/Application Support/iPhone Simulator. The Directories are the iOS version of the different Simulators. The Sub Directories are the Apps install on the simulator. The Documents folder is where the user generated content which gets backup up onto iCloud.

Where is the devices and simulators window in Xcode?

The basic way to open a list of simulators is to use Xcode -> Window -> Devices and Simulators. Here you can create and manage all available simulators.

What are iOS simulators?

An iOS Simulator basically mimics an iOS app or browser on top of a developer's operating system. This is viewable in an iPad or iPhone like window. They cannot virtualize the actual hardware conditions of an iOS device, which is the main requirement for comprehensive testing and debugging.

How do I select a simulated device in Xcode?

Open Xcode and click Menu > Xcode > Preferences > Select Components, and then choose the simulator version you want to download.

How do I add a simulator to Xcode?

You plug in the device, select it in Xcode, and make sure the device is added to your profiles. It’s possible. Just click on the simulator name on top left of Xcode window. Your device will be shown on the top (Sina’s iPhone).

Why can't I run the iOS simulator code on my iPhone/iPad?

The iOS simulator is a version of iOS running in x86 (Intel) machine language. Apps on the app store are ARM code. As the iPhones/iPad's are based on an arm processor and the simulator is an Intel x86 it's not possible. If it is not your own app then you can't. If it's your own device then use the Xcode to run the Simulator code.

What version of iOS do I need for iOS simulators?

Each simulator comes with a particular OS version such as iOS 14.1, iOS 15.0, iOS 15.2, tvOS 14.0, watchOS 7.0, etc. You can easily install the one you need via Xcode. This article shows you how to do so in Xcode 12.x, Xcode 13.x, and newer. 1.

How do I debug an app in Xcode?

Click the Run button to build and run the app on the selected simulated or real device. View the status of the build in the activity area of the toolbar. If the build is successful, Xcode runs the app and opens a debugging session in the debug area.


2 Answers

It may happen because of multiple Xcode installed or during Xcode upgrades. The only thing that need to be done is to open Xcode -> Window -> Devices select duplicated device and delete it.

like image 79
Nikita Leonov Avatar answered Sep 19 '22 14:09

Nikita Leonov


I have a same issue after installing Xcode beta version. I found that there are several solution to fix this issue.

1. snapshot

https://github.com/fastlane/fastlane/tree/master/snapshot

usage : gem install fastlane; fastlane snapshot reset_simulators

I solved my problem with this library and it is very simple to use.

2. Xcode->Window->Devices

You can check installed simulators and delete them. But it will take too long time if you have many simulators.

3. xcrun simctl delete

you can use xcrun command in terminal. But you need to input a specific device name with command.

like image 40
sangjoon moon Avatar answered Sep 22 '22 14:09

sangjoon moon