handle unicode better by decoding early and encoding late
python2 and python3 compatible utf8 encode and decode
Merge pull request #15 from alanhamlett/master

handle unicode better by decoding early and encoding late