With pep8 v1.5.7 the style check fails since checker_state (see #2160) is missing.
It may be worth considering adding a pep8 version check.
$ eb --check-style FLTK-1.3.3-GCC-5.4.0-2.26.eb
== temporary log file in case of crash /tmp/eb-bI3vwb/easybuild-0ref6J.log
Running style check on 1 easyconfig(s)...
Traceback (most recent call last):
File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/home/davide/Git/EasyBuild-develop/easybuild-framework/easybuild/main.py", line 478, in <module>
main()
File "/home/davide/Git/EasyBuild-develop/easybuild-framework/easybuild/main.py", line 349, in main
if cmdline_easyconfigs_style_check([path[0] for path in paths]):
File "/home/davide/Git/EasyBuild-develop/easybuild-framework/easybuild/framework/easyconfig/style.py", line 155, in cmdline_easyconfigs_style_check
if check_easyconfigs_style([path]) == 0:
File "/home/davide/Git/EasyBuild-develop/easybuild-framework/easybuild/framework/easyconfig/style.py", line 137, in check_easyconfigs_style
result = styleguide.check_files(easyconfigs)
File "/usr/lib/python2.7/dist-packages/pep8.py", line 1672, in check_files
runner(path)
File "/usr/lib/python2.7/dist-packages/pep8.py", line 1684, in input_file
return fchecker.check_all(expected=expected, line_offset=line_offset)
File "/usr/lib/python2.7/dist-packages/pep8.py", line 1420, in check_all
for token in self.generate_tokens():
File "/usr/lib/python2.7/dist-packages/pep8.py", line 1372, in generate_tokens
self.maybe_check_physical(token)
File "/usr/lib/python2.7/dist-packages/pep8.py", line 1382, in maybe_check_physical
self.check_physical(token[4])
File "/usr/lib/python2.7/dist-packages/pep8.py", line 1284, in check_physical
result = self.run_check(check, argument_names)
File "/usr/lib/python2.7/dist-packages/pep8.py", line 1277, in run_check
arguments.append(getattr(self, name))
AttributeError: 'Checker' object has no attribute 'checker_state'
With
pep8
v1.5.7 the style check fails sincechecker_state
(see #2160) is missing.It may be worth considering adding a
pep8
version check.