Belgian Pommes Frites
Posts: 122
Karma: 35038
Join Date: Jan 2012
Device: Pocketbook Touch HD
|
Hi Terisa,
I just discovered your normcomment plugin and it works well for me, as I like to remove as much formatting as possible. Thank you very much for making it available.
Unfortunately, I have just run into this problem. One book has the following comment:
<div><p></p><blockquote><p>As startling and powerful as when first published more than two decades ago, André Brink's classic novel, <em>A Dry White Season</em>, is an unflinching and unforgettable look at racial intolerance, the human condition, and the heavy price of morality.</p></blockquote><p>Ben Du Toit is a white schoolteacher in suburban Johannesburg in a dark time of intolerance and state-sanctioned apartheid. A simple, apolitical man, he believes in the essential fairness of the South African government and its policies—until the sudden arrest and subsequent "suicide" of a black janitor from Du Toit's school. Haunted by new questions and desperate to believe that the man's death was a tragic accident, Du Toit undertakes an investigation into the terrible affair—a quest for the truth that will have devastating consequences for the teacher and his family, as it draws him into a lethal morass of lies, corruption, and murder.</p></div>
And when I run your plugin I get the following error:
calibre, version 3.32.0
ERROR: Unhandled exception: <b>ValueError</b>:invalid literal for int() with base 10: '8212a'
calibre 3.32 [64bit] embedded-python: True is64bit: True
Windows-10-10.0.17763-SP0 Windows ('64bit', 'WindowsPE')
('Windows', '10', '10.0.17763')
Python 2.7.12+
Windows: ('10', '10.0.17763', 'SP0', u'Multiprocessor Free')
Interface language: en_GB
Successfully initialized third party plugins: Gather KFX-ZIP (from KFX Input) (1, 9, 0) && DeDRM (6, 6, 1) && Package KFX (from KFX Input) (1, 9, 0) && Fantastic Fiction (1, 2, 0) && Modify ePub (1, 3, 13) && Find Duplicates (1, 6, 3) && BOL_DE (0, 7, 5) && Quality Check (1, 9, 11) && Goodreads (1, 1, 16) && NormComment (0, 0, 2) && Diaps Editing Toolbag (0, 3, 5) && FictionDB (1, 0, 10) && EpubCheck (0, 1, 2) && Barnes & Noble (1, 2, 15) && KFX metadata reader (from KFX Input) (1, 9, 0) && KFX Input (1, 9, 0)
Traceback (most recent call last):
File "calibre_plugins.norm_comment.action", line 125, in _normalize_comment
File "calibre_plugins.norm_comment.action", line 154, in _do_replace_text
File "site-packages\calibre\utils\html2text.py", line 436, in html2text
File "site-packages\calibre\utils\html2text.py", line 430, in html2text_file
File "sgmllib.py", line 104, in feed
File "sgmllib.py", line 186, in goahead
File "site-packages\calibre\utils\html2text.py", line 200, in handle_charref
File "site-packages\calibre\utils\html2text.py", line 72, in charref
ValueError: invalid literal for int() with base 10: '8212a'
I have no idea what it all means. If you have time, I would appreciate it if you could look at it.
The version of your plugin installed is 0.0.2
Many thanks
|