Reply to Does SwiftData have a context.perform {} method? It is indeed caused by this problem. I changed the relationship to optional and it can be saved, but I think this is a problem with Apple, because semantically, I need the relationship not to be optional. App & System Services iCloud & Data Jul ’23