For what it's worth, I don't have this problem...I tried a sample script that looks like:
import zmq print "In the script" print zmq.__version__ and it packages and runs OK. Version information below: pyinstaller version: today's version of the "develop" branch on github Python 2.6 32-bit Windows 7 Pyzmq 2.1.4 command line: $pyinstaller_path/pyinstaller.py z.py pyinstaller does complain about libzmq.dll not being found (during the build) but I guess it eventually does find it; it ends up being in the zmq directory underneath the executable. I tried one-dir and one-file builds, and they both worked. On Mon, May 6, 2013 at 5:33 PM, Jared Welch <[email protected]>wrote: > Hi there, > > > I am using pyinstaller 2.0, Python 2.7 on 64bit windows, and Pyzmq 2.2.0.1 > with corresponding ZMQ version. > > > I am trying to package an application that uses pyzmq and although the > dist directory conatains ALL of the dependencies and zmq .pyds and > libzmq.dll, I get errors when I run the .exe to test it. > > C:\Users\testerbox\pyinstaller-2.0\hello\dist\hello>hello.exe > Traceback (most recent call last): > File "<string>", line 4, in <module> > File > "C:\Users\testerbox\pyinstaller-2.0\pyinstaller-2.0\PyInstaller\loader\iu.py", > line 386, in importHook > File > "C:\Users\testerbox\pyinstaller-2.0\pyinstaller-2.0\PyInstaller\loader\iu.py", > line 480, in doimport > File > "C:\Users\testerbox\pyinstaller-2.0\hello\build\pyi.win32\hello\out00-PYZ.pyz\zmq", > line 45, in <module> > ImportError: cannot import name initthreads > Are you trying to `import zmq` from the pyzmq source dir? > > > I have tried this with several different apps. I have installed pyzmq and > zmq in every which way and still have this issue. In this case, I am only > importing zmq, not even using it in script as its just a test for using > pyinstaller. zmq.utils.initthreads.pyd is in the dist directory. > > From the python interpreter, or running as source code, zmq works > perfectly fine. It only seems to be an issue when its getting packaged. I > scoured the web for some help, but the only ticket on pyinstaller's issues > did not have an answer. ZMQ has a hook for it, but it doesn't seem to work > for initthreads. > > > Any help would be greatly appreciated. Thanks. > > -- > You received this message because you are subscribed to the Google Groups > "PyInstaller" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/pyinstaller?hl=en. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- Daniel Hyams [email protected] -- You received this message because you are subscribed to the Google Groups "PyInstaller" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/pyinstaller?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
