[Python-modules-commits] r17513 - in packages/sphinx/trunk/debian/patches (2 files)
nikratio-guest at users.alioth.debian.org
nikratio-guest at users.alioth.debian.org
Sat Jun 18 00:35:26 UTC 2011
Date: Saturday, June 18, 2011 @ 00:35:24
Author: nikratio-guest
Revision: 17513
Activate docstring_parse.diff in series.
Disable docstring_signature by default.
Fix activation of docstring_signature in unittests.
Modified:
packages/sphinx/trunk/debian/patches/docstring_parse.diff
packages/sphinx/trunk/debian/patches/series
Modified: packages/sphinx/trunk/debian/patches/docstring_parse.diff
===================================================================
--- packages/sphinx/trunk/debian/patches/docstring_parse.diff 2011-06-17 21:27:51 UTC (rev 17512)
+++ packages/sphinx/trunk/debian/patches/docstring_parse.diff 2011-06-18 00:35:24 UTC (rev 17513)
@@ -21,7 +21,7 @@
+ looks like a signature, use the line as the signature and remove it
+ from the docstring content.
+
-+ The default is ``True``.
++ The default is ``False``.
+
+ .. versionadded:: 1.1
+
@@ -102,17 +102,15 @@
"""
Specialized Documenter subclass for functions.
"""
-@@ -847,8 +893,8 @@
+@@ -847,7 +893,7 @@
def format_args(self):
if inspect.isbuiltin(self.object) or \
inspect.ismethoddescriptor(self.object):
- # can never get arguments of a C function or method
-- return None
+ # cannot introspect arguments of a C function or method
-+ pass
+ return None
try:
argspec = inspect.getargspec(self.object)
- except TypeError:
@@ -937,7 +983,7 @@
self.add_line(_(u' Bases: %s') % ', '.join(bases),
'<autodoc>')
@@ -135,7 +133,7 @@
app.add_config_value('autoclass_content', 'class', True)
app.add_config_value('autodoc_member_order', 'alphabetic', True)
app.add_config_value('autodoc_default_flags', [], True)
-+ app.add_config_value('autodoc_docstring_signature', True, True)
++ app.add_config_value('autodoc_docstring_signature', False, True)
app.add_event('autodoc-process-docstring')
app.add_event('autodoc-process-signature')
app.add_event('autodoc-skip-member')
@@ -180,19 +178,12 @@
diff --git a/tests/test_autodoc.py b/tests/test_autodoc.py
--- a/tests/test_autodoc.py
+++ b/tests/test_autodoc.py
-@@ -40,6 +40,7 @@
- members = [],
- member_order = 'alphabetic',
- exclude_members = set(),
-+ docstring_signatures = True,
- )
-
- directive = Struct(
-@@ -501,6 +502,13 @@
+@@ -501,6 +501,14 @@
'attribute', 'mdocattr')
del directive.env.temp_data['autodoc:class']
+ # test autodoc_docstring_signature
++ directive.env.config.autodoc_docstring_signature = True
+ assert_result_contains(
+ '.. py:method:: DocstringSig.meth(FOO, BAR=1) -> BAZ', 'method',
+ 'test_autodoc.DocstringSig.meth')
Modified: packages/sphinx/trunk/debian/patches/series
===================================================================
--- packages/sphinx/trunk/debian/patches/series 2011-06-17 21:27:51 UTC (rev 17512)
+++ packages/sphinx/trunk/debian/patches/series 2011-06-18 00:35:24 UTC (rev 17513)
@@ -3,4 +3,4 @@
unversioned_grammar_pickle.diff
show_more_stack_frames.diff
fix_jquery_1.5_incompatibility.diff
-#docstring_parse.diff
+docstring_parse.diff
More information about the Python-modules-commits
mailing list