Found a solution that worked for me. In my case I was fetching data asynchronously using a ModelActor.
The fix was I had to refetch the model data again using the modelContext model(for:) method
// Async fetch of an episode from a playlist
if let episode: Episode = await playlist.episode() {
// This was missing and was critical. I needed to refetch the data.
let episode: Episode = modelContext.model(for: episode.persistentModelID) as! Episode
}
There's probably a better way to structure my code to prevent this...but this worked as a fix for me where the other solutions didn't.
Post
Replies
Boosts
Views
Activity
Still an issue in iOS 17 beta 6.
"cloudKitContainerIdentifier" doesn't work anymore. You can't set nil or a value. You just get this error: "Extraneous argument label 'cloudKitContainerIdentifier:' in call"
Even though you can't set it, it still enables CloudKit on it's own. Making it impossible to disable it.