2020-01-21 运行$ flake8 /path/to/file 报了如下错误:
"pyflakes" failed during execution due to "'FlakesChecker' object has no attribute 'NAMEDEXPR'"
Run flake8 with greater verbosity to see more details
原因是flake8依赖pyflake,而pyflake虽然修复了这个问题,但并未release到pypi
--------------------------------------------------------------------------------------------------------------
解决:
pip install git+https://github.com/PyCQA/pyflakes.git --user --upgrade
如果github太慢可以换成它的加速镜像站:
pip install git+https://hub.fastgit.org/PyCQA/pyflakes.git --user --upgrade