Questions tagged [py2exe]

Py2exe is a python extension that converts Python Scripts to Windows Executables.

py2exe is a extension which converts Python scripts (.py) into Windows executables (.exe). These executables can run on a system without Python installed. It is the most common tool for doing so.

py2exe was used to distribute the official BitTorrent client (prior to version 6.0) and is still used to distribute SpamBayes as well as other projects.

Resources

1654 questions
14
votes
5 answers

Access denied using Py2exe

I'm using Py2exe to create an executable as a windows service. When I run the script I get this error: File "C:\TeamCity\buildAgent\work\582d895bd5b431ac\winpython\WinPython-32bit-2.7.3.3\python-2.7.3\lib\site-packages\py2exe\build_exe.py", line…
Be.St.
  • 4,101
  • 3
  • 25
  • 35
14
votes
6 answers

ImportError: no module named py2exe

I get this error when I try to use one of the py2exe samples with py2exe. File "setup.py", line 22, in ? import py2exe ImportError: no module named py2exe I've installed py2exe with the installer, and I use python 2.6. I have downloaded the…
Reshure
  • 3,295
  • 5
  • 28
  • 26
13
votes
5 answers

py2exe to generate dlls?

Is there a way using py2exe or some other method to generate dll files instead of exe files? I would want to basically create a normal win32 dll with normal functions but these functions would be coded in python instead of c++.
Brian R. Bondy
  • 339,232
  • 124
  • 596
  • 636
13
votes
4 answers

Fixing SSL certificate error in exe compiled with py2exe (or PyInstaller)

I've just finished testing a Python programme which involves logging into a site and requires a CSRF cookie to be set. I've tried packaging it as an exe using py2exe and got a socket error. I have the same problem when I try with PyInstaller.…
Jamie Bull
  • 12,889
  • 15
  • 77
  • 116
12
votes
4 answers

Where can I find a good tutorial for py2exe?

Can somebody point me at a good tutorial for py2exe? I've read over the official tutorial but it is rather light on details, compared to all the options one can use when building an executable out of a python script. For the record, my python…
Manzabar
  • 676
  • 5
  • 11
11
votes
3 answers

ImportError: No module named cycler

I am using wxpython and matplotlib to develop a software, when I complete my work, I want to convert the python files to *.exe file by py2exe, so it can be used in Windows. Here is the setup.py file. from distutils.core import setup import py2exe …
Elivis
  • 307
  • 1
  • 6
  • 18
11
votes
2 answers

Py2Exe "Missing Modules"

I'm trying to convert my python project into an exe using Py2Exe. It is worth noting that cx_freeze complains about the same three "missing modules", along with several dozen others. The problem is, no one anywhere tells how to resolve this. I'm…
CodeMouse92
  • 6,840
  • 14
  • 73
  • 130
11
votes
2 answers

pyttsx compilation error in windows using py2xe

I have written a python application with using pyttsx library . its working without any issue from tt.py file. I compiled this tt.py file using py2exe module. after compilation i tried to run .exe file. then its shows error like given…
open source guy
  • 2,727
  • 8
  • 38
  • 61
11
votes
2 answers

A single executable file with Py2Exe

I have been trying to make a single executable file and I am getting close. Please do not recommend that I use PyInstaller -- I have tried that route, asked on SO here, and have put in tickets. It is close but not quite working. I am now trying…
mcfly
  • 1,151
  • 4
  • 33
  • 55
11
votes
4 answers

py2exe - No system module 'pywintypes'

I'm trying to convert a simple Python script into a Windows executable. My setup.py script is: from distutils.core import setup import py2exe setup( name = "Simple Script", options = { "py2exe": { "dll_excludes" :…
sebo
  • 1,584
  • 4
  • 16
  • 19
11
votes
3 answers

Py2exe: Are manifest files and w9xpopen.exe required when compiling a web server without GUI interface?

I'm using Py2exe to compile a CherryPy (3.1) server using Python 2.6 (32-bit) on Windows 7 Pro (64-bit). This server will run without a GUI. Questions: Do I need to be concerned about adding a manifest file for this application if it runs without a…
Malcolm
  • 5,125
  • 10
  • 52
  • 75
11
votes
2 answers

How to package Twisted program with py2exe?

I tried to package a Twisted program with py2exe, but once I run the exe file I built, I got a "No module named resource" error. And I found the py2exe said: The following modules appear to be missing ['FCNTL', 'OpenSSL', 'email.Generator',…
Fang-Pen Lin
  • 13,420
  • 15
  • 66
  • 96
11
votes
3 answers

Can Django be used with py2exe?

We'd like to create a Django Intranet application for mass market. We only need to support Windows users, and it needs to be very easy for a Windows admin (or "technical user") to deploy (baring in mind that most Windows admins/users have little…
Nick Bolton
  • 38,276
  • 70
  • 174
  • 242
10
votes
1 answer

Changing the icon of the produced .exe, py2exe

Ive been googling this however none of the results worked for me. Here is my setup file setup( windows = [ { "script": "start.py", "icon_resources": [(1, "myicon.ico")] } ], ) The icon of the actual .exe file should be…
thelost
  • 695
  • 3
  • 12
  • 29
10
votes
12 answers

Enabling JPEG support for QImage in py2exe-compiled Python scripts?

I'm trying to use a JPEG image in a QImage object from a Python script, with PyQt4. The script itself works perfectly, the image loads and can be manipulated and rendered and all. However, when I try to "compile" this script with py2exe,…
Etienne Perot
  • 4,764
  • 7
  • 40
  • 50