Skip to content
Snippets Groups Projects

on 429, retry `fetchAccount` instead of failing

Merged dakkar requested to merge feature/retry-login-on-429 into develop
  1. Dec 13, 2024
    • dakkar's avatar
      fix passing rate limiting info via ApiError · 9b1fc969
      dakkar authored
      9b1fc969
    • dakkar's avatar
      on 429, retry `fetchAccount` instead of failing · 0c1dd733
      dakkar authored
      when switching between accounts, with many tabs open (10 seem to be
      enough), they all hit the endpoint at the same time, and some get rate
      limited.
      
      treating a 429 as a fatal error confuses the frontend, which ends up
      logging the user out of all their accounts.
      
      this code makes the frontend retry, after waiting the appropriate
      amount of time.
      
      seems to work fine in my testing.
      0c1dd733
Loading