View Single Post
Old 03-08-2022, 11:44 AM   #60
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,495
Karma: 8065348
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by JimmXinu View Post
calibre/master branch won't run from source for me using 5.38 binaries, gives:
Code:
  File "C:\Users\me\Desktop\nook\calibre\src\calibre\gui2\dialogs\choose_format_device_ui.py", line 9, in <module>
    from PyQt6 import QtCore, QtGui, QtWidgets
ModuleNotFoundError: No module named 'PyQt6'
Presumably something qt6 got into master.
Whenever you switch from V5 to the beta or back you must force recompilation of all the .ui files in calibre. Normally changes are automatically detected so that the *_ui.py files are regenerated, but the dates are 'wrong' when switching between branches so the files aren't rebuilt. The problem is discussed in posts starting with this one.

I know of two ways to force rebuilding the files:
  • Delete all *_ui.py files in calibre.gui2, then run calibre-debug -g.
  • Set the environment variable
    Code:
    set CALIBRE_FORCE_BUILD_UI_FORMS=1
    before you run calibre-debug -g. This is what I do by setting the env var in the script I use to start calibre in debug mode. It tells calibre to ignore the timestamps and rebuild the _ui.py files.

Last edited by chaley; 03-08-2022 at 12:12 PM.
chaley is offline   Reply With Quote