[b]"What's the best way to implement python retry for API calls?"[/b] or [b]"How do you handle python retry logic

12 Replies, 1543 Views

"Python retry for API calls – what’s your go-to method?"

Hey folks!

I’ve been banging my head against retrying API calls in python and wanted to see how others handle it.

Do you use built-in stuff like `tenacity` or `retrying`? Or just roll your own decorator?

Sometimes the simple `for` loop with `try/except` feels messy, but idk if adding a lib is overkill.

Also, how do you handle backoff? Exponential? Jitter? Or just YOLO it with fixed delays?

Kinda curious what’s worked best for y’all. Share your python retry hacks!

(Also, if anyone’s got a clean way to avoid nested try-catch spaghetti, pls share lol)

Messages In This Thread
[b]"What's the best way to implement python retry for API calls?"[/b] or [b]"How do you handle python retry logic - by - 28-10-2024, 10:17 PM



Users browsing this thread: 1 Guest(s)