[Pythonmac-SIG] Module Import Problem

Mike smartmike1 at gmail.com
Sun Apr 25 06:15:24 CEST 2010


Hi,

We're using Mac OSX 10.5. We got the same error on Mac OSX 10.6, and we're 
not building as of yet...just running using the python interpreter. Here's 
the full traceback:

Xelabos-Mac-Pro:src MacAdmin$ python zgp.py
Traceback (most recent call last):
  File "zgp.py", line 18, in <module>
    main()
  File "zgp.py", line 13, in main
    output.setup()
  File "/Users/MacAdmin/Desktop/ZGP/src/output.py", line 24, in setup
    speaker=pyttsx.init()
  File "build/bdist.macosx-10.6-universal/egg/pyttsx/__init__.py", line 39, 
in init
  File "build/bdist.macosx-10.6-universal/egg/pyttsx/engine.py", line 45, in 
__init__
  File "build/bdist.macosx-10.6-universal/egg/pyttsx/driver.py", line 64, in 
__init__
  File "build/bdist.macosx-10.6-universal/egg/pyttsx/drivers/nsss.py", line 
18, in <module>
ImportError: No module named Foundation
----- Original Message ----- 
From: "Aahz" <aahz at pythoncraft.com>
To: <pythonmac-sig at python.org>
Sent: Saturday, April 24, 2010 12:22 PM
Subject: Re: [Pythonmac-SIG] Module Import Problem


> On Wed, Apr 21, 2010, Mike wrote:
>>
>> My friend is testing my program for me on his Mac, he's running Snow
>> leopard. I'm using a package called Pyttsc that allows for text to
>> speech on the Mac. He's getting the following error:
>>
>> file: build/bdist.macosx-10.6universal/egpyttsx/drivers/nsss.py, line 18: 
>> no module named foundation
>>
>> I looked into this, and it seems to be something related to
>> PyObjC. However, he tried import pyobjc and got no errors. Any idea
>> what the problem might be and how to fix it?
>
> What's your OS?  What's the line of code generating this error?
>
>> Also, will this application build with py2app since it uses this package?
>
> Theoretically, yes.  I'm a bit confused, because build/ implies that
> you're already using py2app or some other distribution mechanism.
> -- 
> Aahz (aahz at pythoncraft.com)           <*> 
> http://www.pythoncraft.com/
>
> "It is easier to optimize correct code than to correct optimized code."
> --Bill Harlan
> _______________________________________________
> Pythonmac-SIG maillist  -  Pythonmac-SIG at python.org
> http://mail.python.org/mailman/listinfo/pythonmac-sig
> unsubscribe: http://mail.python.org/mailman/options/Pythonmac-SIG 



More information about the Pythonmac-SIG mailing list