mirror of
https://github.com/JohnEstropia/CoreStore.git
synced 2026-01-13 12:50:34 +01:00
returnsObjectsAsFaults is not working with fetch tweak #251
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 @iby on GitHub (Jan 9, 2019).
I'm trying to do batch faulting using
returnsObjectsAsFaults… with no success! ☹️ I tried this on my own data and with TimeZones demo. Using the README tweak example I've updated the FetchingAndQueryingDemoViewController.swift#L165-L171 with:This however yields unexpected faulted timezone object:
Looking into this deeper I found a clue on StackOverflow but can't find publicly accessible persistent coordinator in stack nor store, so can't test it out:
Can you confirm whether this is the case? Is there a workaround? ✌️
@JohnEstropia commented on GitHub (Jan 10, 2019):
Yes, the read-only context is currently a child of the write-only context.
Not sure how to work around this issue though, or wether this is a bug or not. In my understanding the
returnsObjectsAsFaultsis a hint that properties can be prefetched, but there might be conditions where CoreData would ignore this altogether.