Re: LaTeX writer crash
Guenter Milde <[email protected]>
| Newsgroups | gmane.text.docutils.user |
|---|---|
| Message-ID | <[email protected]> |
Dear Mikołaj,
thank you for the bug report.
On 2015-07-21, Mikołaj Machowski wrote:
> Below traceback, OS info and docutils version. HTML export works
> without problems.
I get 160 errors of type
/tmp/01.txt:28: (ERROR/3) Unknown target name: "02.08.06".
here.
> Note that I have long list of empty (so far)
> hyperlinks - maybe that is the cause?
No. A minimal example for the problematic input is::
Epiroci zaprosili na tron Alketasa [180]_, ...
.. [180] R. 312
which produces the pseudo-XML::
<document source="/tmp/test02.rst">
<paragraph>
Epiroci zaprosili na tron Alketasa
<footnote_reference ids="id1" refid="id2">
180
, …
<footnote backrefs="id1" ids="id2" names="180">
<label>
180
<enumerated_list enumtype="upperalpha" prefix="" start="18" suffix=".">
<list_item>
<paragraph>
312
i.e. The text R. 312 is parsed as the first item of an enumerated list,
which is surely not what you intended and looks strange in HTML, too.
see http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#enumerated-lists
You can avoid this by escaping::
Epiroci zaprosili na tron Alketasa [180]_, ...
.. [180] \R. 312
However, for footnotes that start with anything that is not a paragraph,
the problem remains:
...
> File "/usr/lib/python2.7/site-packages/docutils/writers/latex2e/__init__.py", line 2176, in visit_footnote
> num,text = node.astext().split(None,1)
> ValueError: need more than 1 value to unpack
I changed the code to be more stable for these cases, found a follow-up bug
and fixed as well and will upload the fix to the repository soon.
Thanks,
Günter
------------------------------------------------------------------------------
_______________________________________________
Docutils-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/docutils-users
Please use "Reply All" to reply to the list.