Ancestors

Toot

Written by Jake Nelson on 2024-09-15 at 18:00

Anyone got any tips for debugging a crashing SwiftData migration? I'm wondering if it's just easier to do it manually... 😅

It crashes right after the willMigrate, and these errors:

"A Core Data error occurred." "Instances of NSCloudKitMirroringDelegate are not reusable and should have a lifecycle tied to a given instance of NSPersistentStore."

I thought it was this, which fixes the crash, but then my didMigrate code is never ran.

https://forums.developer.apple.com/forums/thread/744491

Any tips or ideas?

=> More informations about this toot | More toots from jknlsn@hachyderm.io

Descendants

Written by Jake Nelson on 2024-09-15 at 18:44

OK it seems to work if I create a container without CloudKit, then if I actually want a container with CloudKit I create and return that after, just don't use the original container for anything.

Feels gross, but works? I think?

My uber-scientific print statements indicate this takes negligible time, so hopefully fine

=> More informations about this toot | More toots from jknlsn@hachyderm.io

Proxy Information
Original URL
gemini://mastogem.picasoft.net/thread/113142873459891492
Status Code
Success (20)
Meta
text/gemini
Capsule Response Time
269.764671 milliseconds
Gemini-to-HTML Time
0.452356 milliseconds

This content has been proxied by September (3851b).