python freeze help

Mike Driscoll kyosohma at gmail.com
Tue Sep 23 17:21:04 CEST 2008


On Sep 23, 5:01 am, Gabriel Rossetti <gabriel.rosse... at arimaz.com>
wrote:
> Hello everyone,
>
> I'm trying to use python's freeze utility but I'm running into problems.
> I called it like this :
>
> python /usr/share/doc/python2.5/examples/Tools/freeze/freeze.py
> ~/Documents/Code/Python/src/jester/service.py -m jester
>
> then I did : make
>
> then I tried to run it : ./service
>
> and I get this :
>
> grossetti at desktop-01:~/tmp/freeze$ ./service
> Traceback (most recent call last):
>   File "/home/grossetti/Documents/Code/Python/src/jester/service.py",
> line 16, in <module>
>     from jester import constants, utils
>   File "/home/grossetti/Documents/Code/Python/src/jester/utils.py", line
> 20, in <module>
>     from twisted.internet.protocol import Protocol, ClientCreator
>   File "/usr/lib/python2.5/site-packages/twisted/internet/protocol.py",
> line 17, in <module>
>     from zope.interface import implements
>   File "/usr/lib/python2.5/site-packages/zope/__init__.py", line 20, in
> <module>
>     pkg_resources.declare_namespace('zope')
>   File "/usr/lib/python2.5/site-packages/pkg_resources.py", line 1749,
> in declare_namespace
>     _handle_ns(packageName, path_item)
>   File "/usr/lib/python2.5/site-packages/pkg_resources.py", line 1719,
> in _handle_ns
>     path = module.__path__; path.append(subpath)
> AttributeError: 'str' object has no attribute 'append'
> Error in sys.excepthook:
> Traceback (most recent call last):
>   File "/usr/lib/python2.5/site-packages/apport_python_hook.py", line
> 38, in apport_excepthook
>     from apport.packaging_impl import impl as packaging
>   File "/usr/lib/python2.5/site-packages/apport/__init__.py", line 1, in
> <module>
>     from apport.report import Report
>   File "/usr/lib/python2.5/site-packages/apport/report.py", line 20, in
> <module>
>     from problem_report import ProblemReport
>   File "/usr/lib/python2.5/site-packages/problem_report.py", line 18, in
> <module>
>     from email.MIMEMultipart import MIMEMultipart
>   File "/usr/lib/python2.5/email/__init__.py", line 79, in __getattr__
>     __import__(self.__name__)
> ImportError: No module named multipart


I've gotten this error from py2exe before. I'm not sure how freeze
works, but in py2exe I had to make sure the email package wasn't being
accidentally excluded and explicitly included.


>
> Original exception was:
> Traceback (most recent call last):
>   File "/home/grossetti/Documents/Code/Python/src/jester/service.py",
> line 16, in <module>
>     from jester import constants, utils
>   File "/home/grossetti/Documents/Code/Python/src/jester/utils.py", line
> 20, in <module>
>     from twisted.internet.protocol import Protocol, ClientCreator
>   File "/usr/lib/python2.5/site-packages/twisted/internet/protocol.py",
> line 17, in <module>
>     from zope.interface import implements
>   File "/usr/lib/python2.5/site-packages/zope/__init__.py", line 20, in
> <module>
>     pkg_resources.declare_namespace('zope')
>   File "/usr/lib/python2.5/site-packages/pkg_resources.py", line 1749,
> in declare_namespace
>     _handle_ns(packageName, path_item)
>   File "/usr/lib/python2.5/site-packages/pkg_resources.py", line 1719,
> in _handle_ns
>     path = module.__path__; path.append(subpath)
> AttributeError: 'str' object has no attribute 'append'
>
> Does anyone have any ideas as of why I get this?
>
> Thank you,
> Gabriel

I don't know what this second error is...

Mike



More information about the Python-list mailing list