SyntaxFix
Write A Post
Hire A Developer
Questions
If you should get the following by trying decode():
decode()
AttributeError: 'str' object has no attribute 'decode'
You can also specify the encoding type straight in a cast:
>>> my_byte_str b'Hello World' >>> str(my_byte_str, 'utf-8') 'Hello World'