must be str not bytearray.