mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-11-23 10:01:04 +00:00
Merge pull request #906 from mouse-reeve/isbn-search-resiliency
Handle arbitrary errors in isbn search
This commit is contained in:
commit
5d45b01f05
1 changed files with 3 additions and 2 deletions
|
@ -40,8 +40,9 @@ def search(query, min_confidence=0.1):
|
||||||
else:
|
else:
|
||||||
try:
|
try:
|
||||||
result_set = connector.isbn_search(isbn)
|
result_set = connector.isbn_search(isbn)
|
||||||
except (HTTPError, ConnectorException):
|
except Exception as e: # pylint: disable=broad-except
|
||||||
pass
|
logger.exception(e)
|
||||||
|
continue
|
||||||
|
|
||||||
# if no isbn search or results, we fallback to generic search
|
# if no isbn search or results, we fallback to generic search
|
||||||
if result_set in (None, []):
|
if result_set in (None, []):
|
||||||
|
|
Loading…
Reference in a new issue