View Single Post
Old 09-26-2020, 07:24 PM   #1442
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 80,044
Karma: 147977995
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by chaley View Post
@DNSB: thanks for the exception log, and @JSWolf: thanks for the copy of an offending book. That let me find another case where something the plugin calls sometimes wants a byte string instead of a "normal" string. The attached version takes care of that.

I tested it with your book that specifies the encoding, and with one of my books that does not. I checked every box. No fatal failures. The plugin did complain about lacking a cover in your book.

May it please be that this one works.
It seems to work in 5.0.1 but (I know annoying) in 4.23 (using the eBook I sent you), I get...
Code:
calibre, version 4.23.0
ERROR: Modify ePub failed: No ePub files were updated

Modify ePubs
Logfile for book ID 2244 (The Measure of the Magic / Terry Brooks)
2244
  Modifying:  C:\Users\help\AppData\Local\Temp\calibre_vywtfv\kerujr_modify_epub\2244.epub
Parsing xml file: Broo_9780345529213_epub_opf_r1.opf
Parsing xml file: Broo_9780345529213_epub_ncx_r1.ncx
	Looking for broken links in the NCX
	Looking for Adobe xpgt files and links to remove
	  Found xpgt file to to remove: OEBPS/page-template.xpgt
	  Manifest item removed: OEBPS/page-template.xpgt (page)
The Measure of the Magic - ERROR: Traceback (most recent call last):
  File "calibre_plugins.modify_epub.modify", line 79, in process_book
  File "calibre_plugins.modify_epub.modify", line 141, in _process_book
  File "calibre_plugins.modify_epub.modify", line 365, in _remove_xpgt_files
  File "calibre_plugins.modify_epub.container", line 232, in get_parsed_etree
  File "calibre_plugins.modify_epub.container", line 222, in get_raw
  File "encodings\cp1252.py", line 23, in decode
UnicodeDecodeError: 'charmap' codec can't decode byte 0x9d in position 1317: character maps to <undefined>

ePub not changed after 0.71 seconds
JSWolf is offline   Reply With Quote