View Single Post
Old 05-16-2022, 12:20 AM   #1052
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by Huwaetzel View Post
Hi Davidfor - With my pocketbook PB741 with latest firmware and Ubuntu 22.04 I needed to use the beta to get annotations work at all. But there seems to be a problem with accessing the database because annotations does not find any book and no annotation in a book which is clearly annotated.

calibre, version 5.37.0
FEHLER: Unbehandelter Ausnahmefehler: <b>TypeError</b>:expected str, bytes or os.PathLike object, not NoneType

calibre 5.37 embedded-python: False is64bit: True
Linux-5.15.0-30-generic-x86_64-with-glibc2.35 Linux ('64bit', 'ELF')
('Linux', '5.15.0-30-generic', '#31-Ubuntu SMP Thu May 5 10:00:34 UTC 2022')
Python 3.10.4
Interface language: de
Successfully initialized third party plugins: DeACSM (0, 0, 15) && DeDRM (7, 2, 1) && Annotations (1, 17, 2) && DNB_DE (3, 1, 7) && Favourites Menu (1, 1, 0) && Find Duplicates (1, 9, 5) && KOReader Sync (0, 2, 7) && Pocketbook Tools (0, 9, 5)
Traceback (most recent call last):
File "calibre_plugins.annotations.action", line 363, in fetch_usb_connected_device_annotations
self.fetch_usb_device_annotations(self.get_connect ed_device_primary_name())
File "calibre_plugins.annotations.action", line 407, in fetch_usb_device_annotations
annotated_book_list = self.get_annotated_books_on_usb_device(reader_app)
File "calibre_plugins.annotations.action", line 624, in get_annotated_books_on_usb_device
ra.get_active_annotations()
File "/tmp/calibre_annotations_plugin/PocketBook.py", line 62, in get_active_annotations
File "/tmp/calibre_annotations_plugin/PocketBook.py", line 344, in _fetch_annotations
File "/tmp/calibre_annotations_plugin/PocketBook.py", line 363, in _read_database_annotations
File "/usr/lib/python3.10/posixpath.py", line 76, in join
a = os.fspath(a)
TypeError: expected str, bytes or os.PathLike object, not NoneType

I appreciate the work you are doing with this very universal annotation plugin. Keeping up with all the variants is probably a challenge, but also for me keeping track of annotations is crucial.

Please let me know, if you need further background or you want me to do a special debug.

Thank you
I don't have a PocketBook to test this. But, do they have some sort of "virtual" book? The line with the error is building a file path using data from the database on the device. One of those is a null value in the database for one of the books. That could happen if the book had some sort of different status such as it hasn't been downloaded from wherever PocketBook stores books. Or there is a special location for a particular type or source of books. I don't know how PocketBook works at all. For Kobo, they do both. Purchased books can have an entry in the database but the book is not actually downloaded, and when they are, they are stored in a specific location and the database entry has the file name, but, not the full path.

Hopefully @wold will be around and have an answer. Otherwise, I would need to see the database from the device to make a better guess.
davidfor is offline   Reply With Quote