Permalink
Comparing changes
Choose two branches to see what’s changed or to start a new pull request.
If you need to, you can also .
Open a pull request
Create a new pull request by comparing changes across two branches. If you need to, you can also .
- 6 commits
- 10 files changed
- 0 comments
- 3 contributors
Commits on Jul 24, 2020
Commits on Jul 29, 2020
Commits on Aug 21, 2020
Unified
Split
Showing
with
52 additions
and 8 deletions.
- +25 −3 CHANGELOG.md
- +1 −1 CREDITS.md
- +3 −3 pyproject.toml
- +1 −1 src/mkdocstrings/extension.py
- +2 −0 src/mkdocstrings/handlers/python.py
- +4 −0 src/mkdocstrings/templates/python/material/attribute.html
- +4 −0 src/mkdocstrings/templates/python/material/class.html
- +4 −0 src/mkdocstrings/templates/python/material/function.html
- +4 −0 src/mkdocstrings/templates/python/material/method.html
- +4 −0 src/mkdocstrings/templates/python/material/module.html
| @@ -5,6 +5,28 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) | ||
| and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). | ||
|
|
||
| <!-- insertion marker --> | ||
| ## [v0.13.0](https://github.com/pawamoy/mkdocstrings/releases/tag/v0.13.0) - 2020-08-21 | ||
|
|
||
| <small>[Compare with v0.12.2](https://github.com/pawamoy/mkdocstrings/compare/v0.12.2...v0.13.0)</small> | ||
|
|
||
| ### Bug Fixes | ||
| - Accept dashes in module names ([fcf79d0](https://github.com/pawamoy/mkdocstrings/commit/fcf79d0024ec46c3862c94202864e054c04a6d0b) by Timothée Mazzucotelli). References: [#140](https://github.com/pawamoy/mkdocstrings/issues/140) | ||
|
|
||
| ### Features | ||
| - Add option to show full path of direct members only ([d1b9401](https://github.com/pawamoy/mkdocstrings/commit/d1b9401afecb20d3123eec7334605cb15bf9d877) by Aaron Dunmore). References: [#134](https://github.com/pawamoy/mkdocstrings/issues/134), [#136](https://github.com/pawamoy/mkdocstrings/issues/136) | ||
|
|
||
| ### Packaging | ||
| - Accept `pymdown-extensions` versions up to 0.8.x ([see release notes](https://facelessuser.github.io/pymdown-extensions/about/releases/8.0/#8.0)) ([178d48d](https://github.com/pawamoy/mkdocstrings/commit/178d48da7a62daf285dfc5f6ff230e8bce82ed53) by Hugo van Kemenade). PR [#146](https://github.com/pawamoy/mkdocstrings/issue/146) | ||
|
|
||
|
|
||
| ## [v0.12.2](https://github.com/pawamoy/mkdocstrings/releases/tag/v0.12.2) - 2020-07-24 | ||
|
|
||
| <small>[Compare with v0.12.1](https://github.com/pawamoy/mkdocstrings/compare/v0.12.1...v0.12.2)</small> | ||
|
|
||
| ### Packaging | ||
| - Accept `pytkdocs` version up to 0.7.x ([changelog](https://pawamoy.github.io/pytkdocs/changelog/#v070-2020-07-24)). | ||
|
|
||
|
|
||
| ## [v0.12.1](https://github.com/pawamoy/mkdocstrings/releases/tag/v0.12.1) - 2020-07-07 | ||
|
|
||
| <small>[Compare with v0.12.0](https://github.com/pawamoy/mkdocstrings/compare/v0.12.0...v0.12.1)</small> | ||
| @@ -134,7 +156,7 @@ See issue [#74](https://github.com/pawamoy/mkdocstrings/issues/74). | ||
| ## [v0.9.0](https://github.com/pawamoy/mkdocstrings/releases/tag/v0.9.0) - 2020-03-21 | ||
|
|
||
| <small>[Compare with v0.8.0](https://github.com/pawamoy/mkdocstrings/compare/v0.8.0...v0.9.0)</small> | ||
|
|
||
| This version is a big refactor. We will just list the new features without pointing to particular commits. | ||
| The documentation rendering looks slightly different, and should be better than before. | ||
| No identified breaking changes for end-users. | ||
| @@ -151,7 +173,7 @@ No identified breaking changes for end-users. | ||
| [check the docs!](https://pawamoy.github.io/mkdocstrings/reference/handlers/python/#mkdocstrings.handlers.python.PythonRenderer.DEFAULT_CONFIG) | ||
| Also see the [recommended CSS](https://pawamoy.github.io/mkdocstrings/handlers/python/#recommended-style). | ||
| - **Proper logging messages:** `mkdocstrings` now logs debug, warning and error messages, useful when troubleshooting. | ||
|
|
||
| ### Bug fixes | ||
| - Various fixes and better error handling. | ||
|
|
||
| @@ -162,7 +184,7 @@ No identified breaking changes for end-users. | ||
|
|
||
| ### Breaking Changes | ||
| - Be compatible with Mkdocs >= 1.1 ([5a974a4](https://github.com/pawamoy/mkdocstrings/commit/5a974a4eb810904d6836e216d8539affc8acaa6f)). | ||
| This is a breaking change as we're not compatible with versions of Mkdocs below 1.1 anymore. | ||
| This is a breaking change as we're not compatible with versions of Mkdocs below 1.1 anymore. | ||
| If you cannot upgrade Mkdocs to 1.1, pin mkdocstrings' version to 0.7.2. | ||
|
|
||
| ## [v0.7.2](https://github.com/pawamoy/mkdocstrings/releases/tag/v0.7.2) - 2020-03-04 | ||
| @@ -82,7 +82,7 @@ These projects were used to build `mkdocstrings`. **Thank you!** | ||
| [`pluggy`](https://github.com/pytest-dev/pluggy) | | ||
| [`prompt-toolkit`](https://github.com/prompt-toolkit/python-prompt-toolkit) | | ||
| [`ptyprocess`](https://github.com/pexpect/ptyprocess) | | ||
| [`py`](http://py.readthedocs.io/) | | ||
| [`py`](https://py.readthedocs.io/) | | ||
| [`pycodestyle`](https://pycodestyle.readthedocs.io/) | | ||
| [`pydocstyle`](https://github.com/PyCQA/pydocstyle/) | | ||
| [`pyflakes`](https://github.com/PyCQA/pyflakes) | | ||
| @@ -4,7 +4,7 @@ build-backend = "poetry.masonry.api" | ||
|
|
||
| [tool.poetry] | ||
| name = "mkdocstrings" | ||
| version = "0.12.1" | ||
| version = "0.13.0" | ||
| description = "Automatic documentation from sources, for MkDocs." | ||
| authors = ["Timothée Mazzucotelli <pawamoy@pm.me>"] | ||
| license = "ISC License" | ||
| @@ -22,8 +22,8 @@ include = [ | ||
| python = "^3.6" | ||
| beautifulsoup4 = "^4.8.2" | ||
| mkdocs = "^1.1" | ||
| pymdown-extensions = ">=6.3, <8.0" | ||
| pytkdocs = ">=0.2.0, <0.7.0" | ||
| pymdown-extensions = ">=6.3, <9.0" | ||
| pytkdocs = ">=0.2.0, <0.8.0" | ||
|
|
||
| [tool.poetry.dev-dependencies] | ||
| bandit = "^1.5" | ||
| @@ -93,7 +93,7 @@ class AutoDocProcessor(BlockProcessor): | ||
| """ | ||
|
|
||
| CLASSNAME = "autodoc" | ||
| RE = re.compile(r"(?:^|\n)::: ?([:a-zA-Z0-9_.]*) *(?:\n|$)") | ||
| RE = re.compile(r"(?:^|\n)::: ?([:a-zA-Z0-9_.-]*) *(?:\n|$)") | ||
|
|
||
| def __init__(self, parser: BlockParser, md: Markdown, config: dict) -> None: | ||
| """ | ||
| @@ -39,6 +39,7 @@ class PythonRenderer(BaseRenderer): | ||
| "show_root_heading": False, | ||
| "show_root_toc_entry": True, | ||
| "show_root_full_path": True, | ||
| "show_root_members_full_path": False, | ||
| "show_object_full_path": False, | ||
| "show_category_heading": False, | ||
| "show_if_no_docstring": False, | ||
| @@ -55,6 +56,7 @@ class PythonRenderer(BaseRenderer): | ||
| **`show_root_toc_entry`** | `bool` | If the root heading is not shown, at least add a ToC entry for it. | `True` | ||
| **`show_root_full_path`** | `bool` | Show the full Python path for the root object heading. | `True` | ||
| **`show_object_full_path`** | `bool` | Show the full Python path of every object. | `False` | ||
| **`show_root_members_full_path`** | `bool` | Show the full Python path of objects that are children of the root object (for example, classes in a module). When False, `show_object_full_path` overrides. | `False` | ||
| **`show_category_heading`** | `bool` | When grouped by categories, show a heading for each category. | `False` | ||
| **`show_if_no_docstring`** | `bool` | Show the object heading even if it has no docstring or children with docstrings. | `False` | ||
| **`show_source`** | `bool` | Show the source code of this object. | `True` | ||
| @@ -6,6 +6,10 @@ | ||
|
|
||
| {% if root %} | ||
| {% set show_full_path = config.show_root_full_path %} | ||
| {% set root_members = True %} | ||
| {% elif root_members %} | ||
| {% set show_full_path = config.show_root_members_full_path or config.show_object_full_path %} | ||
| {% set root_members = False %} | ||
| {% else %} | ||
| {% set show_full_path = config.show_object_full_path %} | ||
| {% endif %} | ||
| @@ -6,6 +6,10 @@ | ||
|
|
||
| {% if root %} | ||
| {% set show_full_path = config.show_root_full_path %} | ||
| {% set root_members = True %} | ||
| {% elif root_members %} | ||
| {% set show_full_path = config.show_root_members_full_path or config.show_object_full_path %} | ||
| {% set root_members = False %} | ||
| {% else %} | ||
| {% set show_full_path = config.show_object_full_path %} | ||
| {% endif %} | ||
| @@ -6,6 +6,10 @@ | ||
|
|
||
| {% if root %} | ||
| {% set show_full_path = config.show_root_full_path %} | ||
| {% set root_members = True %} | ||
| {% elif root_members %} | ||
| {% set show_full_path = config.show_root_members_full_path or config.show_object_full_path %} | ||
| {% set root_members = False %} | ||
| {% else %} | ||
| {% set show_full_path = config.show_object_full_path %} | ||
| {% endif %} | ||
| @@ -6,6 +6,10 @@ | ||
|
|
||
| {% if root %} | ||
| {% set show_full_path = config.show_root_full_path %} | ||
| {% set root_members = True %} | ||
| {% elif root_members %} | ||
| {% set show_full_path = config.show_root_members_full_path or config.show_object_full_path %} | ||
| {% set root_members = False %} | ||
| {% else %} | ||
| {% set show_full_path = config.show_object_full_path %} | ||
| {% endif %} | ||
| @@ -6,6 +6,10 @@ | ||
|
|
||
| {% if root %} | ||
| {% set show_full_path = config.show_root_full_path %} | ||
| {% set root_members = True %} | ||
| {% elif root_members %} | ||
| {% set show_full_path = config.show_root_members_full_path or config.show_object_full_path %} | ||
| {% set root_members = False %} | ||
| {% else %} | ||
| {% set show_full_path = config.show_object_full_path %} | ||
| {% endif %} | ||