CFY-1000 flake8 fixes