2
votes

I'm trying to create a standalone test.app with py2app. When running

python setup.py py2app

I get the following messages:

Modules not found (unconditional imports):
 * __builtin__.open (repr)
 * __main__.__requires__ (pdb)
 * _imp (pkg_resources)
 * _weakref.CallableProxyType (_weakrefset)
 * _weakref.ProxyType (_weakrefset)
 * _weakref.ReferenceType (_weakrefset)
 * _weakref.getweakrefcount (_weakrefset)
 * _weakref.getweakrefs (_weakrefset)
 * _weakref.proxy (_weakrefset)
 * _winreg.CloseKey (urllib)
 * _winreg.HKEY_LOCAL_MACHINE (urllib)
 * _winreg.OpenKeyEx (urllib)
 * _winreg.QueryValueEx (urllib)
 * errno.EINVAL (os)
 * errno.ENOENT (os)
 * importlib.machinery (pkg_resources)
 * java.System (java.lang)
 * nt._getfullpathname (os)
 * nt._isdir (os)
 * org (org.python.core, pickle)
 * org.PyStringMap (org.python)
 * org.python (copy, pickle)
 * org.python.core (copy)
 * org.python.core.PyStringMap (pickle)
 * pkg_resources.extern.six.moves (pkg_resources)
 * pwd.getpwnam (distutils.util)
 * sys.getwindowsversion (os)
 * sys.py3kwarning (os)
 * thread._local (collections)
 * thread.allocate_lock (collections)
 * thread.stack_size (collections)

Modules not found (conditional imports):
 * _md5 (hashlib)
 * _sha (hashlib)
 * _sha256 (hashlib)
 * _sha512 (hashlib)
 * java (platform)
 * java.lang (platform)
 * riscospath (os)
Done!

The app is built but when I run it nothing happens (it works if I run it with python test.py)

This is py2app from the Anaconda distribution. Any ideas?

1

1 Answers

0
votes

You need to run python setup.py py2app -A. With the -A flag, the application will work, and there will be less warnings.