python-greenlet / greenlet

Lightweight in-process concurrent programming
Other
1.63k stars 247 forks source link

RFE: please restore sphinx support #394

Closed kloczek closed 8 months ago

kloczek commented 8 months ago

Looks like 3.0.3 has removed sphinx support. It would be really good to restore sphinx support. Reason for that is mkdoc do not support rendering roff output (AKA man page). In our distribution we are using sphinx to generate module man page as standard documentation format.

[tkloczko@pers-jacek SPECS]$ ls -1 python-*.spec | wc -l; grep %sphinx_build_man python-*.spec | wc -l
1224
676

Above means that on scale 1224 packages with python modules in more than half (676) cases it is possible to generate dokumentom as man page. Each module man page is available under python-<module_name> name which allows easy access to any module documentation. Example from my current devel system

[tkloczko@pers-jacek SPECS]$ man python-<tab><tab>
python-anyiodoc                python-numpy                   python-sniffio
python-babel                   python-objgraph                python-sortedcontainers
python-build                   python-pluggy                  python-sphinx
python-charset-normalizer      python-psutil                  python-sphinx-code-tabs
python-cython                  python-pyenchant               python-sphinx-tabs
python-dateutil                python-pygments                python-sphinx-theme-alabaster
python-execnet                 python-pyproject-hooks         python-sphinx_rtd_theme
python-gidocgen                python-pytest                  python-sphinxcontribspelling
python-importlib-metadata      python-pytest-asyncio          python-urllib3
python-installer               python-pytest-xdist            python-wheel
python-jinja2                  python-requests                python-zipp
python-lz4                     python-setuptools              python-zstandard
python-mako                    python-six
python-markupsafe              python-smartypants

To provide back sphinx support all what is necessary to do is restore docs/conf.py and trim it a bit because sphinx can process .rst files as well. Doable? 🤔

kloczek commented 8 months ago

BTW .. mkdic currently is used only with handful number of modules and sphinx is de facto python modules documentation standard.

[tkloczko@pers-jacek SPECS]$ grep "# NOTE:.*mkdoc" python-*
python-httpx.spec:# NOTE: uses mkdoc
python-pdm.spec:# NOTE: uses mkdoc
python-starlette.spec:# NOTE: package uses mkdoc
python-typer.spec:# NOTE: docs/ used mkdocs
kloczek commented 8 months ago

Just searched across some my notes and found https://github.com/jfhbrook/pyee/pull/141

jamadden commented 8 months ago

I have no idea what you mean. Sphinx support is definitely not missing or broken. Sphinx is how we build documentation on RTD. docs/conf.py exists in the repository and the sdist.

kloczek commented 8 months ago

Sorry my mistake. I've been working on two modules and placed this ticked in your repo .. wrong repo😋