Closed israx closed 2 years ago
Hi @israx, are you seeing this issue on DataStore.save
for all models in your schema or a select few? Could you share some examples of the DataStore.save
calls are showing this behavior?
For all of them. This is how I'm calling the API and also here are some logged events I'm getting.
Could you try upgrading to aws-amplify@4.3.21
? This version contains a new feature that might show additional errors logged to the console.
Hi,
I'm facing the same issue after running amplify pull into an existing React Native project.
Using API.graphql
saves data but DataStore.save
submits data locally only and never syncs to cloud where as API.graphql
(mutation) does.
I've using version "aws-amplify": "^4.3.21"
Please advise @dpilch
Hi @pratikdhody, are you seeing an error in the console?
I was able to see the error logged in the console after updating aws-amplify, I was not passing an "id" property to one of my schemas. Now it's working fine.
Do you mind sharing the full error message? We are working to improve the error logging and having real examples would be useful.
Apologies I was not able to reproduce the error anymore. I already updated my schema design which is deployed to production.
This issue has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs.
Looking for a help forum? We recommend joining the Amplify Community Discord server amplify-help
forum.
Before opening, please confirm:
JavaScript Framework
React
Amplify APIs
DataStore
Amplify Categories
api
Environment information
Describe the bug
Amplify Datastore saves data locally only. When I use
DataStore.save()
, the data is not saved in dynamoDb . I'm able to query data that has being stored before though. Other than that, the App is listening for Datastore events and I never get a "ready" event. I'm wondering that the problem might be on the Schema design.Here bellow I attached screenshots of my Schema design and where I'm listening for DataStore events.
Expected behavior
DataStore being able to sync with dynamoDb
Reproduction steps
DataStore.Save(new Schema())
Code Snippet
Log output
aws-exports.js
No response
Manual configuration
No response
Additional configuration
No response
Mobile Device
No response
Mobile Operating System
No response
Mobile Browser
No response
Mobile Browser Version
No response
Additional information and screenshots
No response