How to disable log file for py2exe?
<p>I've created a small script using <code>Python</code> and <code>PyQt4</code>, I converted it to <code>exe</code>. But there's some cases in my script that I'm not handling so a <code>log</code> file being created while using the program. So I wanna disable creating this <code>log</code> file.</p>

<p>How can I do that?</p>

<p>Here's my <code>setup.py</code> file:</p>

<pre><code>from distutils.core import setup
import py2exe
setup(
    windows=['DumbCalculator.py'],
    options = {
        "py2exe": {
            "dll_excludes": ["MSVCP90.dll"],  
        }
    },
    )
</code></pre>

<p>I finally found how to do that.</p>

<p>I went to <code>C:\Python27\Lib\site-packages\py2exe</code> and then opened <code>boot_common.py</code> file and commented the 56, 57, 58, 59, 60, 63, 64,65 lines and saved it.</p>

<p>I run py2exe again and tried the program works great. It makes a log file but doesn't run its annoying prompt. It worked for me !</p>

python python-2.7 pyqt4 py2exe