Re: [Pythonmac-SIG] import problems

2005-12-12 Thread Ronald Oussoren
On 12-dec-2005, at 20:57, Zhi Peng wrote: > Hi! Ronald > > I run your makefile. it is compiled and run as one > command. But I still can not import module. > The error message is "can not import module wave". That's not a very useful message :-(. BTW. why does it refer to module wave? It should

Re: [Pythonmac-SIG] import problems

2005-12-12 Thread Zhi Peng
Hi! Ronald I run your makefile. it is compiled and run as one command. But I still can not import module. The error message is "can not import module wave". I think there is something wrong on my Mac, because the program is simple enough. What was the version of you python? I assume it is pyt

Re: [Pythonmac-SIG] import problems

2005-12-12 Thread Ronald Oussoren
On 12-dec-2005, at 20:48, Zhi Peng wrote: > > Thanks Ronald and everyone. My OS is Tiger. This shows > me that my Python installation or default has been > changed or something is missing for sure. It is > strange for me to see this type of results. What's the output if you insert a call to PyEr

Re: [Pythonmac-SIG] import problems

2005-12-12 Thread Zhi Peng
Thanks Ronald and everyone. My OS is Tiger. This shows me that my Python installation or default has been changed or something is missing for sure. It is strange for me to see this type of results. Regards Zhi --- Ronald Oussoren <[EMAIL PROTECTED]> wrote: > > On 12-dec-2005, at 19:30, Z

[Pythonmac-SIG] import problems

2005-12-12 Thread Zhi Peng
Hi! All If you use MacPython2.3 on MAc, please try the following code to see if you can get "StringModule" imported. //=StringModule.py=== #!pythonw import os class Module1: def __init__(self): self.var1= 9 def method1(self): self.v

Re: [Pythonmac-SIG] import problems

2005-12-09 Thread Zhi Peng
Bob Let me say Thanks a lot for your email First, then I will read corresponding document. Surely it helps a lot. Regards Zhi --- Bob Ippolito <[EMAIL PROTECTED]> wrote: > > On Dec 9, 2005, at 3:55 PM, Zhi Peng wrote: > > > What was the difference when I try to install > module say I ha

Re: [Pythonmac-SIG] import problems

2005-12-09 Thread Bob Ippolito
On Dec 9, 2005, at 3:55 PM, Zhi Peng wrote: > What was the difference when I try to install module say I have > module.py on Macintosh? > > from distutils.core import setup > setup(name="MyModule", version="1.0" py_modules=["module.py"]) > > > Is above enough to set up the module? Where are "mo

Re: [Pythonmac-SIG] import problems

2005-12-09 Thread Zhi Peng
Thanks all   I have to add #!pythonw # -*- coding: Latin-1 -*-   at beginging of the file macerrors to get rid of warning message   What was the difference when I try to install module say I have module.py on Macintosh?   from distutils.core import setup setup(name="MyModule", version

Re: [Pythonmac-SIG] import problems

2005-12-09 Thread Bob Ippolito
On Dec 9, 2005, at 3:19 PM, Zhi Peng wrote: > /System/Library/Frameworks/Python.framework/Versions/2.3/lib/ > python2.3/plat-mac/macerrors.py > on line 326, but no encoding declared; see > http://www.python.org/peps/pep-0263.html for details > import macerrors > > But if I erased "from appscri

[Pythonmac-SIG] import problems

2005-12-09 Thread Zhi Peng
Hi! All When I have module say module.py with sentance like #!pythonw import os from appscript import * and then import from terminal say pythonw, it show me error or warning message /System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/aem/send/errors.py:5: