Merge pull request #906 from mouse-reeve/isbn-search-resiliency

Handle arbitrary errors in isbn search
This commit is contained in:
Mouse Reeve 2021-04-07 11:18:51 -07:00 committed by GitHub
commit 5d45b01f05
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -40,8 +40,9 @@ def search(query, min_confidence=0.1):
else:
try:
result_set = connector.isbn_search(isbn)
except (HTTPError, ConnectorException):
pass
except Exception as e: # pylint: disable=broad-except
logger.exception(e)
continue
# if no isbn search or results, we fallback to generic search
if result_set in (None, []):