Fix pyflakes errors