Change dialog.py encoding to utf-8