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

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 01-24-2010, 12:32 AM   #1
gondwild
Member
gondwild began at the beginning.
 
Posts: 10
Karma: 10
Join Date: Jan 2010
Device: Sony PRS-300
RTF -> EPUB conversion error

What is the feature of the .rtf file that calibre does not support? And what's the best way to proceed from here? (I don't particularly like the .rtf formatting, and would prefer to read the book in .epub, although the .rtf DOES in fact work on my Sony PRS 300)

ERROR: Conversion Error: <b>Failed</b>: Convert book 1 of 1 (Book title here)

Convert book 1 of 1 (Book title here)
Resolved conversion options
{'asciiize': False,
'author_sort': None,
'authors': None,
'base_font_size': 0.0,
'book_producer': None,
'chapter': u"//*[((name()='h1' or name()='h2') and re:test(., 'chapter|book|section|part\\s+', 'i')) or @class = 'chapter']",
'chapter_mark': u'pagebreak',
'comments': None,
'cover': None,
'debug_pipeline': None,
'disable_font_rescaling': False,
'dont_justify': True,
'dont_split_on_page_breaks': False,
'extra_css': None,
'extract_to': None,
'flow_size': 260,
'font_size_mapping': None,
'footer_regex': u'(?i)(?<=<hr>)((\\s*<a name=\\d+></a>((<img.+?>)*<br>\\s*)?\\d+<br>\\s*.*?\\s*)|(\\s* <a name=\\d+></a>((<img.+?>)*<br>\\s*)?.*?<br>\\s*\\d+))(?=<br>)' ,
'header_regex': u'(?i)(?<=<hr>)((\\s*<a name=\\d+></a>((<img.+?>)*<br>\\s*)?\\d+<br>\\s*.*?\\s*)|(\\s* <a name=\\d+></a>((<img.+?>)*<br>\\s*)?.*?<br>\\s*\\d+))(?=<br>)' ,
'input_encoding': None,
'input_profile': <calibre.customize.profiles.InputProfile object at 0x626b7d0>,
'insert_blank_line': False,
'insert_metadata': False,
'isbn': None,
'language': None,
'level1_toc': None,
'level2_toc': None,
'level3_toc': None,
'line_height': 0.0,
'linearize_tables': False,
'margin_bottom': 5.0,
'margin_left': 5.0,
'margin_right': 5.0,
'margin_top': 5.0,
'max_toc_links': 50,
'no_chapters_in_toc': False,
'no_default_epub_cover': False,
'no_inline_navbars': False,
'output_profile': <calibre.customize.profiles.SonyReader300Output object at 0x626b9d0>,
'page_breaks_before': u"//*[name()='h1' or name()='h2']",
'prefer_metadata_cover': False,
'preprocess_html': False,
'pretty_print': True,
'publisher': None,
'rating': None,
'read_metadata_from_opf': '/var/folders/tw/twyPmqswE7OUrwR3lSwWFE+++TI/-Tmp-/calibre_0.6.35_k7eqcH.opf',
'remove_first_image': False,
'remove_footer': False,
'remove_header': False,
'remove_paragraph_spacing': True,
'remove_paragraph_spacing_indent_size': 1.5,
'series': None,
'series_index': None,
'tags': None,
'title': None,
'title_sort': None,
'toc_filter': None,
'toc_threshold': 6,
'use_auto_toc': False,
'verbose': 2}
Python function terminated unexpectedly: This RTF file has a feature calibre does not support. Convert it to HTML first and then try it.
InputFormatPlugin: RTF Input running
on /Users/*****/Documents/Books/eBooks/Author/Book Title Here/File Name Here.rtf
Converting RTF to XML...
Preprocessing to convert unicode characters
Traceback (most recent call last):
File "/Applications/calibre.app/Contents/Resources/Python/lib/python2.6/site.py", line 147, in main
return run_entry_point()
File "/Applications/calibre.app/Contents/Resources/Python/lib/python2.6/site.py", line 116, in run_entry_point
return getattr(pmod, func)()
File "site-packages/calibre/utils/ipc/worker.py", line 99, in main
File "site-packages/calibre/gui2/convert/gui_conversion.py", line 24, in gui_convert
File "site-packages/calibre/ebooks/conversion/plumber.py", line 745, in run
File "site-packages/calibre/customize/conversion.py", line 211, in __call__
File "site-packages/calibre/ebooks/rtf/input.py", line 199, in convert
ValueError: This RTF file has a feature calibre does not support. Convert it to HTML first and then try it.
gondwild is offline   Reply With Quote
Old 01-24-2010, 12:50 AM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 25,386
Karma: 4961459
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Save your rtf as html and convert that
kovidgoyal is online now   Reply With Quote
Old 01-24-2010, 02:45 AM   #3
peterloron
Member
peterloron began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Dec 2009
Location: WA
Device: iPhone Stanza
If you are running on a Mac, you can use this Applescript snippet to quickly convert from RTF to HTML:

Code:
on open filelist
	repeat with i in filelist
		do shell script "textutil -convert html -extension html '" & POSIX path of i & "'"
	end repeat
end open
peterloron is offline   Reply With Quote
Old 01-16-2011, 11:35 AM   #4
Archon
Zealot
Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!Archon , Klaatu Barada Niktu!
 
Archon's Avatar
 
Posts: 110
Karma: 5176
Join Date: Dec 2010
Device: Mac OSX, iPad, iPod, & Nook
Nice little script

I have recently discovered textutil and it is a powerful little program.

I added your snippet to Applescript and saved it as an application.

Now, I have a powerful little drop converter.

Thanks for the tip

Archon
Archon 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
Error when converting RTF to EPUB doreenjoy Calibre 3 05-19-2012 03:32 AM
polish characters, rtf -> epub conversion antismap Calibre 5 12-10-2010 09:10 AM
Repeating Images after EPUB to RTF conversion kerrware Calibre 1 07-15-2010 09:05 AM
rtf -- > epub / fb2 conversion Brandobras Calibre 2 04-14-2010 01:24 AM
Error with RTF Conversion daesdaemar Calibre 4 01-29-2009 05:42 PM


All times are GMT -4. The time now is 03:23 AM.


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