File tree 1 file changed +15
-0
lines changed 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change 76
76
'{allowed_sections}' ,
77
77
'GL07' : 'Wrong order of sections. "{wrong_section}" should be located '
78
78
'before "{goes_before}", the right order is: {sorted_sections}' ,
79
+ 'GL08' : 'No docstring found' ,
79
80
'SS01' : 'No summary found (a short summary in a single line should be '
80
81
'present at the beginning of the docstring)' ,
81
82
'SS02' : 'Summary does not start with a capital letter' ,
@@ -585,6 +586,20 @@ def validate_one(func_name):
585
586
586
587
errs = []
587
588
wrns = []
589
+
590
+ if len (doc .raw_doc ) == 0 :
591
+ errs .append (error ('GL08' ))
592
+ return {
593
+ 'type' : doc .type ,
594
+ 'docstring' : doc .clean_doc ,
595
+ 'deprecated' : doc .deprecated ,
596
+ 'file' : doc .source_file_name ,
597
+ 'file_line' : doc .source_file_def_line ,
598
+ 'github_link' : doc .github_url ,
599
+ 'errors' : errs ,
600
+ 'warnings' : wrns ,
601
+ 'examples_errors' : []}
602
+
588
603
if doc .start_blank_lines != 1 :
589
604
errs .append (error ('GL01' ))
590
605
if doc .end_blank_lines != 1 :
You can’t perform that action at this time.
0 commit comments