mirror of
https://gitlab.com/jeancf/twoot.git
synced 2025-01-31 05:33:45 +00:00
Add tolerance for TooManyRedirects in media search in linked page
This commit is contained in:
parent
bb226e54a9
commit
fdab0a0836
5
twoot.py
5
twoot.py
|
@ -227,7 +227,10 @@ def main(argv):
|
|||
if match is not None:
|
||||
url = match.group(1).replace('&', '&') # Remove HTML-safe encoding from URL if any
|
||||
photos.append(url)
|
||||
except (requests.exceptions.ConnectionError, requests.exceptions.Timeout, requests.exceptions.ContentDecodingError):
|
||||
except (requests.exceptions.ConnectionError,
|
||||
requests.exceptions.Timeout,
|
||||
requests.exceptions.ContentDecodingError,
|
||||
requests.exceptions.TooManyRedirects):
|
||||
pass
|
||||
|
||||
# Add dictionary with content of tweet to list
|
||||
|
|
Loading…
Reference in New Issue
Block a user