Skip to content
This repository has been archived by the owner on May 10, 2023. It is now read-only.

Review Sentences can get stuck on loading #609

Closed
Sobsz opened this issue Mar 8, 2022 · 2 comments
Closed

Review Sentences can get stuck on loading #609

Sobsz opened this issue Mar 8, 2022 · 2 comments
Labels
bug Something isn't working frontend good first issue Good for newcomers P2

Comments

@Sobsz
Copy link

Sobsz commented Mar 8, 2022

My Sentence Collector session entered a "stuck" state. In this state, the "Review" section perpetually displays a spinner with the text "Loading sentences...", even when no language is selected. All other sections work fine. Debugging shows that no request is ever made to review?locale=[language] is ever made.

The "stuck" state can be removed by editing the local storage key persist:sentences to remove sentencesLoading:"true", but this cannot be done without access to a trusted computer. None of the following mobile-only methods solved the issue:

  • logging out and back in (whether via Firefox account or passwordless login)
  • force-stopping Firefox
  • disabling all addons and Enhanced Tracking Protection
  • switching from mobile data to Wi-Fi

Switching browsers or using Incognito mode do allow the user to sidestep the issue. Removing browsing data would solve, too, but I could not find a way to do so for one site only on Firefox Android.

Running Firefox 97.2.0 on Android 11. My Internet connection was being spotty today, which I believe might have caused the problem.

@MichaelKohler
Copy link
Member

Thanks for this thorough bug report and all the debugging done. This makes it fairly straightforward to fix.

We are persisting the sentences state with a few exceptions here: https://github.com/common-voice/sentence-collector/blob/main/web/src/reducers/index.ts#L21

To make sure we are not persisting the loading states, we should add both isUploadingSentences and sentencesLoading to the exceptions linked to above. Then saving the state while a request is reloading wouldn't result in this scenario.

Great catch!

@MichaelKohler MichaelKohler added bug Something isn't working frontend good first issue Good for newcomers P2 labels Mar 8, 2022
paulotokimatu added a commit to paulotokimatu/sentence-collector that referenced this issue May 25, 2022
MichaelKohler pushed a commit that referenced this issue May 25, 2022
## [2.17.5](v2.17.4...v2.17.5) (2022-05-25)

### Bug Fixes

* stop persisting loading state (fixes [#609](#609)) ([#622](#622)) ([b0c8c2c](b0c8c2c))
@MichaelKohler
Copy link
Member

🎉 This issue has been resolved in version 2.17.5 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working frontend good first issue Good for newcomers P2
Projects
None yet
Development

No branches or pull requests

2 participants