Search code examples
iosxcodecore-datacore-data-migration

Core Data Tools Version increase - Should I also increase the model version?


My CoreData model currently uses old (Xcode 3.2) format. I'd like to increase it to the latest one available, in which data is represented in the XML form:

cd version

Should I also increase the Model Version Number in the Core Data editor?

model version


Solution

  • I cannot think of any reason why you'd need to do that as Model Version and Tools Version should be unrelated and orthogonal.

    I have a 10-year old Mac app, Core Data document, which I've always built with the latest Xcode but I never bothered to change the Tools Version in its one data model, which contains 28 entities and a lot of relationships. Until 30 minutes ago, its Tools Version was Xcode 3.2, like yours. To prove my point, I changed only the Tools Version, to Automatic (Xcode 9.0), did a Clean Build Folder, then test, build and run. It passed my test suite, launched fine, opens documents, saves changes. No trouble found. Everything works fine. I plan to commit this change and ship my next version with it.