swift
Core Data model incompatible with persistent store
CoreData.*NSInternalInconsistencyException.*model.*incompatible.*store
Fixes
- 1.Add a migration mapping model for schema changes
- 2.Use lightweight migration: addPersistentStore with NSMigratePersistentStoresAutomaticallyOption
- 3.Delete and recreate the store in development (loses data)
ioscore-datamigration
Related Errors
swift3 fixes
SwiftUI preview crash
SwiftUI.*Previews.*crashed.*The preview process was terminated
- •Clean build folder: Cmd+Shift+K, then rebuild
- •Check for force-unwrapped optionals or fatalError in preview code
swift3 fixes
Swift Combine publisher cancelled unexpectedly
Swift.*Combine.*Cancelled.*sink received completion.*failure
- •Store the AnyCancellable in a Set to prevent premature deallocation
- •Use .store(in: &cancellables) to retain the subscription
swift3 fixes
App Store Connect binary contains simulator architecture
TestFlight.*ERROR ITMS-90.*Invalid Binary.*contains.*simulator architecture
- •Ensure build is for 'Any iOS Device', not simulator
- •Strip simulator architectures from frameworks in build phase