From a0595407aced4df572cd8dda01cccbb2874f9710 Mon Sep 17 00:00:00 2001 From: Sraw Date: Wed, 25 Jul 2018 14:14:50 +0800 Subject: [PATCH] Fix coverage problem and add newsfragments. BTW, fix a bug in pyproject.toml --- newsfragments/13.bugfix.rst | 1 + newsfragments/14.removal.rst | 1 + pyproject.toml | 2 +- sphinxcontrib_trio/__init__.py | 1 + 4 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 newsfragments/13.bugfix.rst create mode 100644 newsfragments/14.removal.rst diff --git a/newsfragments/13.bugfix.rst b/newsfragments/13.bugfix.rst new file mode 100644 index 0000000..1d5ce0e --- /dev/null +++ b/newsfragments/13.bugfix.rst @@ -0,0 +1 @@ +Fix autodoc_member_order="bysource" doesn't work for async methods. \ No newline at end of file diff --git a/newsfragments/14.removal.rst b/newsfragments/14.removal.rst new file mode 100644 index 0000000..25729a9 --- /dev/null +++ b/newsfragments/14.removal.rst @@ -0,0 +1 @@ +Remove support for sphinx<1.6. \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 4b65ac8..6c8f6c0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -5,7 +5,7 @@ # customize this) # - At release time after bumping version number, run: towncrier # (or towncrier --draft) -package = "sphinxcontrib-trio" +package = "sphinxcontrib_trio" filename = "docs/source/index.rst" directory = "newsfragments" underlines = ["+", "~", "^"] diff --git a/sphinxcontrib_trio/__init__.py b/sphinxcontrib_trio/__init__.py index 295e292..a654e12 100644 --- a/sphinxcontrib_trio/__init__.py +++ b/sphinxcontrib_trio/__init__.py @@ -380,6 +380,7 @@ def setup(app): # A monkey-patch to VariableCommentPicker to make autodoc_member_order = 'bysource' work. from sphinx.pycode.parser import VariableCommentPicker + # pragma: no cover if not hasattr(VariableCommentPicker, "visit_AsyncFunctionDef"): VariableCommentPicker.visit_AsyncFunctionDef = VariableCommentPicker.visit_FunctionDef