Python 3

An update to add support for Python 3, consisting mostly of
* Unicode literals
* BytesIO
* Ensuring the encoding when dealing with incoming data (defaulting to UTF-8)

Also a couple of tweaks to get the tests working with Python 3, and behaving consistently.
py26 fails because `collections.OrderedDict` doesn't exist. I'll throw you a pull request soon.