[docutils:patches] #214 Give better messages on malformed tables

Günter Milde via Docutils-develop <[email protected]> Sun, 20 Jul 2025 21:57:43 -0000
Newsgroups gmane.text.docutils.devel
Message-ID </p/docutils/patches/214/efac76be511f6943607a799de3c306ff3ca1c62f.patches@docutils.p.sourceforge.net>
Thank you for the patch. I will have a look at this once 0.22 is out. (We don't want delay the release any further by new changes to the release candidate unless it is  urgent.)


---

**[patches:#214] Give better messages on malformed tables**

**Status:** open
**Group:** None
**Created:** Sun Jun 08, 2025 05:58 PM UTC by Jynn Nelson
**Last Updated:** Sun Jun 08, 2025 05:58 PM UTC
**Owner:** nobody
**Attachments:**

- [tables.diff](https://sourceforge.net/p/docutils/patches/214/attachment/tables.diff) (5.2 kB; application/octet-stream)


This does several things:
- Specifies `Misaligned right border` for that error, instead of just "malformed table".
- Shows the line where each error happened, not the line where the table starts.
  - This had a complication that line numbers appear to be wrong when `include` directives are present (they include the lines in the source document, instead of being relative to the included document). Just disabled the new smarter logic in that case.
- Changes `malformed_table` to require both detail and an offset, so poor errors like this can't happen in the future.

Fixes https://sourceforge.net/p/docutils/bugs/504/.


---

Sent from sourceforge.net because [email protected] is subscribed to https://sourceforge.net/p/docutils/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/docutils/admin/patches/options.  Or, if this is a mailing list, you can unsubscribe from the mailing list.