CFY-717 flake8 fixes