# -*- mode: python -*-
a = Analysis(['app.py'],
             pathex=['/Users/doug/projects/chirp'],
             hiddenimports=[],
             hookspath=None,
             runtime_hooks=None)
pyz = PYZ(a.pure)
exe = EXE(pyz,
          a.scripts,
          a.binaries,
          a.zipfiles,
          a.datas,
          name='chirp',
          debug=False,
          strip=None,
          upx=True,
          console=False )
app = BUNDLE(exe,
             name='chirp.app',
             icon=None)

And the error detail is:

11778 INFO: Using Python library 
/usr/local/Cellar/python/2.7.5/Frameworks/Python.framework/Versions/2.7/Python
Traceback (most recent call last):
  File "bin/py", line 39, in <module>
    exec(compile(__file__f.read(), __file__, "exec"))
  File "build.py", line 9, in <module>
    load_entry_point('PyInstaller==2.1', 'console_scripts', 'pyinstaller')()
  File 
"/Users/doug/projects/chirp/eggs/PyInstaller-2.1-py2.7.egg/PyInstaller/main.py",
 
line 88, in run
    run_build(opts, spec_file, pyi_config)
  File 
"/Users/doug/projects/chirp/eggs/PyInstaller-2.1-py2.7.egg/PyInstaller/main.py",
 
line 46, in run_build
    PyInstaller.build.main(pyi_config, spec_file, **opts.__dict__)
  File 
"/Users/doug/projects/chirp/eggs/PyInstaller-2.1-py2.7.egg/PyInstaller/build.py",
 
line 1924, in main
    build(specfile, kw.get('distpath'), kw.get('workpath'), 
kw.get('clean_build'))
  File 
"/Users/doug/projects/chirp/eggs/PyInstaller-2.1-py2.7.egg/PyInstaller/build.py",
 
line 1873, in build
    execfile(spec)
  File "/Users/doug/projects/chirp/chirp.spec", line 6, in <module>
    runtime_hooks=None)
  File 
"/Users/doug/projects/chirp/eggs/PyInstaller-2.1-py2.7.egg/PyInstaller/build.py",
 
line 446, in __init__
    self.__postinit__()
  File 
"/Users/doug/projects/chirp/eggs/PyInstaller-2.1-py2.7.egg/PyInstaller/build.py",
 
line 309, in __postinit__
    self.assemble()
  File 
"/Users/doug/projects/chirp/eggs/PyInstaller-2.1-py2.7.egg/PyInstaller/build.py",
 
line 700, in assemble
    for ln in importTracker.getwarnings():
  File 
"/Users/doug/projects/chirp/eggs/PyInstaller-2.1-py2.7.egg/PyInstaller/depend/imptracker.py",
 
line 381, in getwarnings
    for w in mod.warnings:
TypeError: iteration over non-sequence

Which, when changed to a debug:

    def getwarnings(self):
        warnings = self.warnings.keys()
        for nm, mod in self.modules.items():
            if mod:
                try:
                  for w in mod.warnings:
                      warnings.append(w + ' - %s (%s)' % (mod.__name__, 
mod.__file__))
                except Exception as e:
                  print('%r' % e)
                  print('Unable to iterate over: %r' % mod.warnings)
                  from pprint import pprint
                  pprint(mod.warnings.__dict__)
        return warnings

It yields:

TypeError('iteration over non-sequence',)
Unable to iterate over: <PyInstaller.depend.modules.PyModule instance at 
0x102786b00>
{'__file__': 
'/usr/local/lib/python2.7/site-packages/sqlalchemy/testing/warnings.pyc',
 '__name__': 'sqlalchemy.testing.warnings',
 '_all': [],
 '_xref': {'sqlalchemy.testing': 1,
           'sqlalchemy.testing.assertions': 1,
           'sqlalchemy.testing.warnings': 1},
 'binaries': [],
 'co': <code object <module> at 0x102791eb0, file 
"/usr/local/lib/python2.7/site-packages/sqlalchemy/testing/warnings.py", 
line 1>,
 'datas': [],
 'imports': [('', 0, 0, 2),
             ('assertions.emits_warning', 1, 0, 1),
             ('assertions.eq_', 1, 0, 1),
             ('__future__', 0, 0, 0),
             ('warnings', 0, 0, 0),
             ('__future__.absolute_import', 0, 0, 0),
             ('util', 0, 0, 2),
             ('assertions', 1, 0, 1),
             ('exc', 0, 0, 2)],
 'warnings': []}

Bassssically, long story short, sqlalchemy now has a 'warnings' module in 
sqlalchemy/testing/warnings, which is conflicting with the 'warnings' 
member of PyInstaller/depends/module/Module.warnings, because of how 
modules are loaded, so the 'warnings' member becomes  a PkgModule (ie. 
sqlalchemy.testings.warnings) instead of the [] of warning messages.

I'm not sure what the best solution to that is, but it's definitely the 
cause.

~
Doug.

On Tuesday, October 8, 2013 4:57:23 AM UTC+8, Martin Z wrote:
>
> On Saturday 05 of October 2013 06:23:16 Alec van Niekerk wrote: 
> > I have the latest version of Pyinstaller and this is still a problem. 
>
> What is the content of your .spec file? 
>
>

-- 
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.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to