building executable using python,vtk and py2exe
Tag : python , By : user185939
Date : March 29 2020, 07:55 AM
I hope this helps . This example uses py2exe. Use packages to add any referenced libraries and options includes to add dependencies. I am not too sure about the exact semantics and I reached this stable configuration after much trial and error. Hopefully, you can use this as a template to go ahead. from distutils.core import setup
import py2exe
import modulefinder
from iso8601 import iso8601
setup(name='exeExample',
version='1.0',
description='Exe example using py2Exe',
author='Urjit Singh Bhatia',
author_email='person@user.com',
packages=['example', 'someLib'],
console=['src\\a.py',
'src\\b.py',
'src\\c.py',
'src\\d.py'],
options={"py2exe":{"includes":["someLib","csv","iso8601","pymssql","uuid","decimal","urllib2","traceback","re","_mssql","os"]}}
)
|
Py2Exe Error: Win32com.client causes errors when trying to run created executable
Tag : python , By : user122937
Date : March 29 2020, 07:55 AM
around this issue This was solved by upgrading to Python 2.7. I originally had Python 2.6 installed but the update solved this issue.
|
Creating executable with Py2exe and matplotlib errors
Date : March 29 2020, 07:55 AM
I hope this helps . I am not fully sure this will fix your problem, but you should start by correcting that faulty options dictionary entry. In python, when you define a dictionary with the same key over and over, you are only going to get the last value. A key can only exist once: options={
r'py2exe': {
r'includes': r'ElementConfig',
...
r'includes': r'mpl_toolkits',
r'includes': r'matplotlib.backends.backend_wx',
...
}
}
print options
#{'py2exe': {'includes': 'matplotlib.backends.backend_wx'}}
options={
'py2exe':{
'includes': [
'ElementConfig',
'ColorConv',
'Tkinter',
're',
'math',
'sys',
'matplotlib',
'mpl_toolkits',
'matplotlib.backends.backend_wx'
],
'dll_excludes': ['MSVCP90.dll'],
}
},
'includes': [
...
'matplotlib.backends.backend_qt4agg'
],
|
Py2exe errors when building executable
Tag : python , By : Phil Austin
Date : March 29 2020, 07:55 AM
fixed the issue. Will look into that further I compiled your program (the imports) and it runs OK for me. the py2exe missed module report is not relevant if you are not using those modules (I got the same list as that you show). Remember that the executable will run while you execute it within the dist module py2exe creates (and not from a copy in your desktop, for example. For that you need to make a direct access link).
|
How to make a python script executable in py2exe?
Date : March 29 2020, 07:55 AM
|