Skip to content

Enable/Disable "Separate Book Files from Library" issue #3131

@castle-samj

Description

@castle-samj

Describe the bug/problem

If there is an invalid /path/to/altbooks in the input field for "Separate Book Files from Library" Calibre-Web will attempt to load from that path regardless of the tick box state.

To Reproduce

Steps to reproduce the behavior:
0. On a working instance, logged in as an admin user..

  1. Go to Settings > Edit Calibre Database Configuration
  2. Select the box next to "Separate Book Files from Library"
  3. Input a directory that is not the same as the "Location of Calibre Database"
    3.1. My exact change was in attempt to target a virtual library: "/path/to/Calibre-Library::virtual"
  4. Save the new configuration
  5. Deselect the tick box next to "Separate Book Files from Library" with the saved path still in the input field
  6. Save configuration again
  7. Load the a page with books to see a wall of "Cover Not Found"
  8. Return to the Settings > Edit Calibre Database Configuration page
  9. Select the tick box next to "Separate Book Files from Library"
  10. Clear all text from the input box and save the configuration
  11. Deselect the tick box next to "Separate Book Files from Library" and save configuration again
  12. Load a page with books to see all cover art loading correctly

Logfile

Multiple lines of the following, but nothing else:
...
[2024-08-21 11:01:30,046] DEBUG {cps.tasks.thumbnail:175} Error updating book thumbnail: Book cover file not found
...

Expected behavior

Deselecting the tick box should result in not using the /path/to/altbooks dir, falling back to the base Calibre Database dir

Screenshots

N/A

Environment (please complete the following information):

  • OS: RaspberryPi OS (Linux 6.6.31+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.31-1+rpt1 (2024-05-29) aarch64)
  • Python version: 3.11.2 (main, May 2 2024, 11:59:08) [GCC 12.2.0]
  • Calibre-Web version: 0.6.23 - d3233b4 - 2024-08-05T18:42:13+02:00 - pyPi
  • Docker container: None
  • Special Hardware: RaspberryPi 5
  • Browser: chromium-browser/stable,now 126.0.6478.164-rpt1 arm64

Additional context
None

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions