Thread1:Fatal error: Container does not have any data stores

when I run my project, I get this error and the simulator open app and show blank page. I don't understand because I have to add some stores after I entry the app. but now I cannot entry it.

I used VersionedSchema and SchemaMigrationPlan

I was getting this error after calling modelContainer.deleteAllData(). If you are calling that, try removing it.

Thread1:Fatal error: Container does not have any data stores
 
 
Q