mirror of https://github.com/scrapy/scrapy.git
Log errors importing or initializing download handlers
This commit is contained in:
parent
d3804b3439
commit
15ccf79cad
|
|
@ -43,14 +43,16 @@ class DownloadHandlers(object):
|
|||
'no handler available for that scheme'
|
||||
return None
|
||||
|
||||
path = self._schemes[scheme]
|
||||
try:
|
||||
dhcls = load_object(self._schemes[scheme])
|
||||
dhcls = load_object(path)
|
||||
dh = dhcls(self._crawler_settings)
|
||||
except NotConfigured as ex:
|
||||
self._notconfigured[scheme] = str(ex)
|
||||
return None
|
||||
except Exception as ex:
|
||||
logger.exception()
|
||||
logger.exception('Loading "{}" for scheme "{}" handler'\
|
||||
.format(path, scheme))
|
||||
self._notconfigured[scheme] = str(ex)
|
||||
return None
|
||||
else:
|
||||
|
|
|
|||
Loading…
Reference in New Issue