From a9ef286bcee5bc7e54e013137f677b61bcfb4d41 Mon Sep 17 00:00:00 2001 From: Andrey Vlasovskikh Date: Sun, 19 Nov 2023 02:36:00 +0300 Subject: [PATCH] Updated mkdocstrings to use python instead of python-legacy --- mkdocs.yml | 4 +- poetry.lock | 105 +++++++++++++++++++++---------------------------- pyproject.toml | 2 +- 3 files changed, 47 insertions(+), 64 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index 8520928..a8df647 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -54,11 +54,11 @@ plugins: - mkdocstrings: handlers: python: - rendering: + options: show_root_toc_entry: false show_root_heading: true + heading_level: 3 show_source: false - selection: members: false watch: - funcparserlib diff --git a/poetry.lock b/poetry.lock index 413a072..a1da2cf 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,20 +1,5 @@ # This file is automatically @generated by Poetry 1.7.0 and should not be changed by hand. -[[package]] -name = "astunparse" -version = "1.6.3" -description = "An AST unparser for Python" -optional = false -python-versions = "*" -files = [ - {file = "astunparse-1.6.3-py2.py3-none-any.whl", hash = "sha256:c2652417f2c8b5bb325c885ae329bdf3f86424075c4fd1a128674bc6fba4b8e8"}, - {file = "astunparse-1.6.3.tar.gz", hash = "sha256:5ad93a8456f0d084c3456d059fd9a92cce667963232cbf763eac3bc5b7940872"}, -] - -[package.dependencies] -six = ">=1.6.1,<2.0" -wheel = ">=0.23.0,<1.0" - [[package]] name = "babel" version = "2.13.1" @@ -245,6 +230,20 @@ python-dateutil = ">=2.8.1" [package.extras] dev = ["flake8", "markdown", "twine", "wheel"] +[[package]] +name = "griffe" +version = "0.38.0" +description = "Signatures for entire Python programs. Extract the structure, the frame, the skeleton of your project, to generate API documentation or find breaking changes in your API." +optional = false +python-versions = ">=3.8" +files = [ + {file = "griffe-0.38.0-py3-none-any.whl", hash = "sha256:6a5bc457320e8e199006aa5fbb03e162f5e21abe31aa6221f7a5c37ea0724c71"}, + {file = "griffe-0.38.0.tar.gz", hash = "sha256:9b97487b583042b543d1e28196caee638ecd766c8c4c98135071806cb5333ac2"}, +] + +[package.dependencies] +colorama = ">=0.4" + [[package]] name = "identify" version = "2.5.32" @@ -482,23 +481,27 @@ files = [ [[package]] name = "mkdocstrings" -version = "0.20.0" +version = "0.24.0" description = "Automatic documentation from sources, for MkDocs." optional = false -python-versions = ">=3.7" +python-versions = ">=3.8" files = [ - {file = "mkdocstrings-0.20.0-py3-none-any.whl", hash = "sha256:f17fc2c4f760ec302b069075ef9e31045aa6372ca91d2f35ded3adba8e25a472"}, - {file = "mkdocstrings-0.20.0.tar.gz", hash = "sha256:c757f4f646d4f939491d6bc9256bfe33e36c5f8026392f49eaa351d241c838e5"}, + {file = "mkdocstrings-0.24.0-py3-none-any.whl", hash = "sha256:f4908560c10f587326d8f5165d1908817b2e280bbf707607f601c996366a2264"}, + {file = "mkdocstrings-0.24.0.tar.gz", hash = "sha256:222b1165be41257b494a9d29b14135d2b7ca43f38161d5b10caae03b87bd4f7e"}, ] [package.dependencies] +click = ">=7.0" +importlib-metadata = {version = ">=4.6", markers = "python_version < \"3.10\""} Jinja2 = ">=2.11.1" Markdown = ">=3.3" MarkupSafe = ">=1.1" -mkdocs = ">=1.2" +mkdocs = ">=1.4" mkdocs-autorefs = ">=0.3.1" -mkdocstrings-python-legacy = {version = ">=0.2.1", optional = true, markers = "extra == \"python-legacy\""} +mkdocstrings-python = {version = ">=0.5.2", optional = true, markers = "extra == \"python\""} +platformdirs = ">=2.2.0" pymdown-extensions = ">=6.3" +typing-extensions = {version = ">=4.1", markers = "python_version < \"3.10\""} [package.extras] crystal = ["mkdocstrings-crystal (>=0.3.4)"] @@ -506,19 +509,19 @@ python = ["mkdocstrings-python (>=0.5.2)"] python-legacy = ["mkdocstrings-python-legacy (>=0.2.1)"] [[package]] -name = "mkdocstrings-python-legacy" -version = "0.2.3" -description = "A legacy Python handler for mkdocstrings." +name = "mkdocstrings-python" +version = "1.7.4" +description = "A Python handler for mkdocstrings." optional = false -python-versions = ">=3.7" +python-versions = ">=3.8" files = [ - {file = "mkdocstrings-python-legacy-0.2.3.tar.gz", hash = "sha256:3fb58fdabe19c6b52b8bb1d3bb1540b1cd527b562865468d6754e8cd1201050c"}, - {file = "mkdocstrings_python_legacy-0.2.3-py3-none-any.whl", hash = "sha256:1b04d71a4064b0bb8ea9448debab89868a752c7e7bfdd11de480dfbcb9751a00"}, + {file = "mkdocstrings_python-1.7.4-py3-none-any.whl", hash = "sha256:70eacbe5f2d5071f2e525ba0b35bc447d398437dfbcd90c63fe6e977551cfe26"}, + {file = "mkdocstrings_python-1.7.4.tar.gz", hash = "sha256:c2fc34efd70000ec31aee247910006e8dd9d1b9f3957bf46880c3f6e51a8f0d5"}, ] [package.dependencies] -mkdocstrings = ">=0.19" -pytkdocs = ">=0.14" +griffe = ">=0.37" +mkdocstrings = ">=0.20" [[package]] name = "nodeenv" @@ -680,23 +683,6 @@ files = [ [package.dependencies] six = ">=1.5" -[[package]] -name = "pytkdocs" -version = "0.16.1" -description = "Load Python objects documentation." -optional = false -python-versions = ">=3.7" -files = [ - {file = "pytkdocs-0.16.1-py3-none-any.whl", hash = "sha256:a8c3f46ecef0b92864cc598e9101e9c4cf832ebbf228f50c84aa5dd850aac379"}, - {file = "pytkdocs-0.16.1.tar.gz", hash = "sha256:e2ccf6dfe9dbbceb09818673f040f1a7c32ed0bffb2d709b06be6453c4026045"}, -] - -[package.dependencies] -astunparse = {version = ">=1.6", markers = "python_version < \"3.9\""} - -[package.extras] -numpy-style = ["docstring_parser (>=0.7)"] - [[package]] name = "pytz" version = "2023.3.post1" @@ -964,6 +950,17 @@ virtualenv = ">=20.24.3" docs = ["furo (>=2023.8.19)", "sphinx (>=7.2.4)", "sphinx-argparse-cli (>=1.11.1)", "sphinx-autodoc-typehints (>=1.24)", "sphinx-copybutton (>=0.5.2)", "sphinx-inline-tabs (>=2023.4.21)", "sphinxcontrib-towncrier (>=0.2.1a0)", "towncrier (>=23.6)"] testing = ["build[virtualenv] (>=0.10)", "covdefaults (>=2.3)", "detect-test-pollution (>=1.1.1)", "devpi-process (>=1)", "diff-cover (>=7.7)", "distlib (>=0.3.7)", "flaky (>=3.7)", "hatch-vcs (>=0.3)", "hatchling (>=1.18)", "psutil (>=5.9.5)", "pytest (>=7.4)", "pytest-cov (>=4.1)", "pytest-mock (>=3.11.1)", "pytest-xdist (>=3.3.1)", "re-assert (>=1.1)", "time-machine (>=2.12)", "wheel (>=0.41.2)"] +[[package]] +name = "typing-extensions" +version = "4.8.0" +description = "Backported and Experimental Type Hints for Python 3.8+" +optional = false +python-versions = ">=3.8" +files = [ + {file = "typing_extensions-4.8.0-py3-none-any.whl", hash = "sha256:8f92fc8806f9a6b641eaa5318da32b44d401efaac0f6678c9bc448ba3605faa0"}, + {file = "typing_extensions-4.8.0.tar.gz", hash = "sha256:df8e4339e9cb77357558cbdbceca33c303714cf861d1eef15e1070055ae8b7ef"}, +] + [[package]] name = "urllib3" version = "2.1.0" @@ -1039,20 +1036,6 @@ files = [ [package.extras] watchmedo = ["PyYAML (>=3.10)"] -[[package]] -name = "wheel" -version = "0.41.3" -description = "A built-package format for Python" -optional = false -python-versions = ">=3.7" -files = [ - {file = "wheel-0.41.3-py3-none-any.whl", hash = "sha256:488609bc63a29322326e05560731bf7bfea8e48ad646e1f5e40d366607de0942"}, - {file = "wheel-0.41.3.tar.gz", hash = "sha256:4d4987ce51a49370ea65c0bfd2234e8ce80a12780820d9dc462597a6e60d0841"}, -] - -[package.extras] -test = ["pytest (>=6.0.0)", "setuptools (>=65)"] - [[package]] name = "zipp" version = "3.17.0" @@ -1071,4 +1054,4 @@ testing = ["big-O", "jaraco.functools", "jaraco.itertools", "more-itertools", "p [metadata] lock-version = "2.0" python-versions = "^3.8" -content-hash = "ce88c22c9c8dd90bfa0210917f2dc9e9a7173eca2774882bf41e24d0da6f8870" +content-hash = "b3d49827188f4d4505b8e0e14a290b2bcfdd645834209f34a5e3f26e6d8eb74b" diff --git a/pyproject.toml b/pyproject.toml index b500622..91d97d0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -26,7 +26,7 @@ pre-commit = {version = "^3.5.0"} tox = {version = "^4.4.6"} mkdocs = {version = "^1.4.2"} mkdocs-material = {version = "^9.1.1"} -mkdocstrings = {extras = ["python-legacy"], version = "^0.20.0"} +mkdocstrings = {extras = ["python"], version = "^0.24.0"} [build-system] requires = ["poetry-core>=1.5.1"]