Update pycat.py

Change comments' alignment, change order of declaring functions and declare file_buffer outside of the condition for safety