Datastore - Changing Schema Breaks Query #1083
Labels
bug
Something isn't working
closing soon
This issue will be closed in 7 days unless further comments are made.
datastore
Issues related to the DataStore category
pending-community-response
Issue is pending response from the issue requestor
Describe the bug
For Amplify iOS - Datastore, if a user saves a model instance, then modifies its modelSchema to add another field, then runs amplify codegen models, a crash happens:
To Reproduce
Steps to reproduce the behavior:
type Note @model {
id: ID!
content: String!
}
Save the model and then query. Observe no error.
Update the schema:
type Note @model {
id: ID!
content: String!
name: String
}
Expected behavior
No error after changing the modelschema and running query
Screenshots
Here is the local DB on the phone. As you can see it's updated to include the extra fields:
Also on the AWS Amplify console you can see the extra fields as well:
Device Information (please complete the following information):
The text was updated successfully, but these errors were encountered: