Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cover jpg preventing download #24

Closed
rinseaid opened this issue Jan 19, 2022 · 2 comments
Closed

Cover jpg preventing download #24

rinseaid opened this issue Jan 19, 2022 · 2 comments

Comments

@rinseaid
Copy link

rinseaid commented Jan 19, 2022

When trying to download a particular odm file, it errors out on the cover art. An output folder is created, but nothing is downloaded as the process exits out after tripping up on the cover art download. The file does appear to be truly broken, but would be great if odmpy could catch and handle the error.

# odmpy dl BjrkanSagas-64.odm
Downloading "The Björkan Sagas" by "Harold R. Johnson" in 4 parts...
Traceback (most recent call last):
File "/usr/sbin/odmpy", line 33, in
sys.exit(load_entry_point('odmpy==0.4.8', 'console_scripts', 'odmpy')())
File "/usr/lib/python3.10/site-packages/odmpy/main.py", line 26, in main
run()
File "/usr/lib/python3.10/site-packages/odmpy/odm.py", line 508, in run
cover_res.raise_for_status()
File "/usr/lib/python3.10/site-packages/requests/models.py", line 960, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 404 Client Error: Not Found for url: https://images.contentreserve.com/ImageType-100/2016-1/%7B00000000-0000-0000-0000-000000000232%7DImg100.jpg

Running version 0.4.8 within an alpine docker, but also able to reproduce this on Windows. Please let me know if further info is needed, or a copy of the .odm file.

ping added a commit that referenced this issue Jan 19, 2022
ping added a commit that referenced this issue Jan 19, 2022
@ping
Copy link
Owner

ping commented Jan 19, 2022

Thanks for the report. This should be fixed in 0.4.9.

@rinseaid
Copy link
Author

Confirmed! Updated to 0.4.9 and re-ran odmpy against the same .odm file.

odmpy now helpfully logs the error and continues the download.

Thanks so much, @ping.

#odmpy dl BjrkanSagas-64.odm
Downloading "The Björkan Sagas" by "Harold R. Johnson" in 4 parts...
Error downloading cover: 404 Client Error: Not Found for url: https://images.contentreserve.com/ImageType-100/2016-1/%7B00000000-0000-0000-0000-000000000232%7DImg100.jpg
Already downloaded license file: ./BjrkanSagas-64.license
Part 1[################################] 30/30 - 00:00:01
Saved "./The Björkan Sagas - Harold R. Johnson/the-björkan-sagas-part-01.mp3"
Part 2[################################] 32/32 - 00:00:01
Saved "./The Björkan Sagas - Harold R. Johnson/the-björkan-sagas-part-02.mp3"
Part 3[################################] 33/33 - 00:00:01
Saved "./The Björkan Sagas - Harold R. Johnson/the-björkan-sagas-part-03.mp3"
Part 4[################################] 34/34 - 00:00:01
Saved "./The Björkan Sagas - Harold R. Johnson/the-björkan-sagas-part-04.mp3"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants