I'm using the command-line tools that are installed with the MacOS X version of Calibre (v 0.4.85), and html2epub seems to be using a cached html document (codyw1003010030-8.html) instead of the XML file specified at runtime (collinsw155155.xml):
Code:
dsl81:/tmp matthew$ /usr/bin/html2epub -o /tmp/collinsw155155.epub --chapter-mark=both --cover=/tmp/collinsw155155.jpg -t "The Moonstone" -a "Wilkie Collins" /tmp/collinsw155155.xml
Building file list...
Parsing /tmp/codyw1003010030-8.html
Parsing /tmp/codyw1003010030-8_toc.html
Output written to /tmp/collinsw155155.epub
dsl81:/tmp matthew$ /usr/bin/html2epub -o /tmp/collinsw155155.epub --chapter-mark=both --cover=/tmp/collinsw155155.jpg -t "The Moonstone" -a "Wilkie Collins" -vvv /tmp/collinsw155155.xml
Building file list...
Found files...
HTMLFile:0:a:/tmp/codyw1003010030-8.html
HTMLFile:0:a:/tmp/codyw1003010030-8_toc.html
[INFO] __init__.pyo:297: Parsing /tmp/codyw1003010030-8.html
[DEBUG] __init__.pyo:297: Written processed HTML to /tmp/codyw1003010030-8.html-parsed.html
[DEBUG] __init__.pyo:297: Written processed HTML to /tmp/codyw1003010030-8.html-nocss.html
[INFO] __init__.pyo:297: Parsing /tmp/codyw1003010030-8_toc.html
[DEBUG] __init__.pyo:297: Written processed HTML to /tmp/codyw1003010030-8_toc.html-parsed.html
[DEBUG] __init__.pyo:297: Written processed HTML to /tmp/codyw1003010030-8_toc.html-nocss.html
Output written to /tmp/collinsw155155.epub
dsl81:/tmp matthew$ rm -f codyw1003010030-8.html
dsl81:/tmp matthew$ /usr/bin/html2epub -o /tmp/collinsw155155.epub --chapter-mark=both --cover=/tmp/collinsw155155.jpg -t "The Moonstone" -a "Wilkie Collins" -vvv /tmp/collinsw155155.xml
Building file list...
Traceback (most recent call last):
File "/Applications/calibre.app/Contents/Resources/loaders/html2epub.py", line 9, in <module>
main()
File "/Applications/calibre.app/Contents/Resources/lib/python2.5/site-packages.zip/calibre/ebooks/epub/from_html.py", line 165, in main
File "/Applications/calibre.app/Contents/Resources/lib/python2.5/site-packages.zip/calibre/ebooks/epub/from_html.py", line 91, in convert
File "/Applications/calibre.app/Contents/Resources/lib/python2.5/site-packages.zip/calibre/ebooks/html.py", line 616, in get_filelist
File "/Applications/calibre.app/Contents/Resources/lib/python2.5/site-packages.zip/calibre/ebooks/html.py", line 227, in opf_traverse
File "/Applications/calibre.app/Contents/Resources/lib/python2.5/site-packages.zip/calibre/ebooks/html.py", line 112, in __init__
IOError: Could not read from file: /tmp/codyw1003010030-8.html with error: [Errno 2] No such file or directory: u'/tmp/codyw1003010030-8.html'
Is there something I need to clear out of the filesystem? This command worked for several hundred files before something somewhere gave out...
Lest it sound like I'm ungrateful, I'd like to say that this looks like just the epub creation tool I've been waiting for!