Traceback (most recent call last):
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/bin/flake8", line 11, in <module>
sys.exit(main())
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/flake8/main.py", line 36, in main
report = flake8_style.check_files()
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/flake8/engine.py", line 181, in check_files
return self._retry_serial(self._styleguide.check_files, paths=paths)
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/flake8/engine.py", line 172, in _retry_serial
return func(*args, **kwargs)
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/pycodestyle.py", line 1877, in check_files
runner(path)
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/flake8/engine.py", line 126, in input_file
return fchecker.check_all(expected=expected, line_offset=line_offset)
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/pycodestyle.py", line 1608, in check_all
self.check_ast()
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/pycodestyle.py", line 1555, in check_ast
for lineno, offset, text, check in checker.run():
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/flake8_import_order/flake8_linter.py", line 52, in run
for error in self.check_order():
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/flake8_import_order/__init__.py", line 289, in check_order
first_str = build_str(k)
File "/Users/ulo/Envs/tmp-686c3c2aab00eaf/lib/python3.5/site-packages/flake8_import_order/__init__.py", line 283, in build_str
if level >= 0:
TypeError: unorderable types: NoneType() >= int()
In pep8 mode code files containing standard library imports after third party ones cause a TypeError in
ImportOrderChecker.check_order.build_str
.Minimal example:
test.py
: