Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Plugins

Notices

Reply
 
Thread Tools Search this Thread
Old 03-29-2013, 12:35 PM   #421
aragornnyc
Junior Member
aragornnyc began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Dec 2010
Device: NOOKcolor
Modify ePub failed

Sorry if i'm not asking the question correctly or in the right forum, but just recently ( last few days) i'm getting this error message...I've been using your plug-in for over a year with no problems



calibre, version 0.9.25
ERROR: Modify ePub failed: No ePub files were updated

Modify ePubs
Logfile for book ID 2153 (xxxxx / xxxxxx)
2153
Modifying: C:\Users\xxxxx\AppData\Local\Temp\calibre__si2hk\7 lvqoo_modify_epub\2153.epub
Updating metadata and cover
Parsing xml file: OEBPS/content.opf
Parsing xml file: OEBPS/toc.ncx
Looking for unused images
Looking for redundant entries in manifest
Looking for unmanifested files
xxxxxxx - ERROR: Traceback (most recent call last):
File "calibre_plugins.modify_epub.modify", line 72, in process_book
File "calibre_plugins.modify_epub.modify", line 132, in _process_book
File "calibre_plugins.modify_epub.modify", line 246, in _process_unmanifested_files
File "calibre_plugins.modify_epub.container", line 132, in get_manifest_item_for_name
File "calibre_plugins.modify_epub.container", line 175, in name_to_href
File "urllib.py", line 1268, in quote
KeyError: u'\u201c'

ePub not changed after 0.65 seconds


thanks for any help you may provide
aragornnyc is offline   Reply With Quote
Old 03-29-2013, 02:15 PM   #422
theducks
Grand Sorcerer
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 13,607
Karma: 5126946
Join Date: Aug 2009
Location: The (original) Silicon Valley, USA
Device: Galaxy Tab 2, Astak Pocket Pro, K4NT
You are in the correct place.
The last line implies a Unicode(d) (file name?) problem with that book

The PI Author frequents this forum and will have insight.
theducks is offline   Reply With Quote
 
Enthusiast
Old 04-13-2013, 11:55 AM   #423
travger
Evangelist
travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.travger ought to be getting tired of karma fortunes by now.
 
travger's Avatar
 
Posts: 463
Karma: 270594
Join Date: Aug 2010
Device: palm tx, Windows XP
Something funny happened:

Changed css in Sigil, added book to Calibre. OK
Replaced cover and flattened toc. OK
Smartened punctuation. NOT ok - formatting went away.
Dragged book again to Calibre and tried all 3 together - again no formatting.
Checked with Sigil - link to 0.css was gone.
Opened the not-in-Calibre copy in Sigil, added cover.
Flattened toc and smartened punctuation (maybe with the same pass) - and now it worked OK.

Book was Null-ABC (Piper) from Gutenberg.

Just a mystery and a warning: do not trust blindly without checking.
travger is offline   Reply With Quote
Old 04-15-2013, 10:58 AM   #424
kiwidude
calibre/Sigil Developer
kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.
 
Posts: 4,220
Karma: 1333994
Join Date: Oct 2010
Location: London, UK
Device: Kindle Paperwhite 3G, iPad 3, iPad Air
@travger - not much I can do without an example epub that replicates the issue. I will say it sounds unusual, and not once have I seen or had reported anything similar. But without an example epub and exact steps this isn't something I will look into.

@aragornnyc - again without the example epub with the problem there is nothing I can do. If you send me a PM with a link to it, or email it to me I can take a look.
kiwidude is offline   Reply With Quote
Old 04-15-2013, 11:50 AM   #425
JSWolf
Suspended
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.
 
Posts: 35,392
Karma: 16147088
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Quote:
Originally Posted by travger View Post
Something funny happened:

Changed css in Sigil, added book to Calibre. OK
Replaced cover and flattened toc. OK
Smartened punctuation. NOT ok - formatting went away.
Dragged book again to Calibre and tried all 3 together - again no formatting.
Checked with Sigil - link to 0.css was gone.
Opened the not-in-Calibre copy in Sigil, added cover.
Flattened toc and smartened punctuation (maybe with the same pass) - and now it worked OK.

Book was Null-ABC (Piper) from Gutenberg.

Just a mystery and a warning: do not trust blindly without checking.
Check the ePub with ADE. ADE is picky about errors in the CSS. So if you left out even one semicolon, it won't display the formatting in the CSS. Sigil is not so picky so even if you have a CSS error, it will display if it can.
JSWolf is offline   Reply With Quote
Old 05-16-2013, 04:31 AM   #426
sts
Junior Member
sts began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Dec 2012
Location: Germany
Device: Sony PRS 650 (retired), Kobo Aura HD
More a feature request than a bug report, but:

I mostly use ModifyEpub to get rid of the embedded fonts. I love my LexiaDaMa font on my device (Sony PRS-650 with PRS+), and want it to show up in all of my books. If the CSS only consists of either no font-family tags at all or just "font-family:serif;", all is okay. But if there is an embedded font with "font-family:<embedded_font>,serif;" in the CSS, my device will not use LexiaDaMa anymore, but the embedded font (well, what a surprise! ;-) ).

ModifyEpub correctly removes the embedded font, the references in the manifest, and the font-face tags in the CSS. But it leaves the font-family tags with now orphaned <embedded_font>-entries.
The Sony then finds a font-family tag with a font that doesn't exist anymore, uses the fallback "serif" and shows the internal standard font, not the LexiaDaMa. I have to manually edit the CSS and change the tag to "font-family:serif;" to get the LexiaDaMa.

Is there any chance to add this functionality to the procedure "remove embedded fonts"? Normally, the orphaned font entry shouldn't be a problem, the engine uses the next entry as fallback, but some devices are picky about that. A clean font-family tag would save some hassle now and then.

Thx in advance
Steffen
sts is offline   Reply With Quote
Old 05-17-2013, 09:28 AM   #427
edwdecarlo
Enthusiast
edwdecarlo began at the beginning.
 
Posts: 31
Karma: 41
Join Date: Nov 2011
Location: North Kingstown, RI, USA
Device: Kindle DX,Fire HD
Quote:
Originally Posted by sts View Post
Is there any chance to add this functionality to the procedure "remove embedded fonts"?
Steffen, this may be an alternate solution:

Calibre has built in functionality to either imbed a font and/or remove the CSS font definitions. This can be done through the Convert Books functionality. I do this for my Mobi files with success, so it should work for ePub files as well.

Use the Convert Books screen, and and set the Output format to ePub (you can convert ePub to ePub). Select Look & Feel. Click the Filter Style Information tab (in the middle of the page). Check the Font box. Then click OK to run the conversion. This should generate a new ePub file with CSS font defs removed, so it will pick up the default font on your device. Note: It will also make any other changes specified for the conversion, so you will want to back up your book file prior to testing out. See screen shot below.

Important: I remember there being an option on calibre that, when performing a conversion to an existing format, a backup/rename of the original file would be performed. I can't find this option anymore, but it appears that calibre does the backup in this case. Does anyone know if the option was removed and this is now the standard behavior?

If this works for you, you can set up the defaults for this screen via Preferences -> Change calibre behavior -> Conversion: Common Options

Hope this is helpful.
Attached Thumbnails
Click image for larger version

Name:	convert.jpg
Views:	50
Size:	171.7 KB
ID:	105965  
edwdecarlo is offline   Reply With Quote
Old 05-17-2013, 09:04 PM   #428
JSWolf
Suspended
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.
 
Posts: 35,392
Karma: 16147088
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Quote:
Originally Posted by edwdecarlo View Post
(you can convert ePub to ePub)
It is always a bad idea to do ePub > ePub unless you have to and in this case, it's not needed. It's best to use Tweak eBook to edit the CSS directly.
JSWolf is offline   Reply With Quote
Old 05-20-2013, 05:33 AM   #429
Hoods7070
Zealot
Hoods7070 can name that song in three notesHoods7070 can name that song in three notesHoods7070 can name that song in three notesHoods7070 can name that song in three notesHoods7070 can name that song in three notesHoods7070 can name that song in three notesHoods7070 can name that song in three notesHoods7070 can name that song in three notesHoods7070 can name that song in three notesHoods7070 can name that song in three notesHoods7070 can name that song in three notes
 
Posts: 105
Karma: 24430
Join Date: Mar 2012
Location: Australia
Device: Nexus 7"
Reversing the order of Author name in jacket

Hi

I'm not the most experienced html/css person, but by trial and error I have managed to edit the xhtml and css files to display jackets the way I want them, and am really chuffed with the result. However, although I choose to display my author names as Surname>Firstnames(s) within Calibre, I would very much like to be able to automatically reverse that order when using Modify Epub to insert/replace a metadata jacket.

