[docutils:bugs] #497 manpage writer renders links incorrectly

Günter Milde via Docutils-develop <[email protected]> Wed, 30 Jul 2025 08:56:06 -0000
Newsgroups gmane.text.docutils.devel
Message-ID </p/docutils/bugs/497/391b60b77dc3e322c347e754a764cd4e6c4f029b.bugs@docutils.p.sourceforge.net>
- **status**: open-fixed --> closed-fixed
- **Comment**:

The bug is fixed in Docutils 0.22 released 2025-07-29.
Thank you for reporting.




---

**[bugs:#497] manpage writer renders links incorrectly**

**Status:** closed-fixed
**Labels:** manpage writer 
**Created:** Tue Feb 11, 2025 11:03 PM UTC by Ulya Trofimovich
**Last Updated:** Wed Apr 30, 2025 07:08 PM UTC
**Owner:** engelbert gruber


Hi! Here's an example bug.rst file (trimmed from a real-world manpage AUTHORS section and changed to hide real names):
~~~
$ cat bug.rst
Aaaaa ([email protected]),
`Bbb <https://github.com/cc>`_ ([email protected]),
`mm <https://github.com/m>`_
`nn <https://github.com/nn>`_
and `OooOoooo <https://github.com/OooOoooo>`_.
~~~
With rst2man (Docutils 0.21.2, Python 3.12.8, on linux) it is rendered as follows (I cut first and last output lines in the output as they obscure the view and are irrelevant):
~~~
$ rst2man bug.rst > bug.1 && man ./bug.1
NAME
        - Aaaaa ( <[email protected]> ), Bbb <https://github.com/cc>
        ( <[email protected]> ), mm <https://github.com/m>

        <nn> and  <OooOoooo> .
~~~
What I think is wrong:

1. In <nn> and <OooOoooo> URI had been removed completely (note that they are different from other addresses in that the substitution text is the same as the last URI path component)
2. spaces surrounding email in parentheses look weird
3. newlines seem to be inserted at random

I would like it to be rendered like this:
~~~
NAME
        - Aaaaa ([email protected]), Bbb <https://github.com/cc> ([email protected]), mm <https://github.com/m> nn <https://github.com/nn> and OooOoooo <https://github.com/OooOoooo>.
~~~
    
I suspect this is the change in https://docutils.sourceforge.io/RELEASE-NOTES.html#release-0-21-2024-04-09, as I saw other changes listed in this release in the same diff with the breaking changes described above.


---

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.