chengbo
chengbo

Reputation: 5819

Playground in Xcode cannot be opened

I cannot create playground project, after I press cmd+option+shift+N or click 'Get started with a playground' shown like below picture, nothing happened. No window pop up, no any messages.

Can anybody help me to figure out why?

xcode welcome window

Upvotes: 4

Views: 509

Answers (1)

chengbo
chengbo

Reputation: 5819

Okay, finally I found the below log in Console app.

7/16/15 09:22:39.551 AM Xcode[1337]: [MT] DVTAssertions: Warning in /SourceCache/IDEFrameworks/IDEFrameworks-7720/IDEKit/TemplateLibrary/IDEPlaygroundCreationHelper.m:48
Details:  Could not find suitable playground file template.
Object:   <IDEPlaygroundCreationHelper>
Method:  +createNewPlaygroundFromTemplateInWorkspaceWindowController:platformIdentifier:withContextSetupBlock:
Thread:   <NSThread: 0x7fab12514460>{number = 1, name = main}
Please file a bug at http://bugreport.apple.com with this warning message and any useful information you can provide.

It said Xcode Could not find suitable playground file template, then I realized I had modified code templates several monthes ago, so I was going to delete them

sudo rm -rf ~/Library/Developer/Xcode/Templates/File\ Templates/

Then playground works! It maybe caused by incompatible template files.

Upvotes: 4

Related Questions