Tried to be a good citizen and corrected a lot of flake8 warnings in librarian.