More fixes.

I thought flycheck + pep8 would catch most of the errors in the
editor, turns out it only warns of superficial issues, and leaves all
the real issues until runtime...