New user question: py2exe with Pmw

Armstrong fivearmstrongs at shaw.ca
Thu May 2 17:23:42 EDT 2002


Hi,

I have a pretty basic piece of Python code that uses the Pmw and Tcl/Tk
modules that I'm trying to run through py2exe.  The Tcl/Tk portion works
just fine, but when I enable the Pmw portion the executable won't run
anymore, failing with the message:

Traceback (most recent call last):
  File "imputil.pyc", line 103, in _import_hook
  File "<string>", line 52, in _import_top_module
  File "imputil.pyc", line 216, in import_top
  File "imputil.pyc", line 271, in _import_one
  File "<string>", line 128, in _process_result
  File "Pmw\__init__.pyc", line 37, in ?
IndexError: list index out of range

It looks to me like Pmw was not included, but I'm not sure. There's a tcl
directory created in the dist directory, but nothing for Pmw.  I looked
through
the docs for py2exe and it says it can do Pmw just fine, but I couldn't find
any other information on how to do this.  My setup file for the distro looks
like
this:

from distutils.core import setup
import py2exe

setup(
    scripts=["myscript.py"]
)

It's just the basic script from the examples... do I need to include some
more
information for py2exe to find the modules properly?

Thanks,
  Greg Armstrong





More information about the Python-list mailing list