Added utf-8 encoding for python3
tidying up loose ends
Merge pull request #1 from senbot/master

Python 3 support