0
0
Fork 0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2024-11-16 01:25:06 +00:00

Aggressive test timeout to catch hanging servers

This commit is contained in:
Philipp Hagemeister 2013-01-12 20:33:03 +01:00
parent 187f491ad2
commit d8bbf2018e

View file

@ -26,6 +26,7 @@
proxy_handler = compat_urllib_request.ProxyHandler() proxy_handler = compat_urllib_request.ProxyHandler()
opener = compat_urllib_request.build_opener(proxy_handler, cookie_processor, YoutubeDLHandler()) opener = compat_urllib_request.build_opener(proxy_handler, cookie_processor, YoutubeDLHandler())
compat_urllib_request.install_opener(opener) compat_urllib_request.install_opener(opener)
socket.setdefaulttimeout(10)
def _try_rm(filename): def _try_rm(filename):
""" Remove a file if it exists """ """ Remove a file if it exists """