Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SplashMixin: improve the package list loading flow #1309

Merged
merged 1 commit into from
Apr 29, 2024

Conversation

anttimaki
Copy link
Collaborator

  • Handle problems in making the API request and saving the response to IndexedDB by silently logging the errors instead of hanging the process with unhandled exceptions. These errors aren't fatal if reading the mod list from cache does succeed
  • Handle problems in reading the mod list from IndexedDB into Vuex by showing an error modal instead of hanging the process. If nothing else, the error message might result in easier investigation of issues reported on Discord
  • Change the logic so the flow proceeds to profiles screen only if loading the mod list into Vuex resulted in no errors, and the mod list contains mods. An exception to this is that empty mod list is allowed if the API request actually returned an empty list. This is a bit sketchy since we have no way for telling a part "no response has been cached" and "response with empty list is cached"
  • If the flow doesn't proceed to profiles screen, the "offline mode" is shown, but this is a bit misnomer now since it's shown even if an API request is made successfully, but processing the result fails e.g. due to IndexedDB error. I feel this is good enough as it is since it allows debugging the rare error situations, and rethinking the whole thing might be too much work
  • User may also end up in the "offline mode" if the mod list is successfully loaded into Vuex but e.g. checking deprecations fail. They will then see the online mod list if they proceed, which may be a bit confusing but not a big issue
  • Unified the status texts to use loadingText subtitle rather than update the main title so often

- Handle problems in making the API request and saving the response to
  IndexedDB by silently logging the errors instead of hanging the
  process with unhandled exceptions. These errors aren't fatal if
  reading the mod list from cache does succeed
- Handle problems in reading the mod list from IndexedDB into Vuex by
  showing an error modal instead of hanging the process. If nothing
  else, the error message might result in easier investigation of
  issues reported on Discord
- Change the logic so the flow proceeds to profiles screen only if
  loading the mod list into Vuex resulted in no errors, and the mod
  list contains mods. An exception to this is that empty mod list is
  allowed if the API request actually returned an empty list. This is a
  bit sketchy since we have no way for telling a part "no response has
  been cached" and "response with empty list is cached"
- If the flow doesn't proceed to profiles screen, the "offline mode" is
  shown, but this is a bit misnomer now since it's shown even if an API
  request is made successfully, but processing the result fails e.g.
  due to IndexedDB error. I feel this is good enough as it is since it
  allows debugging the rare error situations, and rethinking the whole
  thing might be too much work
- User may also end up in the "offline mode" if the mod list is
  successfully loaded into Vuex but e.g. checking deprecations fail.
  They will then see the online mod list if they proceed, which may be
  a bit confusing but not a big issue
- Unified the status texts to use loadingText subtitle rather than
  update the main title so often
@anttimaki anttimaki merged commit 82452c2 into develop Apr 29, 2024
7 checks passed
@anttimaki anttimaki deleted the splash-mixin-fixin branch April 29, 2024 06:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant