from time import sleep
import requests
+import urllib3
from tweepy.api import API
from tweepy.error import TweepError
self.snooze_time = self.snooze_time_step
self.listener.on_connect()
self._read_loop(resp)
- except (requests.Timeout, ssl.SSLError) as exc:
+ except (requests.ConnectionError, requests.Timeout,
+ ssl.SSLError, urllib3.exceptions.ReadTimeoutError,
+ urllib3.exceptions.ProtocolError) as exc:
# This is still necessary, as a SSLError can actually be
# thrown when using Requests
# If it's not time out treat it like any other exception