Merged
Conversation
Amazon search for metadata has been returning HTTP 503. This appears to fix that for `amazon.com`. Also makes some changes to the attributes searched for to accommodate Amazon changes. This may fix #701
Fix getting the rating, series info, identifiers, and high-res cover image.
Ignores some non-book and pre-order pages, resilient against pages with no rating yet, and do better getting the description.
Adds the rating field back to the metadata fetch UI, and allows setting the rating on the book edit screen. Rating is not shown in metadata entries if not fetched from the metadata source.
Google Books search has occasionally thrown an exception that "title" is not a key in `result["volumeInfo"]`. It hasn't happened often, but this makes sure the title is present before trying to use it.
Similar to ACSM support, a specific calibre extension is required for properly supporting KFX and KFX-ZIP files.I've added the extensions to the various lists of allowed extensions, and added their MIME types to the extra types map. This enables importing KFX and KFX-ZIP files using both the automatic ingestion process and manually uploading files.
Updates the build script to add CLI flags for a local build. This will use the existing checked-out repo instead of cloning the repo fresh, for building images for development and testing before code is ready to push up. Also adds CLI flags for the different things the script asks for, mostly as a convenience for people like me who might just re-run the build with some things always the same. I added flags for all of them, just seemed silly to only cover some of them, and the default behavior is the same as it is today. Having flags for values let me shuffle some code around to better reflect what's happening. If a user is provided, for example, there's no point asking for it again or getting the default user. And I added a .editorconfig file, to avoid whitespace-only changes. I took a guess at line width values.
Fixed a couple issues with the local build mode: - dirname was returning relative paths which broke when running the script from different locations. Now properly resolves to absolute path - Added error handling for the cd command so it doesn't silently fail if something goes wrong Also bumped Python line length in editorconfig from 88 to 120 since the existing codebase already has tons of lines over 88 chars anyway. Should cut down on unnecessary warnings.
feat(build): Enable local dev build
feat(import): Kfx format enable
fix(amazon): Fix Amazon metadata search
Fix getting rating from Amazon.com
fix(google): Fix exception in Google metadata search
…r handling - Client-side auto-resize to 200×200px using Canvas API with quality preservation - File size validation (5MB max input, 500KB max output) - Server-side MIME type and Base64 validation for security - Comprehensive error handling for FileReader, image loading, and canvas operations - Form validation: disabled submit until image processed and username entered - Visual feedback: processing indicator, resize notifications, error messages - Accessibility improvements: ARIA labels, descriptive help text, proper alt attributes - Fixed typo: setprofile_picture → set_profile_picture in redirect URL - Added base64 import to cwa_functions.py
Profile pictures: add live preview and auto Base64 handling
Fixes: - Custom login button text now displays correctly on login page - Scope format mismatch resolved (convert string to list for Flask-Dance) - Admin role delegation now works for existing users, not just new ones Improvements: - Case-insensitive group matching (handles "Admin" vs "admin") - Robust group format handling (list, string, comma/space-separated) - Atomic transactions (role changes committed with OAuth entry) - Better error handling and edge case coverage - Scope parsing filters empty strings and handles whitespace Files modified: - cps/web.py: Pass login button text to template - cps/templates/login.html: Display custom button text with fallback - cps/oauth_bb.py: Fix scope format, add role sync for existing users [dev] [bug] Testing OIDC with Authentik. Working - but strange issues... Fixes #715
…g (Issue #715) Critical Fixes: - Remove incorrect token_url_params causing token exchange failures - Keep OAuth scopes as normalized strings (not lists) for OAuth2Session - Add compliance hook to handle scope order/format differences in responses - Create GenericOIDCSession class for proper SSL verification across all requests Error Handling: - Catch InvalidGrantError and TokenExpiredError with user-friendly messages - Add comprehensive exception handling in generic_logged_in callback - Provide specific error feedback instead of generic 500 errors Features: - Custom login button text now displays correctly on login page - Admin role delegation works for both new and existing users - Case-insensitive group matching (handles "Admin" vs "admin") - Robust group format handling (string/list/comma-separated) - Atomic transaction commits for role updates Files modified: - cps/oauth_bb.py: Add GenericOIDCSession, fix scope handling, improve error handling - cps/web.py: Pass login button text to template - cps/templates/login.html: Display custom button text with fallback
…ault; decouple cover changes from uploads cover_enforcer: fallback to safe title/author when metadata fields are empty to avoid ValueError downloads: admin fallback in get_download_link to prevent false 404s on fresh instances; clearer missing-format logging ingest/db: harden CalibreDB.reconnect_db to handle None engine so ingest-triggered session refresh works reliably settings: set _Settings.config_uploading default to 1 (uploads enabled on new instances) covers: allow cover URL/file updates for users with edit role regardless of global uploads toggle; keep format uploads gated by uploads+role templates: update book_edit cover section gating to role_edit; format upload section unchanged (still gated by uploads setting)
- Hardened backup() destination lookup and mkdir; prevents crashes and logs issues instead - Normalized file extension handling; corrected is_target_format logic - Hardened audiobook ‘calibredb add’ argument construction; added proper identifiers flags and safe coalescing of metadata
…stable DB reads Start container using only test override compose file; support CWA_TEST_IMAGE and CWA_TEST_PORT Don’t guess startup time: readiness via HTTP (/, /login) or log signals (ingest watcher/metadata detector); print progress and actual startup duration Add CWA_TEST_NO_TIMEOUT=true and CWA_TEST_START_TIMEOUT=N to control wait policy (default cap 600s) Detect when bind mounts aren’t visible in the container and auto-switch to docker cp mode (AUTO_DOCKER_VOLUMES); set USE_DOCKER_VOLUMES=true for test branching compatibility Introduce DockerPath and update volume_copy to use docker cp in auto mode; ingest_folder/library_folder return DockerPath when auto mode is active Ensure consistent SQLite reads by copying metadata.db along with -wal/-shm sidecars in auto mode (fixes 0-row reads) Add DockerPath.iterdir and .glob to support directory iteration/globbing in tests On startup timeout, print docker compose ps + logs to aid debugging Outcome: Tests run reliably in local, CI, and remote/DinD environments without arbitrary timeouts and with correct DB visibility.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.