Open kitsuyui opened 3 weeks ago
According to this issue , reqwest-middleware does not support blocking Clients.
When I try to use it, I get an error like this:
mismatched types
expected `reqwest::Client`, found `reqwest::blocking::Client`rustcClick for full compiler diagnostic
It might be a good idea to support Client
based on async.
Add retry logic to
Client
. Currently, if an error occurs, it fails immediately. However, Codecov's API returns 5xx errors quite often. By adding retry logic, you can retry even if the API is temporarily down. Retry only when the API returns a specific error.I think it would be even better if the retry count and interval for 5xx errors could be exponential backoff. Maybe the reqwest-retry crate has that feature. reqwest-retry