Long titles with possible invalid chars cause errors during convert

Bug #1235815 reported by Scott Bakker on 2013-10-05
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
calibre
Undecided
Unassigned

Bug Description

Calibre version 1.5, Windows 8 64-bit

When trying to convert the ebook with the Calibre Title below, it failed:

John Carter: Barsoom Series (7 Novels) A Princess of Mars; Gods of Mars; Warlord of Mars; Thuvia, Maid of Mars; Chessmen of Mars; Master Mind of Mars; Fighting Man of Mars COMPLETE WITH ILLUSTRATIONS

After changing only the Calibre Title to the following, it succeeded:

John Carter- Barsoom Series (7 Novels)

calibre, version 1.5.0 (win32, isfrozen: True)
Conversion Error: Failed: Convert book 1 of 1 (John Carter: Barsoom Series (7 Novels) A Princess of Mars; Gods of Mars; Warlord of Mars; Thuvia, Maid of Mars; Chessmen of Mars; Master Mind of Mars; Fighting Man of Mars COMPLETE WITH ILLUSTRATIONS)

Convert book 1 of 1 (John Carter: Barsoom Series (7 Novels) A Princess of Mars; Gods of Mars; Warlord of Mars; Thuvia, Maid of Mars; Chessmen of Mars; Master Mind of Mars; Fighting Man of Mars COMPLETE WITH ILLUSTRATIONS)
Resolved conversion options
calibre version: 1.5.0
{'asciiize': False,
 'author_sort': None,
 'authors': None,
 'base_font_size': 0.0,
 'book_producer': None,
 'change_justification': u'justify',
 'chapter': u"//*[name()='h3' or name()='h4']",
 'chapter_mark': u'pagebreak',
 'comments': None,
 'cover': u'C:\\Users\\Scott\\AppData\\Local\\Temp\\calibre_mkfpy_\\ywmdmu.jpeg',
 'debug_pipeline': None,
 'dehyphenate': True,
 'delete_blank_paragraphs': True,
 'disable_font_rescaling': False,
 'duplicate_links_in_toc': False,
 'embed_all_fonts': False,
 'embed_font_family': None,
 'enable_heuristics': False,
 'extra_css': None,
 'filter_css': u'',
 'fix_indents': True,
 'font_size_mapping': None,
 'format_scene_breaks': True,
 'html_unwrap_factor': 0.4,
 'htmlz_class_style': u'inline',
 'htmlz_css_type': u'tag',
 'htmlz_title_filename': True,
 'input_encoding': None,
 'input_profile': <calibre.customize.profiles.InputProfile object at 0x0411BE10>,
 'insert_blank_line': False,
 'insert_blank_line_size': 0.5,
 'insert_metadata': False,
 'isbn': None,
 'italicize_common_cases': True,
 'keep_ligatures': False,
 'language': None,
 'level1_toc': u"//*[name()='h3' or name()='h6']",
 'level2_toc': u"//*[name()='h4']",
 'level3_toc': None,
 'line_height': 0.0,
 'linearize_tables': False,
 'margin_bottom': -1.0,
 'margin_left': -1.0,
 'margin_right': -1.0,
 'margin_top': -1.0,
 'markup_chapter_headings': True,
 'max_toc_links': 0,
 'minimum_line_height': 120.0,
 'no_chapters_in_toc': False,
 'no_inline_navbars': False,
 'output_profile': <calibre.customize.profiles.KindleOutput object at 0x04129170>,
 'page_breaks_before': u"//*[name()='h3' or name()='h4' or name()='h5' or name()='h6']",
 'prefer_metadata_cover': False,
 'pretty_print': False,
 'pubdate': None,
 'publisher': None,
 'rating': None,
 'read_metadata_from_opf': u'C:\\Users\\Scott\\AppData\\Local\\Temp\\calibre_mkfpy_\\slj0sx.opf',
 'remove_fake_margins': True,
 'remove_first_image': False,
 'remove_paragraph_spacing': False,
 'remove_paragraph_spacing_indent_size': 1.5,
 'renumber_headings': True,
 'replace_scene_breaks': u'',
 'search_replace': '[]',
 'series': None,
 'series_index': None,
 'smarten_punctuation': False,
 'sr1_replace': None,
 'sr1_search': None,
 'sr2_replace': None,
 'sr2_search': None,
 'sr3_replace': None,
 'sr3_search': None,
 'start_reading_at': None,
 'subset_embedded_fonts': False,
 'tags': None,
 'timestamp': None,
 'title': None,
 'title_sort': None,
 'toc_filter': None,
 'toc_threshold': 0,
 'unsmarten_punctuation': False,
 'unwrap_lines': True,
 'use_auto_toc': False,
 'verbose': 2}
InputFormatPlugin: MOBI Input running
on C:\Users\Scott\AppData\Local\Temp\calibre_mkfpy_\z0r4ka.mobi
Extracting text...
Adding anchors...
Extracting images...
Cleaning up HTML...
Parsing HTML...
Converting style information to CSS...
Creating OPF...
Parsing all content...
Parsing styles.css ...
Parsing CR!4ZDG4DZM3X2JFENA2P0YRQKSH14C.html ...
Forcing CR!4ZDG4DZM3X2JFENA2P0YRQKSH14C.html into XHTML namespace
Reading TOC from NCX...
Merging user specified metadata...
Detecting structure...
Flattening CSS and remapping font sizes...
Source base font size is 12.00000pt
Removing fake margins...
Found 150 items of level: div_1
Found 10228 items of level: p_1
div_1 left margin stats: Counter()
div_1 right margin stats: Counter()
Negative text indent detected at level p_1, ignoring this level
Cleaning up manifest...
Trimming unused files from manifest...
Trimming u'images/00025.jpg' from manifest
Trimming u'images/00024.jpg' from manifest
Creating HTMLZ Output...
Converting OEB book to HTML...
Converting CR%214ZDG4DZM3X2JFENA2P0YRQKSH14C.html to HTML...
Python function terminated unexpectedly
  [Errno 2] No such file or directory: u'C:\\Users\\Scott\\AppData\\Local\\Temp\\calibre_mkfpy_\\tienrt_htmlz_output\\John Carter_ Barsoom Series (7 Novels) A Princess of Mars; Gods of Mars; Warlord of Mars; Thuvia, Maid of Mars; Chessmen of Mars; Master Mind of Mars; Fighting Man of Mars COMPLETE WITH ILLUSTRATIONS.html' (Error Code: 1)
Traceback (most recent call last):
  File "site.py", line 132, in main
  File "site.py", line 109, in run_entry_point
  File "site-packages\calibre\utils\ipc\worker.py", line 189, in main
  File "site-packages\calibre\gui2\convert\gui_conversion.py", line 31, in gui_convert_override
  File "site-packages\calibre\gui2\convert\gui_conversion.py", line 25, in gui_convert
  File "site-packages\calibre\ebooks\conversion\plumber.py", line 1181, in run
  File "site-packages\calibre\ebooks\conversion\plugins\htmlz_output.py", line 71, in convert
IOError: [Errno 2] No such file or directory: u'C:\\Users\\Scott\\AppData\\Local\\Temp\\calibre_mkfpy_\\tienrt_htmlz_output\\John Carter_ Barsoom Series (7 Novels) A Princess of Mars; Gods of Mars; Warlord of Mars; Thuvia, Maid of Mars; Chessmen of Mars; Master Mind of Mars; Fighting Man of Mars COMPLETE WITH ILLUSTRATIONS.html'

Fixed in branch master. The fix will be in the next release. calibre is usually released every Friday.

 status fixreleased

Changed in calibre:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers