Changing str to unicode to avoid encoding errors