Every time I create a new playground in order to test some code, Xcode gets stuck and won\'t run the code. It simply presents \'Running playground\' or \'Launching simulator
Firstly, delete the inbuilt comment line.
Then, even if you put a first line comment back in, it still works.
I have cancelled the comment on the first line. It solved for me. Make sure to try it after you have closed and relaunched Xcode and force quit com.apple.coresimulator from Activity Monitor
Check for iCloud storage plan!
If you do have one, it constantly syncs the entire computer which includes Desktop and Document folders. Instead try creating a "Local Files" folder in your Home folder(command+shift+h) and keep your Playground projects there, where it doesn't sync to iCloud.
This worked for me.I hope this works for you as well! :)
I had the same problem, all that I did is to open Assistance editor and everything works fine with me even when I closed the Assistance editor! Don't ask why it was trial and error. Hope this will help you
I was facing the same issue but after googling and experimenting a bit, I found out that one must always import UIKit
before importing any other libs.
In my experience, you should:
It works very well.