Merge pull request #5441 from tk0miya/use_collection.abc

napoleon: Use collections.abc
This commit is contained in:
Takeshi KOMIYA 2018-09-23 18:33:29 +09:00 committed by GitHub
commit f5616139e8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -11,7 +11,7 @@
:license: BSD, see LICENSE for details.
"""
import collections
import collections.abc
import inspect
import re
from functools import partial
@ -120,7 +120,7 @@ class GoogleDocstring(UnicodeMixin):
what = 'class'
elif inspect.ismodule(obj):
what = 'module'
elif isinstance(obj, collections.Callable): # type: ignore
elif isinstance(obj, collections.abc.Callable):
what = 'function'
else:
what = 'object'