Menu

#109 Drop outdated copy of roman.py in docutils/utils

Default
closed-fixed
nobody
None
5
2024-11-10
2024-10-04
No

Back in the days without pypi and pip, Docutils developers decided to ship a copy of the small auxiliary module roman.py (pypi.org) with Docutils in order to allow the package to stay free of any dependencies except Python (also a pre-requisite for the proposed inclusion of Docutils into the standard library).

In the year 2024, however, depending on an external module that

  • is available on pip,
  • has no other dependencies, and
  • is maintained

should not pose an obstacle to Docutils users.

Commits [r9845] and [r9846] added and adopted an alternative implementation of Roman numeral support but did not remove the copy of the upstream roman.py.

I propose to remove both, utils/roman.py and utils/_roman_numeral.py and declare a dependency on roman instead.
(Lowercase roman to int support was added in the upstream repo commit ffc86c4 Oct 1, 2024, so we would need to work around this until a roman.py release with this fix is available.

Related

Commit: [r9845]
Commit: [r9846]

Discussion

  • Dmitry Shachnev

    Dmitry Shachnev - 2024-10-04

    +1 from me as a Debian packager. We currently carry a patch to use system version of roman, so I will be able to drop that patch.

     
  • Adam  Turner

    Adam Turner - 2024-10-04

    Dear Günter,

    I would suggest deleting utils/roman.py instead (it was an oversight in my patch).

    Docutils (via Sphinx) is tested on every commit to CPython, so having a third party package that we don't maintain in the 'critical path' dependency chain is unhelpful, as it means that we would either have to patch roman ourselves (as you propose to do now) or wait for someone else to release a fix.

    utils/_roman_numeral.py is a small module containing well-tested code, and designed with Docutils's needs in mind. It is also more permissively licensed.

    A

     
  • Günter Milde

    Günter Milde - 2024-10-15

    OK then.
    @mandriver: Would an alternative module be OK for Debian? The roman-patch would be obsoleted either way.

     
    • Dmitry Shachnev

      Dmitry Shachnev - 2024-10-15

      Yes, it's also fine for us.

       
  • Günter Milde

    Günter Milde - 2024-11-10
    • status: open --> closed-fixed
     
  • Günter Milde

    Günter Milde - 2024-11-10

    Done in [r9977].

     

    Related

    Commit: [r9977]


Log in to post a comment.

MongoDB Logo MongoDB