Posted February 21, 2017
Yes, and I'm doing mostly that but by calling the same parsing function again, in case of HTTP 500, with an extra boolean switch I added for movies (to remove the downloads from the URL of the query). It's calling itself *once*, so it's recursive :P. I didn't mean Fibonacci-like recursive.
Yepoleb: Recursive functions? It should be a simple if response.status == 500 then retry without downloads.
In my case it makes more sense to do that since I already have an iterative retry logic part of the bulk queries I do. Having a retry loop inside a function call that's already in a retry loop reminds me too much of "Inception". I'm more of a "One Retry Loop to rule them all, One Retry Loop to find them, One Retry Loop to bring them all and in the darkness bind them" kind of coder :).
Post edited February 21, 2017 by WinterSnowfall