GH-121970: Remove Docutils list monkeypatch (#142056)

This commit is contained in:
Adam Turner 2025-11-29 14:28:23 +00:00 committed by GitHub
parent cfcd52490d
commit 3c117380ab
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 26 additions and 34 deletions

View file

@ -24,14 +24,6 @@
# Used in conf.py and updated here by python/release-tools/run_release.py
SOURCE_URI = 'https://github.com/python/cpython/tree/main/%s'
# monkey-patch reST parser to disable alphabetic and roman enumerated lists
from docutils.parsers.rst.states import Body
Body.enum.converters['loweralpha'] = \
Body.enum.converters['upperalpha'] = \
Body.enum.converters['lowerroman'] = \
Body.enum.converters['upperroman'] = lambda x: None
class PyAwaitableMixin(object):
def handle_signature(self, sig, signode):
ret = super(PyAwaitableMixin, self).handle_signature(sig, signode)