Modernize

Doesn't seem to be completely working in Python 3 yet.