msfjarvis / compose-lobsters

Claw for Android: Unofficial read-only client for https://lobste.rs, built using Jetpack Compose.
https://play.google.com/store/apps/details?id=dev.msfjarvis.claw.android
MIT License
102 stars 8 forks source link

Implement handling for the Retry-After header #642

Open msfjarvis opened 3 months ago

msfjarvis commented 3 months ago

Sometimes the app can perform actions quickly enough to trigger Lobsters' in-built spam throttling feature. In that scenario the response includes the Retry-After header that we should respect. OkHttp already has support for this AFAICT but it seems to not be triggering for Lobsters, likely due to a different HTTP status code being sent.