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

Crash at startup #2673

Closed
jvoisin opened this issue Jan 24, 2023 · 5 comments
Closed

Crash at startup #2673

jvoisin opened this issue Jan 24, 2023 · 5 comments
Labels

Comments

@jvoisin
Copy link
Contributor

jvoisin commented Jan 24, 2023

Describe the bug/problem

Calibre-web is crashing on startup.

To Reproduce
Steps to reproduce the behavior:

  1. python3 /opt/calibre/cps.py
  2. get a crash

Logfile

/opt/calibre $ python3 /opt/calibre/cps.py
Traceback (most recent call last):
  File "/opt/calibre/cps.py", line 31, in <module>
    main()
  File "/opt/calibre/cps/main.py", line 26, in main
    app = create_app()
          ^^^^^^^^^^^^
  File "/opt/calibre/cps/__init__.py", line 175, in create_app
    from .schedule import register_scheduled_tasks, register_startup_tasks
  File "/opt/calibre/cps/schedule.py", line 22, in <module>
    from .services.background_scheduler import BackgroundScheduler, CronTrigger, use_APScheduler
ImportError: cannot import name 'CronTrigger' from 'cps.services.background_scheduler' (/opt/calibre/cps/services/background_scheduler.py)

This is likely due to e178efb

Expected behavior
No crash.

Environment (please complete the following information):

  • OS: Alpine Linux
  • Python version: python 3.11.1
  • Calibre-Web version: 4913f06
  • Docker container: None
  • Special Hardware: Nope
@OzzieIsaacs
Copy link
Collaborator

There is some problem with APScheduler, please try reinstalling it with pip

@jvoisin
Copy link
Contributor Author

jvoisin commented Jan 25, 2023

I'm using the one packaged in Alpine Linux, aka 3.9.1-r1.

e178efb added a check around trying to import CronTrigger, and is setting use_APScheduler = False otherwise. Maybe importing CronTrigger and DateTrigger from .services.background_scheduler should be gated behind use_APScheduler?

@faspina
Copy link

faspina commented Mar 1, 2023

is there a workaround for this.?

@OzzieIsaacs
Copy link
Collaborator

#2653

This is some problem with APScheduler, please try reinstalling it with pip

@dqylyln
Copy link

dqylyln commented May 11, 2023

after pip install apscheduler is work

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

No branches or pull requests

4 participants