Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Plugins

Notices

Reply
 
Thread Tools Search this Thread
Old 12-31-2021, 02:49 AM   #1
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 40,721
Karma: 18247461
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Plugin devs: Upcoming migration to Qt 6

calibre 6 (to be released in a few months), will be based on Qt 6. Qt 6 has various minor incompatibilities with Qt 5, many of which I have implemented compatibility layers for. However if your plugins use Qt then they need to be tested against Qt 6. Beta builds of calibre you can use for that purpose are available here: https://download.calibre-ebook.com/betas/

As of 5.99.3 the betas have support for proper icon themeing with support for using different icon themes for light and dark mode and calibre switches between them automatically. In order to use icons from themes that support your plugin you should pass the plugin name to the get_icons() function to load an icon. For example:

Code:
icon = get_icons('owp_sigil.png', 'Open With')
this will load the owp_sigil.png plugin from the users installed icon theme, if present, falling back to the image in the plugin zip file. Note that if you use kiwidude's code for loading icons, you will need to adjust it, as the way it loads themed icons will no longer work.

Notes about the betas:

1) 32 bit support is removed from calibre 6, because Qt 6 drops it. This means that if you use the windows MSI installer, it will uninstall existing calibre 32-bit and replace it with calibre 64-bit. calibre Portable is also now 64 bit.

2) calibre 6 has ARM support, the macOS build is now a universal binary with ARM and Intel and there is a Linux ARM64 build available as well.

Note that you dont need to change import statements as importing from PyQt5 automatically imports from PyQt6 instead when running calibre 6.

If in your testing you find some incompatibilities, do let me know and I will see if they can be patched in https://github.com/kovidgoyal/calibr...yqt6_compat.py

If you are running calibre from source, use the qt6 branch rather than master, with the Qt6 builds.

Last edited by kovidgoyal; 01-12-2022 at 09:49 AM.
kovidgoyal is offline   Reply With Quote
Old 12-31-2021, 07:24 AM   #2
Moonbase59
Zealot
Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.
 
Moonbase59's Avatar
 
Posts: 111
Karma: 196896
Join Date: Oct 2021
Location: Germany
Device: Tolino Vision 5, Tolino Tab 8"
You mention compatibility layers. So will it be possible to run Calibre 6 on Debian/Ubuntu derivatives like Linux Mint 20, that only offer Qt5?
Moonbase59 is offline   Reply With Quote
Advert
Old 12-31-2021, 08:45 AM   #3
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 40,721
Karma: 18247461
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
calibre comes with its own copy of Qt, it doesn't care what Qt is on the host system. You do however need a recent enough version of glibc, which for calibre 6 is IIRC 2.31 which will be about two years old at the time of calibre 6 release.
kovidgoyal is offline   Reply With Quote
Old 12-31-2021, 09:57 AM   #4
Moonbase59
Zealot
Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.Moonbase59 can program the VCR without an owner's manual.
 
Moonbase59's Avatar
 
Posts: 111
Karma: 196896
Join Date: Oct 2021
Location: Germany
Device: Tolino Vision 5, Tolino Tab 8"
Thanks! Yes, my glibc is 2.31 (Linux Mint 20.2).
Moonbase59 is offline   Reply With Quote
Old 12-31-2021, 11:41 AM   #5
thiago.eec
Fanatic
thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.
 
Posts: 589
Karma: 155092
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
Hi, Kovid.

Is it possible to run from source using the Portable binary? It didn't seem to work here.
Since I cannot use a 32bit version, I choose to do my testing with the Portable version, so it wouldn't interfere with my main calibre.
thiago.eec is offline   Reply With Quote
Advert
Old 12-31-2021, 12:23 PM   #6
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 40,721
Karma: 18247461
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Yeah it should be fine to run from source with portable. Make sure you are running the qt6 branch not master though.
kovidgoyal is offline   Reply With Quote
Old 12-31-2021, 01:08 PM   #7
thiago.eec
Fanatic
thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.
 
Posts: 589
Karma: 155092
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
Quote:
Originally Posted by kovidgoyal View Post
Yeah it should be fine to run from source with portable. Make sure you are running the qt6 branch not master though.
My bad. It works fine.
thiago.eec is offline   Reply With Quote
Old 12-31-2021, 02:00 PM   #8
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 19,336
Karma: 94111803
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Forma, Clara HD, Lenovo M8 FHD, Paperwhite 4, Tolino epos
The portable version runs okay but the install version gives an error message:

Quote:
calibre, version 5.34.0
ERROR: Startup error: There was an error during calibre startup. Parts of calibre may not function. Click "Show details" to learn more.

Traceback (most recent call last):
File "calibre\gui2\main.py", line 316, in initialize_db_stage2
File "calibre\gui2\main.py", line 259, in start_gui
File "calibre\gui2\ui.py", line 236, in initialize
File "calibre\gui2\layout.py", line 348, in init_main_window_mixin
File "calibre\gui2\bars.py", line 640, in __init__
File "calibre\gui2\bars.py", line 671, in init_bars
File "calibre\gui2\bars.py", line 212, in init_bar
File "calibre\gui2\bars.py", line 230, in setup_tool_button
TypeError: QToolButton.setPopupMode(): argument 1 has unexpected type 'int'
After this, neither the portable or installed version will launch until I do a restart.

Quote:
calibre, version 5.34.0
ERROR: Contacting calibre failed: Failed to contact running instance of calibre, try restarting calibre

Failed to connect to Listener at: \\.\pipe\CalibreGUI-Davidx with error: QLocalSocket::connectToServer: Invalid name

b'launched:["calibre.exe"]'
Edit: Issue traced to the JobSpy plugin which was installed for the installed calibre but not for the portable calibre.

Last edited by DNSB; 12-31-2021 at 02:41 PM.
DNSB is online now   Reply With Quote
Old 12-31-2021, 02:31 PM   #9
thiago.eec
Fanatic
thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.
 
Posts: 589
Karma: 155092
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
Drop actions on main list are not working either:

Code:
calibre, version 5.34.0
ERRO: Exceção sem tratamento: <b>TypeError</b>:int() argument must be a string, a bytes-like object or a real number, not 'DropAction'

calibre 5.34 Portable embedded-python: True
Windows-10-10.0.19041 Windows ('64bit', 'WindowsPE')
('Windows', '10', '10.0.19041')
Python 3.10.1
Windows: ('10', '10.0.19041', '', 'Multiprocessor Free')
Interface language: pt_BR
Successfully initialized third party plugins: ACE (1, 1, 4) && EpubCheck (0, 2, 3) && Skoob Books (1, 5, 3) && Skoob Sync (0, 4, 1)
Traceback (most recent call last):
  File "calibre\gui2\library\alternate_views.py", line 223, in dragEnterEvent
TypeError: int() argument must be a string, a bytes-like object or a real number, not 'DropAction'
thiago.eec is offline   Reply With Quote
Old 12-31-2021, 10:15 PM   #10
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 40,721
Karma: 18247461
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Both of those issues will be fixed in the next beta, thanks.
kovidgoyal is offline   Reply With Quote
Old 12-31-2021, 11:39 PM   #11
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 19,336
Karma: 94111803
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Forma, Clara HD, Lenovo M8 FHD, Paperwhite 4, Tolino epos
I would also like to mention that many of the plugins while not blatantly failing, do not show on the toolbars and when I attempt to customize them, I get a popup that calibre needs to restart before I can customize the plugin. EpubMerge, FanFicFare, KoboUtilities, ModifyEpub and QualityCheck are some of the culprits. Seeing as I did a clean install of CalibrePortable and restarted after each plugin install, I'm rather doubtful that another restart of calibre will help.
DNSB is online now   Reply With Quote
Old 01-01-2022, 02:19 AM   #12
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 40,721
Karma: 18247461
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Updated beta (5.99.0) fixing all issues reported so far. @DNSB: With this beta running the configure dialog of EpubMerge works for me.
kovidgoyal is offline   Reply With Quote
Old 01-01-2022, 04:04 AM   #13
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 19,336
Karma: 94111803
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Forma, Clara HD, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by kovidgoyal View Post
Updated beta (5.99.0) fixing all issues reported so far. @DNSB: With this beta running the configure dialog of EpubMerge works for me.
Time to download it and take it out for a spin.
DNSB is online now   Reply With Quote
Old 01-01-2022, 06:54 AM   #14
jackie_w
Grand Sorcerer
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 5,907
Karma: 14808080
Join Date: Sep 2009
Location: UK
Device: Kobo: H2O, GloHD, KA1, ClaraHD, Forma, Libra2
I can't drag-drop to the calibre library main window to add a new book.

Code:
calibre, version 5.99.0
ERROR: Unhandled exception: <b>AttributeError</b>:'QDragEnterEvent' object has no attribute 'pos'

calibre 5.99 Portable embedded-python: True
Windows-10-10.0.19042 Windows ('64bit', 'WindowsPE')
('Windows', '10', '10.0.19042')
Python 3.10.1
Windows: ('10', '10.0.19042', '', 'Multiprocessor Free')
Interface language: en_GB
Successfully initialized third party plugins: EpubCheck (0, 2, 3) && EpubMetadata (0, 0, 6) && EpubXCustomMetadata (0, 0, 7) && JS_Editor_Tools (0, 3, 16) && JS_Editor_Utils (0, 0, 9) && JS_Modify_Epub (0, 0, 22) && KoboTouchExtended (3, 5, 4) && ScrambleEbook (0, 4, 5) && TTS to MP3 (0, 5, 10)
Traceback (most recent call last):
  File "calibre\gui2\bars.py", line 256, in dragEnterEvent
  File "calibre\gui2\bars.py", line 236, in check_iactions_for_drag
AttributeError: 'QDragEnterEvent' object has no attribute 'pos'
ETA: Hold off. Actually I tried a second time and it worked

ETA2: It seems to be more complicated than that. I have the Book Details panel under the library window not down the right-hand side.

If the trajectory of my drag tries to pass across the Book details panel then the above error happens.

If the drag trajectory avoids passing over Book Details, by entering the library window from the side, then there is no error.

Last edited by jackie_w; 01-01-2022 at 07:09 AM. Reason: ETA2
jackie_w is offline   Reply With Quote
Old 01-01-2022, 07:34 AM   #15
thiago.eec
Fanatic
thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.thiago.eec can grok the meaning of the universe.
 
Posts: 589
Karma: 155092
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
I can drag-and-drop books to the main list, but it still fails if I drag-and-drop one book on another:

Code:
calibre, version 5.99.0
ERRO: Exceção sem tratamento: <b>AttributeError</b>:'QDropEvent' object has no attribute 'pos'

calibre 5.99 Portable embedded-python: True
Windows-10-10.0.19041 Windows ('64bit', 'WindowsPE')
('Windows', '10', '10.0.19041')
Python 3.10.1
Windows: ('10', '10.0.19041', '', 'Multiprocessor Free')
Interface language: pt_BR
Successfully initialized third party plugins: ACE (1, 1, 4) && EpubCheck (0, 2, 3) && Skoob Books (1, 5, 3) && Skoob Sync (0, 4, 1)
Traceback (most recent call last):
  File "calibre\gui2\library\alternate_views.py", line 236, in dropEvent
AttributeError: 'QDropEvent' object has no attribute 'pos'
Also, when I changed my calibre interface style to System Default (which turns it to Light Theme), I got this new error when hovering some parts of the interface, like the column headers:

Code:
calibre, version 5.99.0
ERRO: Exceção sem tratamento: <b>AttributeError</b>:'QHoverEvent' object has no attribute 'pos'

calibre 5.99 Portable embedded-python: True
Windows-10-10.0.19041 Windows ('64bit', 'WindowsPE')
('Windows', '10', '10.0.19041')
Python 3.10.1
Windows: ('10', '10.0.19041', '', 'Multiprocessor Free')
Interface language: pt_BR
Successfully initialized third party plugins: ACE (1, 1, 4) && EpubCheck (0, 2, 3) && Skoob Books (1, 5, 4) && Skoob Sync (0, 4, 1)
Traceback (most recent call last):
  File "calibre\gui2\library\views.py", line 64, in event
AttributeError: 'QHoverEvent' object has no attribute 'pos'

Last edited by thiago.eec; 01-01-2022 at 08:39 AM. Reason: Add another error
thiago.eec is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Suggestion for PI Devs BetterRed Plugins 11 09-27-2020 06:18 PM
Attn plugin devs: porting to python 3 kovidgoyal Plugins 129 06-16-2020 01:31 AM
Attention All Plugin Devs: Remove vestiges from python 2? KevinH Plugins 11 05-29-2020 03:16 PM
Plugin Devs: Should we include a License or COPYING file? KevinH Plugins 3 08-15-2017 01:09 PM
New Plugin Features in the upcoming Sigil 0.8.900 KevinH Plugins 6 09-14-2015 02:48 PM


All times are GMT -4. The time now is 06:00 PM.


MobileRead.com is a privately owned, operated and funded community.