Move decorator functions out of util into separate file
Move Exceptions classes to be together
Reorder imports, add __future__ imports and utf8 comments

The __future__ imports and utf8 comments are intended to make the code
more easily Python 3 compatible