another string/byte fix/improvement for python3 compatibility