Limit maximum redirects to something sensible

main
Bob Mottram 2024-03-27 11:37:06 +00:00
parent 714695d4f3
commit 2aec6996e0
1 changed files with 1 additions and 0 deletions

View File

@ -43,6 +43,7 @@ def create_session(proxy_type: str):
return None
if not session:
return None
session.max_redirects = 3
if proxy_type == 'tor':
session.proxies = {}
session.proxies['http'] = 'socks5h://localhost:9050'