Skip to content

[bug] Scheduled "Convert Library" task fails with 403 (manual trigger works fine) #1481

Description

@CalmStilton

Description

Manually running "Convert Library" (via the Run Now / manual trigger) completes successfully. Scheduling it to run automatically fails every time — the scheduled job never actually starts.

Steps to reproduce

  1. In CWA Settings, schedule the "Convert Library" task (tried a 15 minute interval).
  2. Wait for the scheduled trigger to fire.
  3. Check the container logs.
  4. By contrast, running "Convert Library" manually via its own trigger/button completes without issue.

Actual behavior (from container logs)

ERROR {cps:875} Exception on /convert-library-status [GET]
Traceback (most recent call last):
  File "/lsiopy/lib/python3.13/site-packages/flask/app.py", line 1511, in wsgi_app
    response = self.full_dispatch_request()
  File "/lsiopy/lib/python3.13/site-packages/flask/app.py", line 919, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/lsiopy/lib/python3.13/site-packages/flask/app.py", line 917, in full_dispatch_request
    rv = self.dispatch_request()
  File "/lsiopy/lib/python3.13/site-packages/flask/app.py", line 902, in dispatch_request
    return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
  File "/app/calibre-web-automated/cps/cwa_functions.py", line 1893, in get_status
    with open("/config/convert-library.log", 'r') as f:
FileNotFoundError: [Errno 2] No such file or directory: '/config/convert-library.log'

ERROR {cps.cwa_functions:472} Internal schedule-convert-library failed: 403 Forbidden: You don't have the permission to access the requested resource. It is either read-protected or not readable by the server.

/config/convert-library.log never gets created, which suggests the scheduled job's internal call fails (403) before the conversion actually starts. My guess is the scheduler triggers this via an internal HTTP request to itself and that request isn't carrying an authenticated session, whereas a manual click from the browser does.

Expected behavior

Scheduled "Convert Library" runs should behave the same as a manually-triggered run.

Environment

  • Image: crocodilestick/calibre-web-automated:latest
  • Deployment: Docker Compose
  • No reverse proxy in front of it — accessed directly over LAN
  • Auth: local built-in auth (not OIDC/proxy auth)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions