Example #1
0
def pep8_check(filename):
    # default pep8 setup
    pep8.options = _PEP8Options()
    pep8.options.physical_checks = pep8.find_checks('physical_line')
    pep8.options.logical_checks = pep8.find_checks('logical_line')
    pep8.args = []

    pep8.input_file(filename)
Example #2
0
def check_file(path, complexity=-1):
    warnings = pyflakes.checkPath(path)
    warnings += pep8.input_file(path)
    if complexity > -1:
        warnings += mccabe.get_module_complexity(path, complexity)
    return warnings
Example #3
0
def check_file(path, complexity=-1):
    warnings = pyflakes.checkPath(path)
    warnings += pep8.input_file(path)
    if complexity > -1:
        warnings += mccabe.get_module_complexity(path, complexity)
    return warnings