zeiteisen
zeiteisen

Reputation: 7168

Playground execution terminated because the playground process exited unexpectedly

I want to use a playground in Xcode 6.0.1. So File -> New -> Playground

I get immediately the error. Playground execution terminated because the playground process exited unexpectedly. See image. Restart Xcode didn't helped.

Whats wrong with Xcode?Xcode Error

Upvotes: 15

Views: 8550

Answers (11)

Damo
Damo

Reputation: 12900

This happened to me and I found that the platform setting wasn't set for my playground. Probably because the playground was created in a previous version of XCode which didn't require it.

Solution:

Double click on your playground to open it in XCode and wait for the fail message. Dismiss the message (it may appear more than once) and do the following

1.Select to show the project navigator pane.

enter image description here

2.Select the workspace in the navigator.

enter image description here

3.Select to show the Utilities pane.

enter image description here

4.In the playground settings area of the Identity inspector. Select OSX (or iOS)

enter image description here

Upvotes: 0

Anshu Kumar Gupta
Anshu Kumar Gupta

Reputation: 181

A restart of Xcode solves the problem , most of the times . (Do remember to quit from the dock too)

If that doesn't work a restart of Mac is all that is required

Upvotes: 0

Sophy Swicz
Sophy Swicz

Reputation: 1367

It's not necessary to delete manually Developer's folder. Just follow this steps in Command Line (CL).

Quit Xcode.app, Simulator.app and all Xcode related and then in CL:

 sudo killall -9 com.apple.CoreSimulator.CoreSimulatorService

 rm -rf ~/Library/*/CoreSimulator

Upvotes: 0

SmileBot
SmileBot

Reputation: 19662

New Answer:

As @Woomin points out in the comments, first try restarting Xcode and rebooting your Mac, and if that fails try the following:

Try deleting the .simruntime files:

enter image description here

I found them located here in my root directory:

enter image description here

Old Answer:

If the above doesn't work try removing everything in the Developer folder located at /Library/Developer/. If this still doesn't work try removing everything in ~/Library/Developer/. If this still doesn't solve it remove xcode with AppCleaner and reinstall it using the MAS version. I found that doing this last thing solved the issue but it came back when I installed the simulators from xcode's download tab. Removing the .simruntime files finally solved it for me. BTW, I'm using version 7.2.

Upvotes: 29

MppleHero
MppleHero

Reputation: 31

Xcode 7.2 and Mac os x 10.11.2 Restart Xcode or mac does not worked for me. I solve this problem is that delete the Simulator Profiles. The Path is ~/Library/Developer/CoreSimulator/Profiles/Runtimes. Delete all Runtimes. Than Restart the Xcode, problem has been solved.

Upvotes: 1

Areal-17
Areal-17

Reputation: 406

With Xcode 7.2 (7C68) i had the same problem. I'd solve it by changing the entry of the runtime value from com.apple.CoreSimulator.SimRuntime.iOS-9-1 to com.apple.CoreSimulator.SimRuntime.iOS-9-2. I'd changed it in the device.plist. In ~/Library/Developer/CoreSimulator/XCPGDevices/ is one or more folder with a UUID as name. In one of this folders is the current device.plist.enter image description here

Upvotes: 0

Strictly Taboo
Strictly Taboo

Reputation: 13

OSX 10.11.2 and Xcode 7.2

I had gotten a reply to his from a member on the Apple Developer Forum and wanted to provide some additional information on my fix for this. First I deleted the ~/Library/Developer folder as indicated. Looking into it it had the some Simulator Profiles. I didn't know what that had to do with the Playground issue so I did NOT empty the Trash. I rebooted and the playground worked.

I put back the folder and the playground had the issues again. I one by one removed the simulator profiles in the sub directory ultimately removing ALL of the profiles without deleting the ~/Library/Developer folder structure and the Playground works.

Upvotes: 0

Zhao
Zhao

Reputation: 924

Thanks smileBot's answer. I am able to make it work with 7.2 too. I did try differently.

I installed Xcode 7.2 release version via downloading. However it had problem mentioned above. I first deleted the Xcode 7.2 via AppCleaner completely. Empty the trash. Also cleaned the derived data using WatchDog for Xcode And then restart the machine. Try again, it did not work.

So I went ahead deleted the folder ~/Library/Developer/ and then restart, try again, I can use Playground again in Xcode 7.2 again.

Upvotes: 3

Teja Swaroop
Teja Swaroop

Reputation: 1169

Install Command line tools using command

xcode-select --install

then u will get an update in Appstore install that app Problem will be solved.

Upvotes: 0

Infinitus
Infinitus

Reputation: 11

It is ok when Change the platform to "OS X" from inspector, but problem when back to "iOS". I don't know why...in Xcode7 Beta.

Plus, it is ok in my Xcode 6.4 for both platform when playground.

And there is one more option for iOS platform "Run in Full Simulator",besides "Render Documentation"option. in My Xcode 6.4 inspector

and I have check the "IDEPlaygroundSettings.inspector" in

/Applications/Xcode.app/Contents//PlugIns/IDELanguageSupportUI.ideplugin/Contents/Resources/IDEPlaygroundSettings.inspector

and

/Applications/Xcode-Beta.app/Contents//PlugIns/IDELanguageSupportUI.ideplugin/Contents/Resources/IDEPlaygroundSettings.inspector

they are quite different.

Upvotes: -2

zeiteisen
zeiteisen

Reputation: 7168

A restart of the mac solves the problem. What causes the issue is still unknown.

Upvotes: 8

Related Questions