We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7096342 commit e5bab77Copy full SHA for e5bab77
scripts/validate_docstrings.py
@@ -269,8 +269,15 @@ def pandas_validate(func_name: str):
269
# Some objects are instances, e.g. IndexSlice, which numpydoc can't validate
270
doc_obj = get_doc_object(func_obj, doc=func_obj.__doc__)
271
doc = PandasDocstring(func_name, doc_obj)
272
- result = validate(doc_obj)
273
-
+ if func_obj.__doc__ is not None:
+ result = validate(doc_obj)
274
+ else:
275
+ result = {
276
+ "docstring": "",
277
+ "file": None,
278
+ "file_line": None,
279
+ "errors": [("GL08", "The object does not have a docstring")],
280
+ }
281
mentioned_errs = doc.mentioned_private_classes
282
if mentioned_errs:
283
result["errors"].append(
0 commit comments