[docutils:bugs] #499 latex2e: field list absent from body when on start of input string
Günter Milde via Docutils-develop <[email protected]> Mon, 14 Apr 2025 09:17:40 -0000
| Newsgroups | gmane.text.docutils.devel |
|---|---|
| Message-ID | </p/docutils/bugs/499/da833c79346d77957bf23e361453d6cb0608db74.bugs@docutils.p.sourceforge.net> |
- **labels**: latex2e writer, field list --> latex2e writer
- **status**: open --> closed-invalid
- **Comment**:
Thank you for reporting.
The reason for the behaviour is, that [a field list at the start of a document is transformed into a docinfo list](https://docutils.sourceforge.io/docs/ref/rst/restructuredtext.html#bibliographic-fields). (It is returned as "docinfo" part also by the HTML writers.)
You can configure this behaviour with the [docinfo-xform](https://docutils.sourceforge.io/docs/user/config.html#docinfo-xform) setting. In the minimal example, add a line
"docinfo_xform": False,
to the `overrides` dictionary in `latex_parts()`.
---
**[bugs:#499] latex2e: field list absent from body when on start of input string**
**Status:** closed-invalid
**Labels:** latex2e writer
**Created:** Sun Apr 06, 2025 06:43 PM UTC by PJBrs
**Last Updated:** Sun Apr 06, 2025 06:43 PM UTC
**Owner:** nobody
**Attachments:**
- [latex_lists_test.py](https://sourceforge.net/p/docutils/bugs/499/attachment/latex_lists_test.py) (2.3 kB; text/x-python)
When I try to translate an RST string that begins with a field list to latex, the string is absent from the "body" part of what the writer returns. Instead, it becomes part of "docinfo".
If I add some information before the field list, it is correctly added to the "body" part of what core.publish_parts returns.
I don't know docutils very well, so I've attached an MWE.
~~~
$ docutils -V
docutils (Docutils 0.21.2, Python 3.9.21, on linux)
~~~
---
Sent from sourceforge.net because [email protected] is subscribed to https://sourceforge.net/p/docutils/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/docutils/admin/bugs/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.