You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Punchline: from builtins import str; str(unidecode(str('2b or not 2b')))
"b'2b or not 2b'"
>>>fromunidecodeimportunidecode>>>str(unidecode(str('2b or not 2b'))) # no problem'2b or not 2b'>>>frombuiltinsimportstr>>>str(unidecode(str('2b or not 2b'))) # big problem"b'2b or not 2b'">>>str(str('2b or not 2b')) # str recursively all you want'2b or not 2b'>>>unidecode(str('2b or not 2b')) # `newbyte` obj is `repr`ed by unidecodeb'2b or not 2b'>>>unidecode('2b or not 2b')
'2b or not 2b'>>>unidecode(unidecode('2b or not 2b'))
'2b or not 2b'>>>unidecode(unidecode(b'2b or not 2b'))
'2b or not 2b'>>>unidecode(unidecode(str('2b or not 2b'))) # because future.builtins creates a newbytes type---------------------------------------------------------------------------AttributeErrorTraceback (mostrecentcalllast)
...
AttributeError: encodemethodhasbeendisabledinnewbytes>>>unidecode(str('2b or not 2b'))
b'2b or not 2b'
The text was updated successfully, but these errors were encountered:
Punchline:
from builtins import str; str(unidecode(str('2b or not 2b')))
"b'2b or not 2b'"
The text was updated successfully, but these errors were encountered: