Fix tostring unicode
I'm not sure if this is perfect (or where else things like this might come up), but this fixes the failing test I added and the rest of the test suite passes. The issue arises when you give a string containing non-ascii characters. You have to decode to unicode (which I force to be utf-8...). I don't know the Python 3 issues, if any (it's in a Python 2 protected block of code). See issue #1620.
