|
From: Günter M. <mi...@us...> - 2025-04-29 12:52:28
|
- **status**: open --> pending
- **Priority**: 5 --> 3
---
**[feature-requests:#56] :key:value not caught as badly formed option, but rather taken as an argument**
**Status:** pending
**Group:** Default
**Created:** Fri Oct 13, 2017 09:44 AM UTC by Robin Shannon
**Last Updated:** Tue Oct 17, 2017 01:53 PM UTC
**Owner:** nobody
If your mistype your reST directive like this:
.. directive:: argument
:key:value (note the lack of a space between ":" and "v")
docutils interprests this as a directive with two arguments (argument, :key:value) instead on one argument and an option key value pair. It seems like it would be nice if there was a check for the final argument given (if more than one argument is given) along the lines of:
_emptystr, key, _emptystr, value = re.split(r"^\:(.*?)\:(.*?)", arg)
if key in self.option_spec and key not in self.options:
RAISE WARNING
---
Sent from sourceforge.net because doc...@li... is subscribed to https://sourceforge.net/p/docutils/feature-requests/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/docutils/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list. |