In some iOS app written in Objective C
and using Core Data
, I have the following issue.
I have an entity (called myEntity) initialized with one record. I have checked, by counting the number of records, using the debugger, that it contains one record after initialization.
But I also can see this error message, right after saving the record:
Error: Error Domain=NSCocoaErrorDomain Code=134030 "Error while saving."
So I am not so confident that it is really saved.
Later inside the app I need this record (in myEntity), but for some unknown reason myEntity has lost its unique record, and contains nothing.
I want to locate the point where the record disappears in order to solve the problem.
Is there some kind of break point I can use for that purpose?
I have read about Test Failure Breakpoints
, but the way to use them doesn't seem clear.
There is one more detail I need to add in order to be precise. If I close the app, before needing the record, and reopen it; then everything goes fine with no problem at all.