mirror of https://github.com/searxng/searxng.git
[enh] engine exception traceback
This commit is contained in:
parent
d6b1ff08ad
commit
23b4a53248
|
@ -40,13 +40,12 @@ number_of_searches = 0
|
||||||
def search_request_wrapper(fn, url, engine_name, **kwargs):
|
def search_request_wrapper(fn, url, engine_name, **kwargs):
|
||||||
try:
|
try:
|
||||||
return fn(url, **kwargs)
|
return fn(url, **kwargs)
|
||||||
except Exception, e:
|
except:
|
||||||
# increase errors stats
|
# increase errors stats
|
||||||
engines[engine_name].stats['errors'] += 1
|
engines[engine_name].stats['errors'] += 1
|
||||||
|
|
||||||
# print engine name and specific error message
|
# print engine name and specific error message
|
||||||
logger.warning('engine crash: {0}\n\t{1}'.format(
|
logger.exception('engine crash: {0}'.format(engine_name))
|
||||||
engine_name, str(e)))
|
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue