Using calibre to convert txt to mobi file
My first blog is not for SAP tech, but for my kindle paperwhite~ 😆
I used calibre to convert the novel txt files to mobi file which has content and nice format, but convert failed recently.
The error log as below:
Python function terminated unexpectedly
This txt file has malformed markup, it cannot be converted by calibre. See http://daringfireball.net/projects/markdown/syntax (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 193, 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 1041, in run
File “site-packages\calibre\customize\conversion.py”, line 241, in __call__
File “site-packages\calibre\ebooks\conversion\plugins\txt_input.py”, line 199, in convert
ValueError: This txt file has malformed markup, it cannot be converted by calibre. See http://daringfireball.net/projects/markdown/syntax
I found that if I remove the symbol ‘##’ which used to generate the content, it converted success.
At last I try to split the novel file(14.8M) to four smaller files(about 3~5M) without remove the symbol ‘##’, and they had beed converted success!!
I don’t know why calibre cannot convert the larger file, but the error messages is difficult to comprehend!!
So that the error messages is very important when we develop the sap program. ℹ