mirror of
https://github.com/janeczku/calibre-web
synced 2024-11-25 02:57:22 +00:00
Update testresults
This commit is contained in:
parent
8f3bb2e338
commit
399ddc5d6f
@ -738,16 +738,18 @@ def save_cover_from_url(url, book_path):
|
|||||||
return save_cover(img, book_path)
|
return save_cover(img, book_path)
|
||||||
except (socket.gaierror,
|
except (socket.gaierror,
|
||||||
requests.exceptions.HTTPError,
|
requests.exceptions.HTTPError,
|
||||||
|
requests.exceptions.InvalidURL,
|
||||||
requests.exceptions.ConnectionError,
|
requests.exceptions.ConnectionError,
|
||||||
requests.exceptions.Timeout) as ex:
|
requests.exceptions.Timeout) as ex:
|
||||||
log.info(u'Cover Download Error %s', ex)
|
# "Invalid host" can be the result of a redirect response
|
||||||
|
log.error(u'Cover Download Error %s', ex)
|
||||||
return False, _("Error Downloading Cover")
|
return False, _("Error Downloading Cover")
|
||||||
except MissingDelegateError as ex:
|
except MissingDelegateError as ex:
|
||||||
log.info(u'File Format Error %s', ex)
|
log.info(u'File Format Error %s', ex)
|
||||||
return False, _("Cover Format Error")
|
return False, _("Cover Format Error")
|
||||||
except UnacceptableAddressException:
|
except UnacceptableAddressException as e:
|
||||||
log.error("Localhost was accessed for cover upload")
|
log.error("Localhost or local network was accessed for cover upload")
|
||||||
return False, _("You are not allowed to access localhost for cover uploads")
|
return False, _("You are not allowed to access localhost or the local network for cover uploads")
|
||||||
|
|
||||||
|
|
||||||
def save_cover_from_filestorage(filepath, saved_filename, img):
|
def save_cover_from_filestorage(filepath, saved_filename, img):
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user