summaryrefslogtreecommitdiff
path: root/sphinx/util/inspect.py
diff options
context:
space:
mode:
Diffstat (limited to 'sphinx/util/inspect.py')
-rw-r--r--sphinx/util/inspect.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/sphinx/util/inspect.py b/sphinx/util/inspect.py
index 6b404790c..5bac708f3 100644
--- a/sphinx/util/inspect.py
+++ b/sphinx/util/inspect.py
@@ -313,7 +313,10 @@ class Signature(object):
try:
self.signature = inspect.signature(subject)
except IndexError:
- if hasattr(subject, '_partialmethod'): # partialmethod with no argument
+ # Until python 3.6.4, cpython has been crashed on inspection for
+ # partialmethods not having any arguments.
+ # https://bugs.python.org/issue33009
+ if hasattr(subject, '_partialmethod'):
self.signature = None
self.partialmethod_with_noargs = True
else: