any ideas on how I can fix it?
Xcode playground keeps saying running my playground but dosen't run any code I type in it just keeps saying that
Sometimes, playground gets stuck.
What I do then:
- quit and restart XCode
- try ro run the playground
if does not work:
- quit and restart XCode
- comment out about half of code in playground to check if it works.
- continue by dichotomie to find if some code is causing the problem
Can you provide a screenshot or an error message?
Do you have automatic running enabled? If so try re running manually. I don’t think it works every time though.
there is no error message it just keeps saying running playground but never does and I've tried it manually and automatically @jinpark5117
@KingOfTheEmpre Ok then can you try changing the playground's target platform to macOS like how it is suggested in this stackoverflow answer?
Ok @KingOfTheEmpre can you check if the target platform of the playground is macOS? If the target platform's something other than macOS try changing it to macOS like it is suggested in this stackoverflow answer. Perhaps that will work.
shoot. multiple comments. Thought the forum deleted my comment, turns out I was wrong. Anyways, didn't mean to spam you, sorry. 😉
@KingOfTheEmpre If the above solution doesn't work, consider using the Swift Playgrounds app on the macOS app store. It's not a perfect replacement for XCode Playgrounds (for instance, playgroundbooks are only available on xcode playgrounds), but if xcode playgrounds is too buggy it might be worth it.
P.S. Note that the swift playgrounds app also has a bug which makes playgrounds crash (specifically when using SwiftUI). The solution to that bug is to turn off the "enable results" option for that playground 😉