I am attempting my first lightweight CoreData migration. I read two guides on lightweight migrations. Both add code to a CoreDataStack class, modifying variables like NSPersiste
The migration options need to be used in the call that added the persistent store to the persistent store coordinator. You will easily find this line of code by doing a search for addPersistentStoreWithType
.
try coordinator!.addPersistentStoreWithType(
NSSQLiteStoreType, configuration: nil, URL: url, options: mOptions)
Most likely your Core Data stack is in the AppDelegate class, but regardless where it is, this is where you have to add the migration options.