Is this possible? If not, is there any chance of this feature being added to Modify Epub?

Many thanks
Hoods7070 is offline   Reply With Quote
Old 05-21-2013, 05:39 AM   #430
sts
Junior Member
sts began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Dec 2012
Location: Germany
Device: Sony PRS 650 (retired), Kobo Aura HD
Quote:
Originally Posted by edwdecarlo View Post
Calibre has built in functionality to either imbed a font and/or remove the CSS font definitions. This can be done through the Convert Books functionality.
Conversion is not a desirable alternative, I want to avoid any conversions as much as possible.

I use ModifyEpub to clear the file (remove artifacts, orphaned images, adobe junk, metadata jackets). Then I open the epub "in zip mode" (Speed Commander correctly recognizes epub as zip and handles it like a directory), and take a look into the CSS. If it is only one, I edit it directly. If every chapter has its own (sometimes more than 100 CSS files), I extract them all, run a RegEx Replace (with the very nice little tool "grepWin"), and copy them back into the zip.

My changes involve "font-family" (on global classes), "text-indent" (I like 1.5em), text-align (I like justify, which is set by the reader, but only if there's no "left" in the CSS) and margins (page and body is handled by ModifyEpub, but often there are margins on div or p, I don't like empty space between paragraphs).
sts is offline   Reply With Quote
Old 05-23-2013, 09:56 AM   #431
krkrskiafkono
Junior Member
krkrskiafkono began at the beginning.
 
Posts: 2
Karma: 10
Join Date: May 2013
Device: Kobo Aura
The following is maybe a feature request:

Since I now do own a Kobo Aura, and Kobo defaults widows+orphans to annoying 3, I want to change them in a bulk operation for the whole library. Is this already possible with modify epub?

If not, could this be implemented? I think of a feature to add every line defined in Calibres "extra css" field to the CSS of the book, e.g., I defined the following lines:

Code:
body {
    widows: 0;
    orphans: 0;
}
So when I now check "modify @page and body margin styles", this will result in a css with added also all lines defined in "extra css" of Calibre.
krkrskiafkono is offline   Reply With Quote
Old 05-23-2013, 01:19 PM   #432
JSWolf
Suspended
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.
 
Posts: 35,392
Karma: 16147088
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
I like the widows/orphans idea.
JSWolf is offline   Reply With Quote
Old 05-24-2013, 05:21 AM   #433
chrisparker
Connoisseur
chrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercisechrisparker juggles running chainsaws for a bit of light exercise
 
chrisparker's Avatar
 
Posts: 62
Karma: 38776
Join Date: May 2011
Location: London, UK
Device: iPad mini, Kobo Aura HD, Nook ST Glowlight
Great idea!
chrisparker is offline   Reply With Quote
Old 06-08-2013, 09:28 PM   #434
BetterRed
null operator
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 2,317
Karma: 1664976
Join Date: Mar 2012
Location: NSW Australia
Device: none
Is this PI available at the CLI via calibre-debug and what arguments do I need to know about.

If anyone can post an example of using this PI at the CLI that would be much appreciated.

Thanks BR
BetterRed is offline   Reply With Quote
Old 06-08-2013, 10:00 PM   #435
jackie_w
Wizard
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 2,572
Karma: 3784089
Join Date: Sep 2009
Location: UK
Device: Sony PRS-350/650/T1, PB360, Kobo Glo/AuraHD/Aura6"
Quote:
Originally Posted by BetterRed View Post
Is this PI available at the CLI via calibre-debug and what arguments do I need to know about.

If anyone can post an example of using this PI at the CLI that would be much appreciated.
I don't use the CLI myself but if you look inside the Modify ePub.zip archive there is a directory called commandline. There are some examples and documentation in there. The me.py file shows all the various commandline options.
jackie_w is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[GUI Plugin] Open With kiwidude Plugins 216 03-18-2014 02:23 AM
[GUI Plugin] Quality Check kiwidude Plugins 724 03-15-2014 04:40 PM
[GUI Plugin] Manage Series kiwidude Plugins 110 09-20-2013 06:52 PM
Modify ePub plugin dev thread kiwidude Development 346 09-02-2013 05:14 PM
[GUI Plugin] Plugin Updater **Deprecated** kiwidude Plugins 159 06-19-2011 12:27 PM


All times are GMT -4. The time now is 12:23 PM.


MobileRead.com is a privately owned, operated and funded community.