No such module 'RealmSwift' error in playground

I’ve installed the bootstrap script with no errors. However, xcode complains
" No such module ‘RealmSwift’ "
in the playground when trying to import RealmSwift.
Using Xcode 10 and version 1.1 of the course.

1 Like

Hi, the 1.1 edition of the book is for Xcode 9.3 / Swift 4.1 (as stated on the cover and the book store page). If you have a digital copy of the book, as soon as there is a book update for Xcode 10 you can download it for free.

1 Like

i’m facing the same problem too. the solution: i’m using xcode normal project by creating new app.

Open bootstrap.sh with your favorite editor, and just change the REALM_VERSION=“3.4.0” with the latest Realm Version that appears in this page https://realm.io/docs/swift/latest/

In the time I’m writting this post is the 3.11.1 version so you will replace this line with REALM_VERSION=“3.11.1” and then run bootstrap.sh again.

Hope it helps.

2 Likes

Indeed, that works.
Thank you.

Indeed. updating to version 3.13.1 as latest suggested by barrera fixes the problem of No such RealmSwift module in the playground. I open the bootstrap with the textEdit app and changed the version numbers to the one found in the link

It didn’t work for me. Pretty much al day I wasted trying to make this work. But was still getting No such module ‘RealmSwift’ on my Xcode 10, Swift 4.2 despite using Realm 13.3.1 which is the latest.

This tutorial helped me set up Realm with Playground as a separate project:

Great solution, thanks. I think it is better to run bootstrap.sh clean, but it works anyway.

Update on 20190804, change the line below in the bootstrap file

## Realm release
REALM_VERSION="3.14.2"

Thank you. Realm “3.14.2” worked for me on Xcode 10.3