Update log.py

encode change to UTF-8