-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Labels
featurea feature request or enhancementa feature request or enhancement
Description
When working with gargle via a package like googlesheets, failed requests are automatically retried. This is excellent and it means requests almost always make it through.
The downside is that the retries understandably backoff rather aggressively, so the wait time can be quite long, up to 100 seconds by default. In a Shiny app, this can be an eternity of waiting for the end user, and it'd be helpful for the app author to be able to give some feedback on the progress of the request.
The feature request is for gargle to offer some window of opportunity to know that a retry has happened and to run code before the next retry occurs.
Just brainstorming, two potential ways to do this could be:
gargle::request_retry()could execute a callback function, found via an R option, before callingSys.sleep().gargle::request_retry()could take inspiration fromrlang::check_installed()and signal a known condition with restarts. This would give (admittedly expert) users a chance to run code before returning control torequest_retry().
Metadata
Metadata
Assignees
Labels
featurea feature request or enhancementa feature request or enhancement