From e1e56773cb2e2ad421d414f2ee0010fe0d9b28f5 Mon Sep 17 00:00:00 2001 From: Johan Andersson Date: Sun, 31 Aug 2014 00:55:39 +0200 Subject: [PATCH] get_http_data: remove try-except-clause --- lib/svtplay_dl/utils/__init__.py | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/lib/svtplay_dl/utils/__init__.py b/lib/svtplay_dl/utils/__init__.py index 8f948dc..fadf854 100644 --- a/lib/svtplay_dl/utils/__init__.py +++ b/lib/svtplay_dl/utils/__init__.py @@ -63,19 +63,7 @@ def get_http_data(url, header=None, data=None, useragent=FIREFOX_UA, opener = build_opener(HTTPCookieProcessor(cookiejar)) - try: - response = opener.open(request) - except HTTPError as e: - log.error("Something wrong with that url") - log.error("Error code: %s", e.code) - sys.exit(5) - except URLError as e: - log.error("Something wrong with that url") - log.error("Error code: %s", e.reason) - sys.exit(5) - except ValueError as e: - log.error("Try adding http:// before the url") - sys.exit(5) + response = opener.open(request) if is_py3: data = response.read() try: