vbuterin/pybitcointools — pull request #48 by nelisky (2014-10-21 23:38:14+00:00)
Title: spreading the string or unicode check for variables.

Some cases had only str while others both str and unicode. I came across a specific case where having only str broke it for me.

Nitpicking a bit the 'proper' way to do this would be:

from types import StringTypes

if isinstance(var, StringTypes):
# do something

as there's always a chance another string type gets added to the core lib (though I seriously doubt it).