hmm.  I think your code is cleaner.  don't know why mine is so complicated, but probably I had some problems wih unicode on Python 3.  Well, let's go with your version and TravisCI will complain in case there is something going on.