結果 : how to write error log file in python