Flake8ify #2231

Fixed all flake8 issues

Task ID : 2231
Review ID : 343001