Skip to content

Amplify.DataStore first run sync problem. A lot of sync requests and 0 items  #2

@yurydemin

Description

@yurydemin

Hello, Kilo, thanks for your projects and great tutorials.
I have found interesting situation with DataStore when running flutter app at first time (clear app, without cache).
E.g look at the todos project. After config plugins, todos bloc starting with getTodos and observeTodos.
So at the first request (DataStore.query(Todo.classType)) DataStore starting sync process, sending some sync requests and return 0 todo items! After that observer starting its requests again and again to get all data correct.
Its happening just at the first launch after installing app. The second one and other - OK, like already syncing and first request return correct amount of items.

Maybe it is nesseccary to check datastore sync after plugins setup or smth else?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions