I created a new project in XCode.
File > New > Playground (option+shift+cmd+N)
I restarted my XCode and also rebooted my system, but still same error.
From the developer forums, this worked for me:
- Quit Xcode
- Delete the folder
/Users/<username>/Library/Developer/CoreSimulator/Devices
. For example, in Terminal:rm -rf ~/Library/Developer/CoreSimulator/Devices
- In Terminal:
killall -9 com.apple.CoreSimulator.CoreSimulatorService
(or just reboot).