Sometimes the script randomly hangs. I suspect it happens when my internet connects\disconnects. Requests docs says this:
Timeouts
You can tell Requests to stop waiting for a response after a given number of seconds with the timeout parameter. Nearly all production code should use this parameter in nearly all requests. Failure to do so can cause your program to hang indefinitely
I've added "timeout=120" in all occurrences of "requests.get". Lets see if it helps.
Sometimes the script randomly hangs. I suspect it happens when my internet connects\disconnects. Requests docs says this:
I've added "timeout=120" in all occurrences of "requests.get". Lets see if it helps.