iterative / iterative/PyDrive2

retries for failed API requests

Offen
#41 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
enhancement
Vorherrschende Sprache
Python
Sterne
670
Forks
75
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

Currently, pydrive2 uses googleapiclient for all Drive API operations, but doesn't retry any failed requests. However, the Drive API [recommends retries with exponential backoff](https://developers.google.com/drive/api/v3/handle-errors) for many errors, and [googleapiclient supports retries](https://github.com/googleapis/google-api-python-client/blob/c482712935d1c1331e33bd7f9968bd3b2be223bb/googleapiclient/http.py#L846) for all requests.

Would it be possible to add retry behavior as per the Drive API recommendations?

(Additionally, it'd be great to add this for the [initial client creation](https://github.com/iterative/PyDrive2/blob/c739ba379e4c656da5e229a21c39a4d621ada09b/pydrive2/auth.py#L610-L612), as the discovery service can also throw 500s.)

Thanks!

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.