mirror of
https://github.com/JohnEstropia/CoreStore.git
synced 2026-01-11 20:00:30 +01:00
Error with Xcode 10 #231
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @felipekoblinger on GitHub (Sep 20, 2018).
Hello! I'm not sure if I'm doing something wrong.
I'm using CoreStore (latest - 5.3.0) in a simple project and it was working fine on Xcode 9.4.1, but it is giving a runtime error in Xcode 10 (iOS 12).
Code base: https://github.com/felipekoblinger/ibd185-my-watched-movies-ios
It is working fine in iOS 12 with Xcode 9.4.1.
Am I missing something?
Thanks :)
@JohnEstropia commented on GitHub (Sep 21, 2018):
@felipekoblinger Hi, this was a known issue with Swift 4.2 and should be fixed in the
developbranch for version 5.3.1. (I'm pushing the Cocoapods version within the day)This is due to the changes in memory ownership model in Swift 4.2. In particular, in places where objects are chained:
In this case the array returned from the
friendsrelationship may be deallocated before thenameproperty is read. You can fix this in the current5.3.0version by doingIn CoreStore 5.3.1 all CoreStoreObject property types now keep a strong reference to the internal
NSManagedObject. In theory this shouldn't cause retain cycles becauseNSManagedObjects don't retain their parentCoreStoreObjects and their properties.I'm keeping this issue open to get feedback from others. Let me know if you observe anything unstable.