download_series only caught AccessDenied, so any other per-book error (e.g. a
Nextory book whose epub package is missing the crypt_key) aborted the entire
series/list download. Catch all per-book exceptions, log them, and continue;
report the count of skipped books at the end.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The EpubInParts writer called exit() right after write_epub(), terminating
the whole process after a single book. This broke every multi-book download
(series, and the new want-to-read list) — only the first ebook was ever
written. Remove it so the download loop continues.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Add a want-to-read flow so the whole 'Saved for later' list can be
downloaded at once: a URL containing 'want-to-read' resolves the user's
want_to_read product list into a Series of book ids, skipping entries with
no epub format (audiobook-only). Mirrors the equivalent feature in
audiobook-dl.
Also remove three leftover rich.print() debug calls in login() that printed
the full session/profile/authorize responses — including the login and
profile tokens — to stdout on every run, and drop a duplicated header update.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Fix Nextory: bump X-App-Version and handle null series
The Nextory API now rejects the old X-App-Version "5.4.1" with an
AppDeprecateError. Bump it to "2026.05.4" (current Android app version).
Also, the product API can return {"series": null} for standalone books
(not just omit the key entirely). The previous `"series" in product_info`
check passed in that case and we crashed on a NoneType subscript.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* Add urllib3 as explicit dependency
grawlix/sources/storytel.py imports urllib3.util.parse_url but urllib3
was only pulled in transitively. Fresh installs (e.g. via uv tool) fail
at import time with ModuleNotFoundError.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* Fix invalid escape sequence warning in saxo regex
f"\d+$" produced a SyntaxWarning on Python 3.12 (and will become a
SyntaxError in a future release). The string has no interpolation, so
the raw form r"\d+$" is the right fix.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Support the new system for eReolen where user access it through their
local libraries.
This new system makes the `--library` argument unnecessary and has
therefore also been removed.
Formats can now be loaded based on book data format and file extension
of the output file. Will also try to use the extension of the output
location instead of using the default filetype every time.