From: <gre...@gm...> - 2004-12-01 19:44:41
|
Hey Kevin, I'm still getting a new problem now. Per your example I changed my setup file to: from distutils.core import setup import py2exe setup( name =3D "JobRater", console =3D ["JobRater.py"], data_files =3D [ (".", ["JobRater.rsrc.py"]) ] ) Now I'm getting this error when I try to run it: Traceback (most recent call last): File "JobRater.py", line 65, in ? File "PythonCard\model.pyc", line 329, in __init__ File "PythonCard\resource.pyc", line 48, in getResource File "PythonCard\resource.pyc", line 86, in __init__ File "PythonCard\resource.pyc", line 91, in __init__ File "PythonCard\resource.pyc", line 91, in __init__ File "PythonCard\resource.pyc", line 96, in __init__ File "PythonCard\resource.pyc", line 139, in enforceSpec File "PythonCard\resource.pyc", line 30, in loadComponentModule ImportError: cannot import module 'button Any ideas? Thanks, Greg On Wed, 1 Dec 2004 14:40:46 -0500, Gregory Pi=F1ero <gre...@gm...> = wrote: > On Mon, 29 Nov 2004 13:29:09 -0800, Kevin Altis <al...@se...> = wrote: >=20 >=20 > > On Nov 28, 2004, at 2:37 PM, Gregory Pi=F1ero wrote: > > > > > > > > > Hi everyone, > > > > > > I'm trying to use py2exe on a small pythoncard app I made but when I > > > try to run the exe it says errors occured and in the log file it says= : > > > > > > Traceback (most recent call last): > > > File "JobRater.py", line 60, in ? > > > File "PythonCard\model.pyc", line 329, in __init__ > > > File "PythonCard\resource.pyc", line 45, in __init__ > > > File "PythonCard\util.pyc", line 30, in readAndEvalFile > > > IOError: [Errno 2] No such file or directory: 'JobRater.rsrc.py' > > > > > > Unfortunately I'm not sure what the correct method for using py2exe > > > with pythonCard is so I'm not sure if I'm doing something wrong or > > > what. This is my setup.py file: > > > > > > from distutils.core import setup > > > import py2exe > > > > > > setup(windows=3D["JobRater.py"]) > > > > > > And then I just call it as instructed on the py2exe website: > > > > > >>> python setup.py py2exe > > > > > > Any ideas what I could be doing wrong? Below I'll paste JobRater.py > > > and JobRater.rsrc.py just in case there's something wrong in those. > > > > > > Thanks, > > > > > > Greg > > > > > > > You need to specifically import the component modules that you use in > > your resource file, but your initial problem is that you need to > > included the .rsrc.py and any other data files you use either by > > manually copying them into the directory or just including them in the > > py2exe data files list. If you look at the minimalStandalone sample > > you'll see setup.py ... > > > > from distutils.core import setup > > import py2exe > > > > setup( name =3D "minimal", > > console =3D ["minimal.py"], > > data_files =3D [ (".", ["readme.txt", "minimal.rsrc.py"]) ] > > ) > > > > ka > > > > ------------------------------------------------------- > > SF email is sponsored by - The IT Product Guide > > Read honest & candid reviews on hundreds of IT Products from real users= . > > Discover which products truly live up to the hype. Start reading now. > > http://productguide.itmanagersjournal.com/ > > _______________________________________________ > > Pythoncard-users mailing list > > Pyt...@li... > > https://lists.sourceforge.net/lists/listinfo/pythoncard-users > > > |