Skip to content

[🐛] Getting stuck in loading state for ChannelList #3180

@ndb-allgravy

Description

@ndb-allgravy

Issue

We're getting reports from users getting stuck on an infinite loading status on the ChannelList component.
This happens in a situation with bad connection, but with offline enabled and available data, which gets wiped.

Related code looks like in stream-chat-js, so I created issue there but posting here for visibility too.
GetStream/stream-chat-js#1584

Thank you! Let me know if this makes sense

Steps to reproduce

Steps to reproduce the behavior:

With a bad connection...

  1. Offline sync manager tries to client.sync() but this fails with a timeout
  2. Offline data gets deleted
  3. Querying channels fails due to timeout, and isLoading is not cleared
  4. See loading status, even if we a) should have offline data, and b) should instead show an error if we didn't have data

Expected behavior

  • Loading state should be false when we have an error after all queryChannels requests have failed
  • Offline data should not be wiped when a sync request fails.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions