Hi everyone, I’m trying to organise collections on my jailbroken KOA3 (FW 5.14.1) using Calibre 7.26.0 [running on macOS Ventura 13.6.3], the Kindle Collection plugin (1.7.29) & LibrarianSync – and have run into an issue I'm really hoping someone can help me with.
I want to use the "
Edit Collections manually..." option of the Kindle Collections plug-in. If I understand correctly a QT6 patch is required, so I've edited the plug-in's
utilities.py file as per
dmeyer0's instructions [
post #430] and rezipped the folder etc.
Unfortunately after patching & rezipping, the plug-in was no longer installed as far as Calibre was concerned. So I tried "Load plugin from file” but that failed, with the following message:
ERROR: Unhandled exception:
<b>InvalidPlugin</b>:The plugin in '/Users/.../Kindle Collections.zip' is invalid.
It does not contain a top-level __init__.py file
I unzipped the plugin to check the files, and yes, the
__init__.py file was definitely still there.
Just in case the problem was the compression utility I was using, I did try several different tools to rezip the folder, but always got the same error message. Finally a friend figured out how to use the calibre-customize command line tool with the build-plugin option to zip and update the plugin successfully.
However, when I now try using the plugin to edit collections manually, I get the following error:
Spoiler:
ERROR: Unhandled exception:
<b>AttributeError</b>:type object 'Qt' has no attribute 'ItemFlags'
calibre 7.26 embedded-python: True
macOS-13.6.3-arm64-arm-64bit Darwin ('64bit', '')
('Darwin', '22.6.0', 'Darwin Kernel Version 22.6.0: Tue Nov 7 21:42:31 PST 2023; root:xnu-8796.141.3.702.9~2/RELEASE_ARM64_T8112')
Python 3.11.5
OSX: ('13.6.3', ('', '', ''), 'arm64')
Interface language: None
EXE path: /Applications/calibre.app/Contents/MacOS/calibre
Successfully initialized third party plugins: DeDRM (10, 0, 3) && Comments Cleaner (1, 15, 0) && EpubMerge (3, 2, 0) && EpubSplit (3, 10, 0) && Generate Cover (2, 3, 5) && Goodreads (1, 8, 2) && Kindle Collections (1, 7, 29) && Kindle hi-res covers (0, 5, 1) && Manage Series (1, 5, 2) && Quality Check (1, 13, 16) && Reading List (1, 15, 4) && Resize Cover (1, 2, 1)
Traceback (most recent call last):
File "calibre_plugins.kindle_collections.kindle_edit_co llections", line 333, in collection_combo_index_changed
self.refresh_table(collection)
File "calibre_plugins.kindle_collections.kindle_edit_co llections", line 406, in refresh_table
self.edit_w._table.populate_table(self.sorted_book _codes, self.book_details, self.sort_field, self.sort_order)
File "calibre_plugins.kindle_collections.kindle_edit_co llections", line 530, in populate_table
self.populate_table_row(row, row_data[index])
File "calibre_plugins.kindle_collections.kindle_edit_co llections", line 554, in populate_table_row
item = CheckableTableWidgetItem(data['include'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "calibre_plugins.kindle_collections.utilities" , line 247, in __init__
self.setFlags(Qt.ItemFlag(Qt.ItemIsSelectable | Qt.ItemIsUserCheckable | Qt.ItemIsEnabled ))
^^^^^^^^^^^^
AttributeError: type object 'Qt' has no attribute 'ItemFlags'
What's confusing is that in both the utilities.py file, & the trace log above, 'ItemFlags' doesn't exist. I've double checked, & have definitely replaced Qt.ItemFlags with Qt.ItemFlag, as per dmeyer0's instructions.
Any suggestions on why this exception is happening, and how to fix it? I'd dearly love to get this working on my KOA3, so any help would be greatly appreciated.
Thanks everyone!