View Single Post
Old 05-02-2020, 04:14 AM   #1349
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
Beta - Python 3 compatible

I promised one a long time ago, did the work, but, just keep forgetting to post it, Finally here it is, a Python 3 compatible beta of the Count Pages plugin.

The beta is completely compatible with the released version of calibre. And I have tested it with the previous Python 3 beta, and with the 4.99.5 beta released earlier. Nearly everything works.

The only problem I have is downloading the page count for some books from Goodreads. There is a problem on some pages that produce the error:

Code:
encoding not supported USC4 little endian, line 1, column 1
I assume it is an encoding issue on the site, but, I haven't worked out why or how to handle it.


Other than that, it is working for me. I am interested in here of success or problems with it in either the released version of calibre, or a Python 3 version. If there are any problems, please post the error from calibre and as much information as possible for me to reproduce it.

Edit: Kovid knew what the problem was. I have fixed the problem with the encoding and it works for all the test cases that I have. I have replaced the attached beta with version 1.9.2.

Last edited by BetterRed; 06-21-2020 at 06:36 PM. Reason: Remove beta attachments - now in the release
davidfor is offline   Reply With Quote