mirror of
https://github.com/viq/NewsBlur.git
synced 2025-09-18 21:43:31 +00:00
Screw it. Too many different exceptions come from fetching URLs. If anything goes wrong, not much we can do.
This commit is contained in:
parent
5927f857b2
commit
4b4c5b76aa
1 changed files with 3 additions and 2 deletions
|
@ -9,7 +9,7 @@ import operator
|
|||
import BmpImagePlugin, PngImagePlugin, Image
|
||||
from StringIO import StringIO
|
||||
from apps.rss_feeds.models import MFeedPage
|
||||
from utils.feed_functions import timelimit, TimeoutError
|
||||
from utils.feed_functions import timelimit
|
||||
|
||||
HEADERS = {
|
||||
'User-Agent': 'NewsBlur Favicon Fetcher - http://www.newsblur.com',
|
||||
|
@ -178,7 +178,8 @@ class IconImporter(object):
|
|||
return image, icon_file
|
||||
try:
|
||||
image, icon_file = _1(url)
|
||||
except (urllib2.HTTPError, urllib2.URLError, IOError, TimeoutError, ValueError):
|
||||
# except (urllib2.HTTPError, urllib2.URLError, IOError, TimeoutError, ValueError):
|
||||
except (Exception):
|
||||
return None, None
|
||||
return image, icon_file
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue