##// END OF EJS Templates
check-commit: allow foo_bar naming in functions...
Gregory Szorc -
r43382:24a07347 default
parent child Browse files
Show More
@@ -340,8 +340,6 b' commonpypats = ['
340 340 ),
341 341 (r'[^\n]\Z', "no trailing newline"),
342 342 (r'(\S[ \t]+|^[ \t]+)\n', "trailing whitespace"),
343 # (r'^\s+[^_ \n][^_. \n]+_[^_\n]+\s*=',
344 # "don't use underbars in identifiers"),
345 343 (
346 344 r'^\s+(self\.)?[A-Za-z][a-z0-9]+[A-Z]\w* = ',
347 345 "don't use camelcase in identifiers",
@@ -39,12 +39,6 b' errors = ['
39 39 "summary keyword should be most user-relevant one-word command or topic"),
40 40 (afterheader + r".*\.\s*\n", "don't add trailing period on summary line"),
41 41 (afterheader + r".{79,}", "summary line too long (limit is 78)"),
42 # Forbid "_" in function name.
43 #
44 # We skip the check for cffi related functions. They use names mapping the
45 # name of the C function. C function names may contain "_".
46 (r"\n\+[ \t]+def (?!cffi)[a-z]+_[a-z]",
47 "adds a function with foo_bar naming"),
48 42 ]
49 43
50 44 word = re.compile(r'\S')
@@ -130,6 +130,4 b' A patch with other errors:'
130 130 This has no topic and ends with a period.
131 131 7: don't add trailing period on summary line
132 132 This has no topic and ends with a period.
133 20: adds a function with foo_bar naming
134 + def blah_blah(x):
135 133 [1]
General Comments 0
You need to be logged in to leave comments. Login now