[python-win32] Found how to use TLBs with py2exe, anyhow problems
Andreas Maurer
pyama at snafu.de
Fri Feb 27 09:15:03 EST 2004
Hi there,
finding in the py2exe Wiki how to import TLBs in py2exe, it still
doesn't work.
This traceback will appear:
---
running py2exe
*** generate typelib stubs ***
Traceback (most recent call last):
File "setupget_VSS.py", line 48, in ?
console = [r"H:\Ablagen\py\Versionierung\get_VSS.py"],
File "C:\PROGRA~1\Python23\Lib\distutils\core.py", line 149, in setup
dist.run_commands()
File "C:\PROGRA~1\Python23\Lib\distutils\dist.py", line 907, in run_commands
self.run_command(cmd)
File "C:\PROGRA~1\Python23\Lib\distutils\dist.py", line 927, in run_command
cmd_obj.run()
File "C:\PROGRA~1\Python23\Lib\site-packages\py2exe\build_exe.py", line 180,
in run
self.typelibs)
File "C:\PROGRA~1\Python23\Lib\site-packages\py2exe\build_exe.py", line 1061,
in collect_win32
com_genpy
sub_mod = gencache..GetModuleForCLSID(clsid)
File "C:\PROGRA~1\Python23\Lib\site-packages\win32com\client\gencache.py",
line 240, in GetMod
uleForCLSID
makepy.GenerateChildFromTypeLibSpec(sub_mod, info)
File "C:\PROGRA~1\Python23\Lib\site-packages\win32com\client\makepy.py", line
306, in Generate
ChildFromTypeLibSpec
__import__("win32com.gen_py." + dir_name + "." + child)
File "H:\Ablagen\py\Setups\build\bdist.win32
\winexe\temp\win32com\gen_py\783CD4E0-9D54-11CF-B8EE-00608CC9A71Fx0x5x1
\IVSSDatabase.py", line 27, in ?
class IVSSDatabase(DispatchBaseClass):
NameError: name 'DispatchBaseClass' is not defined
---
In the setup file options are set in this way:
opts = {
"py2exe": {
"optimize": "2",
"dist_dir": r"H:\Ablagen\py\Versionierung\bin",
"typelibs": [('{783CD4E0-9D54-11CF-B8EE-00608CC9A71F}', 0, 5, 1)],
}
}
Again, the environment:
Python: 2.3.3
py2exe: 0.5.0
OS: W2K SP3
win32all: build 200
Regards
Andi
More information about the Python-win32
mailing list