fixed a python3 failure due to incompatible encoding