Chapter 6 - Error when performing manual migration

This is my 3rd attempt to complete the manual migration as outlined in chapter 6. After being frustrated from error messages earlier this week, I decided to take a break and try it again in a few days.

Tonight I started chapter 6 from the beginning, making sure I followed every step and compared my work with the completed projects. All my code and settings appear to be correct, but I still get an error when launching the app:

Thread 1: Exception: “-[UnCloudNotes.Note attachments]: unrecognized selector sent to instance 0x600000b5c3c0”

Screen Shot 2020-04-30 at 6.37.28 PM

What did I do wrong? I included a copy of my project.

UnCloudNotes.zip (125.8 KB)

EDIT: I noticed I didn’t set the note relationship as the inverse to the attachment relationship. I did change that, deleted and recreated the mapping mode, but now I get a different error:

Thread 1: Fatal error: Unresolved error Error Domain=NSCocoaErrorDomain Code=134140 “Persistent store migration failed, missing mapping model.” UserInfo={destinationModel=(<NSManagedObjectModel: 0x60000268b5c0>) isEditable 0, entities {

Screen Shot 2020-04-30 at 7.49.15 PM

@jvantoor Please check out the update version of the book when you get a chance:

https://store.raywenderlich.com/products/core-data-by-tutorials

I hope it helps!

This topic was automatically closed after 166 days. New replies are no longer allowed.