Bug 32602

Summary: Calibre is missing a dependancy on python3-xxhash
Product: Mageia Reporter: Stéphane Pontier <stephane.pontier>
Component: RPM PackagesAssignee: Stig-Ørjan Smelror <smelror>
Status: NEW --- QA Contact:
Severity: normal    
Priority: Normal CC: geex+mageia, geiger.david68210
Version: Cauldron   
Target Milestone: ---   
Hardware: All   
OS: Linux   
URL: https://calibre-ebook.com/
Whiteboard:
Source RPM: calibre-7.1.0-1.mga10.src.rpm CVE:
Status comment:

Description Stéphane Pontier 2023-12-07 19:32:50 CET
Description of problem:

Calibre does not launch.

Version-Release number of selected component (if applicable):

calibre-7.1.0-1.mga10

How reproducible:

Always

Steps to Reproduce:
1. launch calibre
2. read the error:

Traceback (most recent call last):
  File "/usr/bin/calibre", line 21, in <module>
    sys.exit(calibre())
  File "/usr/lib64/calibre/calibre/gui_launch.py", line 72, in calibre
    main(args)
  File "/usr/lib64/calibre/calibre/gui2/main.py", line 555, in main
    run_main(app, opts, args, gui_debug, si, retry_communicate=True)
  File "/usr/lib64/calibre/calibre/gui2/main.py", line 567, in run_main
    return run_gui(opts, args, app, gui_debug=gui_debug)
  File "/usr/lib64/calibre/calibre/gui2/main.py", line 405, in run_gui
    run_gui_(opts, args, app, gui_debug)
  File "/usr/lib64/calibre/calibre/gui2/main.py", line 415, in run_gui_
    from calibre.gui2.ui import Main
  File "/usr/lib64/calibre/calibre/gui2/ui.py", line 31, in <module>
    from calibre.db.legacy import LibraryDatabase
  File "/usr/lib64/calibre/calibre/db/legacy.py", line 21, in <module>
    from calibre.db.cache import Cache
  File "/usr/lib64/calibre/calibre/db/cache.py", line 42, in <module>
    from calibre.db.notes.connect import copy_marked_up_text
  File "/usr/lib64/calibre/calibre/db/notes/connect.py", line 8, in <module>
    import xxhash
ModuleNotFoundError: No module named 'xxhash'

FIX:

installing the package python3-xxhash resolve the problem.
Comment 1 katnatek 2023-12-09 01:24:33 CET
@Stig you are listed as maintainer of this package, assigning to you

Assignee: bugsquad => smelror

Comment 2 Guillaume Bedot 2023-12-09 21:02:45 CET
If you haven't yet a library (first install), it launches but the first next button does nothing...

CC: (none) => geex+mageia

Comment 3 Stig-Ørjan Smelror 2023-12-10 20:27:35 CET
(In reply to Guillaume Bedot from comment #2)
> If you haven't yet a library (first install), it launches but the first next
> button does nothing...

What do you see if you launch calibre from the command line?
Comment 4 Stig-Ørjan Smelror 2023-12-10 20:30:19 CET
python-xxhash has been imported to Cauldron and is present in the spec file for calibre.
Now waiting for the complete rebuild with Python 3.12.
Comment 5 Guillaume Bedot 2023-12-10 21:09:35 CET
# urpme python3-xxhash

$ rm -rf Bibliothèque\ calibre .config/calibre

$ calibre
qt.qpa.plugin: Could not find the Qt platform plugin "wayland" in ""

Here a window "calibre Assistant de bienvenue" appears.
I click Suivant, with defaults, this appears in the console, with the same module error as Stéphane.

Traceback (most recent call last):
  File "/usr/lib64/calibre/calibre/gui2/wizard/__init__.py", line 782, in validatePage
    if not self.is_library_dir_suitable(newloc):
  File "/usr/lib64/calibre/calibre/gui2/wizard/__init__.py", line 774, in is_library_dir_suitable
    from calibre.db.legacy import LibraryDatabase
  File "/usr/lib64/calibre/calibre/db/legacy.py", line 21, in <module>
    from calibre.db.cache import Cache
  File "/usr/lib64/calibre/calibre/db/cache.py", line 42, in <module>
    from calibre.db.notes.connect import copy_marked_up_text
  File "/usr/lib64/calibre/calibre/db/notes/connect.py", line 8, in <module>
    import xxhash
ModuleNotFoundError: No module named 'xxhash'
Comment 6 Guillaume Bedot 2023-12-10 21:20:01 CET
If I click Annuler, and run calibre again, it gives the exact same output as Stéphane. And, of course, installing said module fixes the isssue.
Comment 7 Stig-Ørjan Smelror 2024-01-01 14:58:23 CET
Calibre 7.2.0 has been pushed to Cauldron with xxhash added as a required package and is also built for Python 3.12.x.
Comment 8 David GEIGER 2024-01-01 15:55:09 CET
Nop python3-xxhash was not added a runtime dependency but right now yes in upcoming calibre-7.2.0-2.mga10 update.

CC: (none) => geiger.david68210

Comment 9 Guillaume Bedot 2024-01-02 10:11:26 CET
The update pulled the dependency.

On gnome, a window asks to choose the library folder, but then calibre closes. It has to be run again to open the library.