Cannot register dll created using "py2exe --com-dll"

Jordan Tucker jtuc at ev1.net
Tue Jul 29 10:55:52 EDT 2003


A fix that seems to work (at least it lets DllRegisterServer succeed) is inserting
the following before the aforementioned line:

      scriptDir = None
      if hasattr(sys, 'argv'):
        scriptDir = os.path.split(sys.argv[0])[0]

This allows registration, but now when I try to instantiate one of the objects
defined in my dll from the interpreter, I get the following error:

Fatal Python error: PyThreadState_Get: no current thread

This also happens with the server example included. Do I have to use something
other than win32com.client.Dispatch to connect to an inproc server from a
dll? I think I've used it before to do the same thing with non-py2exe dlls.

Jordan




More information about the Python-list mailing list