From fc11996bc6b529bfd3a3d12b691a6322ed87b1cb Mon Sep 17 00:00:00 2001 From: nandgator <38415384+nandgator@users.noreply.github.com> Date: Sat, 10 Oct 2026 13:39:09 +0530 Subject: [PATCH 1/2] chore: loosen docs tooling bounds, rename mkdocstrings 'import' to 'inventories' Drop the upper bounds on the documentation groups, let ruff format Markdown again, and upgrade the lock to the latest stable releases. mkdocstrings-python >=1.14 supports the 'inventories' key that replaces the removed 'import'. --- mkdocs.yaml | 2 +- pyproject.toml | 28 +++----- uv.lock | 179 +++++++++++++++++++++++++++++-------------------- 3 files changed, 117 insertions(+), 92 deletions(-) diff --git a/mkdocs.yaml b/mkdocs.yaml index 868fad4d..6e63469d 100644 --- a/mkdocs.yaml +++ b/mkdocs.yaml @@ -48,7 +48,7 @@ plugins: python: options: show_root_heading: true - import: + inventories: - https://docs.python-requests.org/en/master/objects.inv - git-revision-date-localized - mike diff --git a/pyproject.toml b/pyproject.toml index a449c001..a9a04cae 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,23 +54,18 @@ crypto-eth-addresses = ["eth-hash[pycryptodome]>=0.7.0"] ############################## [dependency-groups] -# The documentation and man page generation tooling is deliberately held to the versions -# that produce the published output (the man page ships in distro packages). Newer -# releases change the rendered output (e.g. man page markup, bundled pandoc) or break the -# mkdocs configuration. Raise these bounds only together with a review of the regenerated -# `docs/` and man page. docs-offline = [ - "myst-parser>=3.0.1,<4", - "pypandoc-binary>=1.13,<1.14", - "sphinx>=7.1.2,<7.2", - "furo>=2024.8.6,<2025", + "myst-parser>=3.0.1", + "pypandoc-binary>=1.13", + "sphinx>=7.1.2", + "furo>=2024.8.6", ] docs-online = [ - "mkdocs>=1.6.1,<2", + "mkdocs>=1.6.1", "mkdocs-git-revision-date-localized-plugin>=1.2.7", - "mkdocs-material>=9.5.34,<10", - "mkdocstrings[python]>=0.26.0,<1", - "mkdocstrings-python>=1.10.5,<2", + "mkdocs-material>=9.5.34", + "mkdocstrings[python]>=0.26.0", + "mkdocstrings-python>=1.14.0", # `inventories` option replaces `import` "mike>=2.1.3", ] package = ["build>=1.2.1"] @@ -81,7 +76,7 @@ tooling = [ "ruff>=0.6.3", "pyright>=1.1.378", "pytest>=9.0.3", - "pypandoc-binary>=1.13,<1.14", # helps with type checking + "pypandoc-binary>=1.13", # helps with type checking ] #################### @@ -151,11 +146,6 @@ line-length = 100 target-version = "py311" extend-exclude = ["**/__pycache__", ".pytest_cache", "site"] -[tool.ruff.format] -# Markdown files under docs/ are sources for the generated documentation and man page; -# keep ruff (which can format Python code blocks in Markdown) away from them. -exclude = ["*.md"] - [tool.ruff.lint.isort] # case-sensitive = true combine-as-imports = true diff --git a/uv.lock b/uv.lock index 093b1702..16230d9b 100644 --- a/uv.lock +++ b/uv.lock @@ -6,13 +6,25 @@ resolution-markers = [ "python_full_version < '3.12'", ] +[[package]] +name = "accessible-pygments" +version = "0.0.5" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "pygments" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/bc/c1/bbac6a50d02774f91572938964c582fff4270eee73ab822a4aeea4d8b11b/accessible_pygments-0.0.5.tar.gz", hash = "sha256:40918d3e6a2b619ad424cb91e556bd3bd8865443d9f22f1dcdf79e33c8046872", size = 1377899, upload-time = "2024-05-10T11:23:10.216Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/8d/3f/95338030883d8c8b91223b4e21744b04d11b161a3ef117295d8241f50ab4/accessible_pygments-0.0.5-py3-none-any.whl", hash = "sha256:88ae3211e68a1d0b011504b2ffc1691feafce124b845bd072ab6f9f66f34d4b7", size = 1395903, upload-time = "2024-05-10T11:23:08.421Z" }, +] + [[package]] name = "alabaster" -version = "0.7.16" +version = "1.0.0" source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/c9/3e/13dd8e5ed9094e734ac430b5d0eb4f2bb001708a8b7856cbf8e084e001ba/alabaster-0.7.16.tar.gz", hash = "sha256:75a8b99c28a5dad50dd7f8ccdd447a121ddb3892da9e53d1ca5cca3106d58d65", size = 23776, upload-time = "2024-01-10T00:56:10.189Z" } +sdist = { url = "https://files.pythonhosted.org/packages/a6/f8/d9c74d0daf3f742840fd818d69cfae176fa332022fd44e3469487d5a9420/alabaster-1.0.0.tar.gz", hash = "sha256:c00dca57bca26fa62a6d7d0a9fcce65f3e026e9bfe33e9c538fd3fbb2144fd9e", size = 24210, upload-time = "2024-07-26T18:15:03.762Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/32/34/d4e1c02d3bee589efb5dfa17f88ea08bdb3e3eac12bc475462aec52ed223/alabaster-0.7.16-py3-none-any.whl", hash = "sha256:b46733c07dce03ae4e150330b975c75737fa60f0a7c591b6c8bf4928a28e2c92", size = 13511, upload-time = "2024-01-10T00:56:08.388Z" }, + { url = "https://files.pythonhosted.org/packages/7e/b3/6b4067be973ae96ba0d615946e314c5ae35f9f993eca561b356540bb0c2b/alabaster-1.0.0-py3-none-any.whl", hash = "sha256:fc6786402dc3fcb2de3cabd5fe455a2db534b371124f1f21de8731783dec828b", size = 13929, upload-time = "2024-07-26T18:15:02.05Z" }, ] [[package]] @@ -273,11 +285,11 @@ wheels = [ [[package]] name = "docutils" -version = "0.20.1" +version = "0.22.4" source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/1f/53/a5da4f2c5739cf66290fac1431ee52aff6851c7c8ffd8264f13affd7bcdd/docutils-0.20.1.tar.gz", hash = "sha256:f08a4e276c3a1583a86dce3e34aba3fe04d02bba2dd51ed16106244e8a923e3b", size = 2058365, upload-time = "2023-05-16T23:39:19.748Z" } +sdist = { url = "https://files.pythonhosted.org/packages/ae/b6/03bb70946330e88ffec97aefd3ea75ba575cb2e762061e0e62a213befee8/docutils-0.22.4.tar.gz", hash = "sha256:4db53b1fde9abecbb74d91230d32ab626d94f6badfc575d6db9194a49df29968", size = 2291750, upload-time = "2025-12-18T19:00:26.443Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/26/87/f238c0670b94533ac0353a4e2a1a771a0cc73277b88bff23d3ae35a256c1/docutils-0.20.1-py3-none-any.whl", hash = "sha256:96f387a2c5562db4476f09f13bbab2192e764cac08ebbf3a34a95d9b1e4a59d6", size = 572666, upload-time = "2023-05-16T23:39:15.976Z" }, + { url = "https://files.pythonhosted.org/packages/02/10/5da547df7a391dcde17f59520a231527b8571e6f46fc8efb02ccb370ab12/docutils-0.22.4-py3-none-any.whl", hash = "sha256:d0013f540772d1420576855455d050a2180186c91c15779301ac2ccb3eeb68de", size = 633196, upload-time = "2025-12-18T19:00:18.077Z" }, ] [[package]] @@ -305,17 +317,19 @@ wheels = [ [[package]] name = "furo" -version = "2024.8.6" +version = "2025.12.19" source = { registry = "https://pypi.org/simple" } dependencies = [ + { name = "accessible-pygments" }, { name = "beautifulsoup4" }, { name = "pygments" }, - { name = "sphinx" }, + { name = "sphinx", version = "9.0.4", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version < '3.12'" }, + { name = "sphinx", version = "9.1.0", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version >= '3.12'" }, { name = "sphinx-basic-ng" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/a0/e2/d351d69a9a9e4badb4a5be062c2d0e87bd9e6c23b5e57337fef14bef34c8/furo-2024.8.6.tar.gz", hash = "sha256:b63e4cee8abfc3136d3bc03a3d45a76a850bada4d6374d24c1716b0e01394a01", size = 1661506, upload-time = "2024-08-06T08:07:57.567Z" } +sdist = { url = "https://files.pythonhosted.org/packages/ec/20/5f5ad4da6a5a27c80f2ed2ee9aee3f9e36c66e56e21c00fde467b2f8f88f/furo-2025.12.19.tar.gz", hash = "sha256:188d1f942037d8b37cd3985b955839fea62baa1730087dc29d157677c857e2a7", size = 1661473, upload-time = "2025-12-19T17:34:40.889Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/27/48/e791a7ed487dbb9729ef32bb5d1af16693d8925f4366befef54119b2e576/furo-2024.8.6-py3-none-any.whl", hash = "sha256:6cd97c58b47813d3619e63e9081169880fbe331f0ca883c871ff1f3f11814f5c", size = 341333, upload-time = "2024-08-06T08:07:54.44Z" }, + { url = "https://files.pythonhosted.org/packages/f4/b2/50e9b292b5cac13e9e81272c7171301abc753a60460d21505b606e15cf21/furo-2025.12.19-py3-none-any.whl", hash = "sha256:bb0ead5309f9500130665a26bee87693c41ce4dbdff864dbfb6b0dae4673d24f", size = 339262, upload-time = "2025-12-19T17:34:38.905Z" }, ] [[package]] @@ -354,32 +368,6 @@ wheels = [ { url = "https://files.pythonhosted.org/packages/fa/48/f36d233ce749d1bb880cb5e6f8bb171dc2effabc7435c31da604d831b3ec/gitpython-3.2.0-py3-none-any.whl", hash = "sha256:bd70c5ec05cd2b797423e7eb312147d2458d3cca92085888fba2213f85905537", size = 228537, upload-time = "2026-09-30T09:10:31.159Z" }, ] -[[package]] -name = "griffe" -version = "2.3.2" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "griffecli" }, - { name = "griffelib" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/07/20/8446877884b2189cddf1304fd376d9bde2d1a6caf77e3980c5cdf5959245/griffe-2.3.2.tar.gz", hash = "sha256:8625bf98dbb02edb291aef77f2f1a17ae6c62d32a764f5bfed009e6010b2d538", size = 437566, upload-time = "2026-10-06T09:54:36.066Z" } -wheels = [ - { url = "https://files.pythonhosted.org/packages/10/09/385273046ef74d336e15cdd1069a9c0699483134b0616dceb4174d4d1213/griffe-2.3.2-py3-none-any.whl", hash = "sha256:31f5217d19c7e732893260d558f92298c4c9c9d2b50f930a1e6dec3f6feb63cb", size = 5081, upload-time = "2026-10-06T09:54:33.565Z" }, -] - -[[package]] -name = "griffecli" -version = "2.3.2" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "colorama" }, - { name = "griffelib" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/92/9a/32ae6bc0adc178e22e567e810e9c2e50956652574b9f07cd438a35de88d8/griffecli-2.3.2.tar.gz", hash = "sha256:d9daf7aaef8ac38fb29680a3397cc66300f3fc17c68c909a26446f06df0b44dd", size = 59944, upload-time = "2026-10-06T09:54:38.05Z" } -wheels = [ - { url = "https://files.pythonhosted.org/packages/69/c0/f9bcf1852e66b826674d174c7a17f8208bd9f9ea42c8e1debd4ba4c482d2/griffecli-2.3.2-py3-none-any.whl", hash = "sha256:54770415ad6f4b650d1c7af606d5db85c8e75591114b4b714c081a29ff00d986", size = 11637, upload-time = "2026-10-06T09:54:34.575Z" }, -] - [[package]] name = "griffelib" version = "2.3.2" @@ -439,14 +427,14 @@ wheels = [ [[package]] name = "markdown-it-py" -version = "3.0.0" +version = "4.2.0" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "mdurl" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/38/71/3b932df36c1a044d397a1f92d1cf91ee0a503d91e470cbd670aa66b07ed0/markdown-it-py-3.0.0.tar.gz", hash = "sha256:e3f60a94fa066dc52ec76661e37c851cb232d92f9886b15cb560aaada2df8feb", size = 74596, upload-time = "2023-06-03T06:41:14.443Z" } +sdist = { url = "https://files.pythonhosted.org/packages/06/ff/7841249c247aa650a76b9ee4bbaeae59370dc8bfd2f6c01f3630c35eb134/markdown_it_py-4.2.0.tar.gz", hash = "sha256:04a21681d6fbb623de53f6f364d352309d4094dd4194040a10fd51833e418d49", size = 82454, upload-time = "2026-05-07T12:08:28.36Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/42/d7/1ec15b46af6af88f19b8e5ffea08fa375d433c998b8a7639e76935c14f1f/markdown_it_py-3.0.0-py3-none-any.whl", hash = "sha256:355216845c60bd96232cd8d8c40e8f9765cc86f46880e43a8fd22dc1a1a8cab1", size = 87528, upload-time = "2023-06-03T06:41:11.019Z" }, + { url = "https://files.pythonhosted.org/packages/b3/81/4da04ced5a082363ecfa159c010d200ecbd959ae410c10c0264a38cac0f5/markdown_it_py-4.2.0-py3-none-any.whl", hash = "sha256:9f7ebbcd14fe59494226453aed97c1070d83f8d24b6fc3a3bcf9a38092641c4a", size = 91687, upload-time = "2026-05-07T12:08:27.182Z" }, ] [[package]] @@ -725,7 +713,7 @@ wheels = [ [[package]] name = "mkdocstrings" -version = "0.30.1" +version = "1.0.6" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "jinja2" }, @@ -735,9 +723,9 @@ dependencies = [ { name = "mkdocs-autorefs" }, { name = "pymdown-extensions" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/c5/33/2fa3243439f794e685d3e694590d28469a9b8ea733af4b48c250a3ffc9a0/mkdocstrings-0.30.1.tar.gz", hash = "sha256:84a007aae9b707fb0aebfc9da23db4b26fc9ab562eb56e335e9ec480cb19744f", size = 106350, upload-time = "2025-09-19T10:49:26.446Z" } +sdist = { url = "https://files.pythonhosted.org/packages/53/71/f85bdf13355073ae15a7375f09879375a830553552e58c1c4b7e0bbc5c8b/mkdocstrings-1.0.6.tar.gz", hash = "sha256:a0b8c2bdd29a6416c80d717aa369bbf7831946bd9f23c2a66db1b1dbe7693dbd", size = 100649, upload-time = "2026-07-11T19:38:05.732Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/7b/2c/f0dc4e1ee7f618f5bff7e05898d20bf8b6e7fa612038f768bfa295f136a4/mkdocstrings-0.30.1-py3-none-any.whl", hash = "sha256:41bd71f284ca4d44a668816193e4025c950b002252081e387433656ae9a70a82", size = 36704, upload-time = "2025-09-19T10:49:24.805Z" }, + { url = "https://files.pythonhosted.org/packages/5d/5b/4c1902e8bdd5c4db63284e9d101dece4038d4025d6d88850ffe0a1578980/mkdocstrings-1.0.6-py3-none-any.whl", hash = "sha256:2703708697487d1b6d6d7b412e176fa436edf120c1bf81dc9e126b12d00893c7", size = 35787, upload-time = "2026-07-11T19:38:04.417Z" }, ] [package.optional-dependencies] @@ -747,21 +735,21 @@ python = [ [[package]] name = "mkdocstrings-python" -version = "1.19.0" +version = "2.0.9" source = { registry = "https://pypi.org/simple" } dependencies = [ - { name = "griffe" }, + { name = "griffelib" }, { name = "mkdocs-autorefs" }, { name = "mkdocstrings" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/75/1c/3af8413919b0839b96a78f60e8bd0dfd26c844d3717eeb77f80b43f5be1c/mkdocstrings_python-1.19.0.tar.gz", hash = "sha256:917aac66cf121243c11db5b89f66b0ded6c53ec0de5318ff5e22424eb2f2e57c", size = 204010, upload-time = "2025-11-10T13:30:55.915Z" } +sdist = { url = "https://files.pythonhosted.org/packages/96/11/640067d1ad713ea99c233e53e57a4c300d9885f904a61371d7ef90dea549/mkdocstrings_python-2.0.9.tar.gz", hash = "sha256:ae945637dc0618c6beedbee169f10c0234b77f322c53db3fc9fb4c29b3013038", size = 203006, upload-time = "2026-09-22T13:43:27.712Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/98/5c/2597cef67b6947b15c47f8dba967a0baf19fbdfdc86f6e4a8ba7af8b581a/mkdocstrings_python-1.19.0-py3-none-any.whl", hash = "sha256:395c1032af8f005234170575cc0c5d4d20980846623b623b35594281be4a3059", size = 143417, upload-time = "2025-11-10T13:30:54.164Z" }, + { url = "https://files.pythonhosted.org/packages/62/0f/f7f926cfa06317bbdbd3cf0ff82f9e3a91767352eb01519c81499fddf575/mkdocstrings_python-2.0.9-py3-none-any.whl", hash = "sha256:c0233eff3f84d78110df50541918e7ec2bcff8e1614faddea34290a90321a416", size = 105698, upload-time = "2026-09-22T13:43:26.345Z" }, ] [[package]] name = "myst-parser" -version = "3.0.1" +version = "5.1.0" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "docutils" }, @@ -769,11 +757,12 @@ dependencies = [ { name = "markdown-it-py" }, { name = "mdit-py-plugins" }, { name = "pyyaml" }, - { name = "sphinx" }, + { name = "sphinx", version = "9.0.4", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version < '3.12'" }, + { name = "sphinx", version = "9.1.0", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version >= '3.12'" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/49/64/e2f13dac02f599980798c01156393b781aec983b52a6e4057ee58f07c43a/myst_parser-3.0.1.tar.gz", hash = "sha256:88f0cb406cb363b077d176b51c476f62d60604d68a8dcdf4832e080441301a87", size = 92392, upload-time = "2024-04-28T20:22:42.116Z" } +sdist = { url = "https://files.pythonhosted.org/packages/21/dc/603751677fff302f34396e206b610f556a59d7fe58b9a2145f54e96b48e8/myst_parser-5.1.0.tar.gz", hash = "sha256:ab69322dc6719dcc7f296479dbb70181b66df6ed315064f92dbc85c0e1bf2f02", size = 101182, upload-time = "2026-05-13T09:38:19.361Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/e2/de/21aa8394f16add8f7427f0a1326ccd2b3a2a8a3245c9252bc5ac034c6155/myst_parser-3.0.1-py3-none-any.whl", hash = "sha256:6457aaa33a5d474aca678b8ead9b3dc298e89c68e67012e73146ea6fd54babf1", size = 83163, upload-time = "2024-04-28T20:22:39.985Z" }, + { url = "https://files.pythonhosted.org/packages/09/dc/f3dfb7488b770f3f67e6545085bf2abea5172e88f57b8ad25ef860ca704c/myst_parser-5.1.0-py3-none-any.whl", hash = "sha256:9c91c52b3cdb4d94a6506e4fab4e2f296c7623a0da0dcbe6de1565c3dad67a8a", size = 85817, upload-time = "2026-05-13T09:38:17.904Z" }, ] [[package]] @@ -893,16 +882,16 @@ wheels = [ [[package]] name = "pypandoc-binary" -version = "1.13" +version = "1.17" source = { registry = "https://pypi.org/simple" } wheels = [ - { url = "https://files.pythonhosted.org/packages/97/f3/8e1ba6d7ecc97cb57ac61a3b8e935967e1f273421e37b6861c6742ad202d/pypandoc_binary-1.13-py3-none-macosx_10_9_x86_64.whl", hash = "sha256:946666388eb79b307d7f497b3b33045ef807750f8e5ef3440e0ba3bbab698044", size = 20136798, upload-time = "2024-02-16T08:59:08.257Z" }, - { url = "https://files.pythonhosted.org/packages/80/5e/70051958952850b9747032f9c854d1ae7870052c7d5697feb0a1d74d65c2/pypandoc_binary-1.13-py3-none-macosx_11_0_arm64.whl", hash = "sha256:21ef0345726d36fc45a50211320614daf2caede684b0d0963ce8738292809746", size = 20136798, upload-time = "2024-02-16T08:59:12.418Z" }, - { url = "https://files.pythonhosted.org/packages/ba/e9/c8b096e244e9b003efd35f4ace54dc4d62fa903db647421f4d49497988cb/pypandoc_binary-1.13-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:67c0c7af811bcf3cd4f3221be756a4975ec35b2d7df89d8de4313a8caa2cd54f", size = 18886568, upload-time = "2024-02-16T08:59:15.986Z" }, - { url = "https://files.pythonhosted.org/packages/c8/91/df8eff0a17a3e714589e84516aebaf82d952930ef0894a5b160ae7bcd3cb/pypandoc_binary-1.13-py3-none-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9455fdd9521cbf4b56d79a56b806afa94c8c22f3c8ef878536e58d941a70f6d6", size = 17055071, upload-time = "2024-02-16T08:59:19.59Z" }, - { url = "https://files.pythonhosted.org/packages/d3/56/91b26aa4cf417f62fccd46f733a9b9acf880e1dabd1d4302a9184b5c353d/pypandoc_binary-1.13-py3-none-musllinux_1_1_aarch64.whl", hash = "sha256:2915f52e4632bd2d0a8fcd2f7e7dfc2ea19b4e1a280fcbc2ddcd142713c4ff12", size = 18886559, upload-time = "2024-02-16T08:59:22.697Z" }, - { url = "https://files.pythonhosted.org/packages/b3/34/99e3f656ace162306270b387297933c9a8d7711b1ff1a3b8f5139e8805b1/pypandoc_binary-1.13-py3-none-musllinux_1_1_x86_64.whl", hash = "sha256:11a2497320eb3dccb74de3c67b6df3e5d3f66cdc2a36a67e9a871708f7e48412", size = 17055053, upload-time = "2024-02-16T08:59:26.292Z" }, - { url = "https://files.pythonhosted.org/packages/0a/d2/bcbf20b497d0393eb29b03d677eba204afdd4ce3af1ed0cd584194378e60/pypandoc_binary-1.13-py3-none-win_amd64.whl", hash = "sha256:3881aa7c84faec2007c0ae4466d3a1cfc93171206b8540f2defa8ea971bf6fd6", size = 24762997, upload-time = "2024-02-16T08:59:30.096Z" }, + { url = "https://files.pythonhosted.org/packages/80/85/681a54111f0948821a5cf87ce30a88bb0a3f6848af5112c912abac4a2b77/pypandoc_binary-1.17-py3-none-macosx_10_9_x86_64.whl", hash = "sha256:734726dc618ef276343e272e1a6b4567e59c2ef9ef41d5533042deac3b0531f1", size = 25553945, upload-time = "2026-03-14T22:38:47.91Z" }, + { url = "https://files.pythonhosted.org/packages/15/58/8fd107c68522957868c1e785fbea7595608df118e440e424d189668294df/pypandoc_binary-1.17-py3-none-macosx_11_0_arm64.whl", hash = "sha256:fcfd28f347ed998dda28823fc6bc24f9310e7fdf3ddceaf925bf0563a100ab5b", size = 25553944, upload-time = "2026-03-14T22:38:50.74Z" }, + { url = "https://files.pythonhosted.org/packages/f4/27/ac1078239aae14b94c51975b7f46ad8e099e47d7ae26c175a5486b1c0099/pypandoc_binary-1.17-py3-none-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl", hash = "sha256:d6b620b21c9374e3e48aabd518492bf0776b148442ee28816f6aaf52da3d4387", size = 34460960, upload-time = "2026-03-14T22:38:53.391Z" }, + { url = "https://files.pythonhosted.org/packages/8d/7f/1e5612b52900ebe590862dabeadf546f739b27527dcd8bfd632f8adac1be/pypandoc_binary-1.17-py3-none-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:9ada156cb980cd54fd6534231788e668c00dbb591cbd24f0be0bd86812eb8788", size = 36867598, upload-time = "2026-03-14T22:38:56.351Z" }, + { url = "https://files.pythonhosted.org/packages/3b/31/a5a867159c4080e5d368f4a53540a727501a2f31affc297dc8e0fced96a7/pypandoc_binary-1.17-py3-none-musllinux_1_2_aarch64.whl", hash = "sha256:2f439dcd211183bb3460253ca4511101df6e1acf4a01f45f5617e1fa2ad24279", size = 36867584, upload-time = "2026-03-14T22:38:59.087Z" }, + { url = "https://files.pythonhosted.org/packages/0d/2d/6a51cd4e54bdf132c19416801077c34bd40ba182e85d843360d36ae03a2d/pypandoc_binary-1.17-py3-none-musllinux_1_2_x86_64.whl", hash = "sha256:f6e6d3e4cfafbe23189a08db3d41f8def260bacd6e7e382bceadab7ba1f17da6", size = 34460949, upload-time = "2026-03-14T22:39:01.71Z" }, + { url = "https://files.pythonhosted.org/packages/c6/b9/f47b77ba75ed5d47ec85fcc2ecfbf7f78e3a73347f3a09836634d930de98/pypandoc_binary-1.17-py3-none-win_amd64.whl", hash = "sha256:76fae066cd2d7e78fb97f0ec8e9e36f437b07187b689b0b415ca18216f8f898a", size = 40891661, upload-time = "2026-03-14T22:39:04.782Z" }, ] [[package]] @@ -1083,6 +1072,15 @@ wheels = [ { url = "https://files.pythonhosted.org/packages/82/3b/64d4899d73f91ba49a8c18a8ff3f0ea8f1c1d75481760df8c68ef5235bf5/rich-15.0.0-py3-none-any.whl", hash = "sha256:33bd4ef74232fb73fe9279a257718407f169c09b78a87ad3d296f548e27de0bb", size = 310654, upload-time = "2026-04-12T08:24:02.83Z" }, ] +[[package]] +name = "roman-numerals" +version = "4.1.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/ae/f9/41dc953bbeb056c17d5f7a519f50fdf010bd0553be2d630bc69d1e022703/roman_numerals-4.1.0.tar.gz", hash = "sha256:1af8b147eb1405d5839e78aeb93131690495fe9da5c91856cb33ad55a7f1e5b2", size = 9077, upload-time = "2025-12-17T18:25:34.381Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/04/54/6f679c435d28e0a568d8e8a7c0a93a09010818634c3c3907fc98d8983770/roman_numerals-4.1.0-py3-none-any.whl", hash = "sha256:647ba99caddc2cc1e55a51e4360689115551bf4476d90e8162cf8c345fe233c7", size = 7676, upload-time = "2025-12-17T18:25:33.098Z" }, +] + [[package]] name = "ruff" version = "0.17.0" @@ -1146,8 +1144,42 @@ wheels = [ [[package]] name = "sphinx" -version = "7.1.2" +version = "9.0.4" +source = { registry = "https://pypi.org/simple" } +resolution-markers = [ + "python_full_version < '3.12'", +] +dependencies = [ + { name = "alabaster" }, + { name = "babel" }, + { name = "colorama", marker = "sys_platform == 'win32'" }, + { name = "docutils" }, + { name = "imagesize" }, + { name = "jinja2" }, + { name = "packaging" }, + { name = "pygments" }, + { name = "requests" }, + { name = "roman-numerals" }, + { name = "snowballstemmer" }, + { name = "sphinxcontrib-applehelp" }, + { name = "sphinxcontrib-devhelp" }, + { name = "sphinxcontrib-htmlhelp" }, + { name = "sphinxcontrib-jsmath" }, + { name = "sphinxcontrib-qthelp" }, + { name = "sphinxcontrib-serializinghtml" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/42/50/a8c6ccc36d5eacdfd7913ddccd15a9cee03ecafc5ee2bc40e1f168d85022/sphinx-9.0.4.tar.gz", hash = "sha256:594ef59d042972abbc581d8baa577404abe4e6c3b04ef61bd7fc2acbd51f3fa3", size = 8710502, upload-time = "2025-12-04T07:45:27.343Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/c6/3f/4bbd76424c393caead2e1eb89777f575dee5c8653e2d4b6afd7a564f5974/sphinx-9.0.4-py3-none-any.whl", hash = "sha256:5bebc595a5e943ea248b99c13814c1c5e10b3ece718976824ffa7959ff95fffb", size = 3917713, upload-time = "2025-12-04T07:45:24.944Z" }, +] + +[[package]] +name = "sphinx" +version = "9.1.0" source = { registry = "https://pypi.org/simple" } +resolution-markers = [ + "python_full_version >= '3.12'", +] dependencies = [ { name = "alabaster" }, { name = "babel" }, @@ -1158,6 +1190,7 @@ dependencies = [ { name = "packaging" }, { name = "pygments" }, { name = "requests" }, + { name = "roman-numerals" }, { name = "snowballstemmer" }, { name = "sphinxcontrib-applehelp" }, { name = "sphinxcontrib-devhelp" }, @@ -1166,9 +1199,9 @@ dependencies = [ { name = "sphinxcontrib-qthelp" }, { name = "sphinxcontrib-serializinghtml" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/dc/01/688bdf9282241dca09fe6e3a1110eda399fa9b10d0672db609e37c2e7a39/sphinx-7.1.2.tar.gz", hash = "sha256:780f4d32f1d7d1126576e0e5ecc19dc32ab76cd24e950228dcf7b1f6d3d9e22f", size = 6828258, upload-time = "2023-08-02T02:06:09.375Z" } +sdist = { url = "https://files.pythonhosted.org/packages/cd/bd/f08eb0f4eed5c83f1ba2a3bd18f7745a2b1525fad70660a1c00224ec468a/sphinx-9.1.0.tar.gz", hash = "sha256:7741722357dd75f8190766926071fed3bdc211c74dd2d7d4df5404da95930ddb", size = 8718324, upload-time = "2025-12-31T15:09:27.646Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/48/17/325cf6a257d84751a48ae90752b3d8fe0be8f9535b6253add61c49d0d9bc/sphinx-7.1.2-py3-none-any.whl", hash = "sha256:d170a81825b2fcacb6dfd5a0d7f578a053e45d3f2b153fecc948c37344eb4cbe", size = 3169543, upload-time = "2023-08-02T02:06:06.816Z" }, + { url = "https://files.pythonhosted.org/packages/73/f7/b1884cb3188ab181fc81fa00c266699dab600f927a964df02ec3d5d1916a/sphinx-9.1.0-py3-none-any.whl", hash = "sha256:c84fdd4e782504495fe4f2c0b3413d6c2bf388589bb352d439b2a3bb99991978", size = 3921742, upload-time = "2025-12-31T15:09:25.561Z" }, ] [[package]] @@ -1176,7 +1209,8 @@ name = "sphinx-basic-ng" version = "1.0.0b2" source = { registry = "https://pypi.org/simple" } dependencies = [ - { name = "sphinx" }, + { name = "sphinx", version = "9.0.4", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version < '3.12'" }, + { name = "sphinx", version = "9.1.0", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version >= '3.12'" }, ] sdist = { url = "https://files.pythonhosted.org/packages/98/0b/a866924ded68efec7a1759587a4e478aec7559d8165fac8b2ad1c0e774d6/sphinx_basic_ng-1.0.0b2.tar.gz", hash = "sha256:9ec55a47c90c8c002b5960c57492ec3021f5193cb26cebc2dc4ea226848651c9", size = 20736, upload-time = "2023-07-08T18:40:54.166Z" } wheels = [ @@ -1318,7 +1352,8 @@ docs-offline = [ { name = "furo" }, { name = "myst-parser" }, { name = "pypandoc-binary" }, - { name = "sphinx" }, + { name = "sphinx", version = "9.0.4", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version < '3.12'" }, + { name = "sphinx", version = "9.1.0", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version >= '3.12'" }, ] docs-online = [ { name = "mike" }, @@ -1353,25 +1388,25 @@ provides-extras = ["crypto-eth-addresses"] [package.metadata.requires-dev] docs-offline = [ - { name = "furo", specifier = ">=2024.8.6,<2025" }, - { name = "myst-parser", specifier = ">=3.0.1,<4" }, - { name = "pypandoc-binary", specifier = ">=1.13,<1.14" }, - { name = "sphinx", specifier = ">=7.1.2,<7.2" }, + { name = "furo", specifier = ">=2024.8.6" }, + { name = "myst-parser", specifier = ">=3.0.1" }, + { name = "pypandoc-binary", specifier = ">=1.13" }, + { name = "sphinx", specifier = ">=7.1.2" }, ] docs-online = [ { name = "mike", specifier = ">=2.1.3" }, - { name = "mkdocs", specifier = ">=1.6.1,<2" }, + { name = "mkdocs", specifier = ">=1.6.1" }, { name = "mkdocs-git-revision-date-localized-plugin", specifier = ">=1.2.7" }, - { name = "mkdocs-material", specifier = ">=9.5.34,<10" }, - { name = "mkdocstrings", extras = ["python"], specifier = ">=0.26.0,<1" }, - { name = "mkdocstrings-python", specifier = ">=1.10.5,<2" }, + { name = "mkdocs-material", specifier = ">=9.5.34" }, + { name = "mkdocstrings", extras = ["python"], specifier = ">=0.26.0" }, + { name = "mkdocstrings-python", specifier = ">=1.14.0" }, ] package = [{ name = "build", specifier = ">=1.2.1" }] runner = [{ name = "tox", specifier = ">=4.22" }] sast = [{ name = "bandit", extras = ["toml"], specifier = ">=1.7.9" }] testing = [{ name = "pytest", specifier = ">=9.0.3" }] tooling = [ - { name = "pypandoc-binary", specifier = ">=1.13,<1.14" }, + { name = "pypandoc-binary", specifier = ">=1.13" }, { name = "pyright", specifier = ">=1.1.378" }, { name = "pytest", specifier = ">=9.0.3" }, { name = "ruff", specifier = ">=0.6.3" }, From 5985f514cf2d61b74000218572a8932be1c44167 Mon Sep 17 00:00:00 2001 From: nandgator <38415384+nandgator@users.noreply.github.com> Date: Sat, 10 Oct 2026 13:40:59 +0530 Subject: [PATCH 2/2] docs: hide badges from the man page; regenerate docs with current tooling The newer docutils renders each README badge as '[image: ...] ' in the man page, so the export script now shows the badge row in html output only. Regenerate docs/index.rst (newer pandoc whitespace) and let ruff format the Python example in docs/install_and_use.md (and its rST copy). --- docs/index.rst | 12 +++++++----- docs/install_and_use.md | 3 ++- docs/install_and_use.rst | 3 ++- package/export/__main__.py | 24 +++++++++++++++++++++--- 4 files changed, 32 insertions(+), 10 deletions(-) diff --git a/docs/index.rst b/docs/index.rst index 14892901..ed4a0c4c 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -1,7 +1,9 @@ validators - Python Data Validation for Humans™ =============================================== -|PyCQA| |SAST| |Docs| |Version| |Downloads| +.. only:: html + + |PyCQA| |SAST| |Docs| |Version| |Downloads| .. raw:: html @@ -36,10 +38,10 @@ Resources -- `Documentation `__ -- `Bugtracker `__ -- `Security `__ -- `Code `__ +- `Documentation `__ +- `Bugtracker `__ +- `Security `__ +- `Code `__ .. diff --git a/docs/install_and_use.md b/docs/install_and_use.md index ed136587..d091a2ac 100644 --- a/docs/install_and_use.md +++ b/docs/install_and_use.md @@ -14,7 +14,8 @@ pip install validators ```python import validators -print(validators.email('someone@example.com')) + +print(validators.email("someone@example.com")) ``` ### To raise validation error diff --git a/docs/install_and_use.rst b/docs/install_and_use.rst index 7673cefb..d391df73 100644 --- a/docs/install_and_use.rst +++ b/docs/install_and_use.rst @@ -20,7 +20,8 @@ Usage .. code:: python import validators - print(validators.email('someone@example.com')) + + print(validators.email("someone@example.com")) To raise validation error ~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/package/export/__main__.py b/package/export/__main__.py index 4edd01c5..a32e6efe 100644 --- a/package/export/__main__.py +++ b/package/export/__main__.py @@ -4,6 +4,7 @@ from ast import ImportFrom, parse from os.path import getsize from pathlib import Path +from re import MULTILINE, sub from shutil import copy from subprocess import Popen # nosec @@ -53,6 +54,21 @@ def _gen_md_docs(source: Path, refs_path: Path): return mkdocs_build.returncode +def _hide_badges_from_man(rst: str): + """Show the badge row (e.g. `|PyCQA| |SAST|`) only in html output. + + The man builder renders every image as `[image: ...]` followed by its link target, + which is noise in a man page. + """ + return sub( + r"^(\|[^|\n]+\|(?: \|[^|\n]+\|)*)$", + lambda match: f".. only:: html\n\n {match.group(1)}", + rst, + count=1, + flags=MULTILINE, + ) + + def _gen_rst_docs(source: Path, refs_path: Path, only_web: bool = False, only_man: bool = False): """Generate reStructuredText docs.""" # external @@ -64,9 +80,11 @@ def _gen_rst_docs(source: Path, refs_path: Path, only_web: bool = False, only_ma with open(source / "docs/index.rst", "wt") as idx_f: idx_f.write( - convert_file(source_file=source / "docs/index.md", format="md", to="rst").replace( - "\r\n", - "\n", # remove carriage return in windows + _hide_badges_from_man( + convert_file(source_file=source / "docs/index.md", format="md", to="rst").replace( + "\r\n", + "\n", # remove carriage return in windows + ) ) + "\n\n.. toctree::" + "\n :hidden:"