diff --git a/platypush/utils/reflection/_parser.py b/platypush/utils/reflection/_parser.py index fa89def7..888a2b60 100644 --- a/platypush/utils/reflection/_parser.py +++ b/platypush/utils/reflection/_parser.py @@ -99,6 +99,7 @@ class DocstringParser: _param_doc_re = re.compile(r"^:param\s+(?P[\w_]+):\s+(?P.*)$") _type_doc_re = re.compile(r"^:type\s+[\w_]+:.*$") _return_doc_re = re.compile(r"^:return:\s+(?P.*)$") + _default_docstring = re.compile(r"^Initialize self. See help") def __init__( self, @@ -164,6 +165,10 @@ class DocstringParser: ctx.state = ParseState.TYPE return + # Ignore the default constructor docstring + if cls._default_docstring.match(line): + return + # Update the return type docstring if required m = cls._return_doc_re.match(line) if m or (ctx.state == ParseState.RETURN and cls._is_continuation_line(line)):