Re: idle
Hi Franz, >>is there no IDLE in Python2.4? > > Sure, > on Windows: > > C:\Python24\Lib\idlelib\idle.pyw > You should have a shortcuts in your StartMenu > und Python 2.4 What about with Suse 9.3 und Python 2.4? o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
codecs
Hi there, sys.stdout = codecs.lookup('utf-8')[-1](sys.stdout) What does this line mean? Thanks. o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
idle
Hi, is there no IDLE in Python2.4? o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
Install MySQLdb on Mac OS X (10.3)
Hi, I can't install MySQLdb on Mac OS X (Ver. 10.3) properly. Here's my environment: 1. MySQL-python-1.0.0 2. Python 2.3 3. mysql -V /usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/bin/mysql Ver 14.7 Distrib 4.1.9, for apple-darwin7.7.0 (po werpc) 4. platform.platform() -> 'Darwin-7.6.0-Power_Macintosh-powerpc-32bit' 5. python setup.py build ... running build_ext building '_mysql' extension creating build/temp.darwin-7.6.0-Power_Macintosh-2.3 gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd -fno-common -dynamic -DNDEBUG -g -O3 -Wall - Wstrict-prototypes -I/usr/include/mysql -I/usr/local/include/mysql -I/usr/local/mysql/include -I/usr/local/mysql/inclu de/mysql -I/sw/include/mysql -I/System/Library/Frameworks/Python.framework/Versions/2.3/include/python2.3 -c _mysql.c -o build/temp.darwin-7.6.0-Power_Macintosh-2.3/_mysql.o _mysql.c: In function `_mysql_ConnectionObject_shutdown': _mysql.c:1545: error: too few arguments to function `mysql_shutdown' error: command 'gcc' failed with exit status 1 Can anybody enlighten me? Thanks for help. o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
Re: Install MySQLdb on Mac OS X (10.3)
Skip Montanaro wrote: TK> I can't install MySQLdb on Mac OS X (Ver. 10.3) properly. Here's my TK> environment: TK> 1. MySQL-python-1.0.0 ... Try a more recent version of mysql-python. I think 1.1.7 is the latest. Skip Hi Skip, > Try a more recent version of mysql-python. I think 1.1.7 is the latest. It now works with MySQL-python-1.2.0 And I have to set: export PATH=$PATH:/usr/local/mysql-standard-4.1.9-apple-darwin7.7.0-powerpc/bin Thanks for the hint. o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
__call__
Hi, how can handle __call__? Can you give a sample? Thanks o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
Re: __call__
class Test(object): > > ... def __call__(self): > ... print "the instance was called" > ... > t = Test() t() > > the instance was called > > Is this what you wanted? Yeah! Thanks. -- http://mail.python.org/mailman/listinfo/python-list
Re: __call__
Simon Percivall wrote: > Look at http://docs.python.org/ref/callable-types.html > > class Test(object): > > ... def __call__(self): > ... print "the instance was called" > ... > t = Test() t() > > the instance was called > > Is this what you wanted? Sorry but it does not work. Here's my code: >>> class Test(object): ... def __call__(self): ... print 'Hi' ... >>> Test() <__main__.Test object at 0x3e6d0> o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
Re: __call__
tiissa wrote: > TK wrote: > >> Sorry but it does not work. > > > It _does_ work. It just don't do what you expect. Seems so;-). Thanks a lot for help!!! o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
newbie-question
Hi, how can I implement a socket timeout? Thanx for help. o-o THomas -- http://mail.python.org/mailman/listinfo/python-list
Newbie question: Install Tkinter with Python2.5
Hi there, how can I install Tkinter with Python2.5? I can install Python2.5 (tarball) in the usual way but there is no Tkinter? What's wrong? Traceback (most recent call last): File "mbox.py", line 12, in from Tkinter import * File "/usr/local/lib/python2.5/lib-tk/Tkinter.py", line 38, in import _tkinter # If this fails your Python may not be configured for Tk ImportError: No module named _tkinter o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
Re: Newbie question: Install Tkinter with Python2.5
Hi, > I see that Tcl/Tk detection has been moved in the Python source > distribution (since the "good old days" when I last had to deal with > this kind of thing) from the configure machinery to the setup.py > program. However, a few things worth checking include (1) whether you > not only have the Tcl/Tk libraries but also the Tcl/Tk headers/ > includes and (2) whether they're installed in standard places or > somewhere else. > > Look for things like libtcl8.4.so, libtk8.4.so as well as tcl.h and > tk.h. If appropriate, check your distribution's packages and make sure > you have the developer packages (eg. tcl8.4-dev, tk8.4-dev) installed. It's not so simple ... . Thanx fpor help. o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
newbie question: apply()
HI, I need an example for the usage of the apply()-function. Can you help me? Thanks. o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
Re: newbie question: apply()
pos_args = ["spam", 1, [3]] kwd_args = {"b":7, "c":9} result = some_function(*pos_args, **kwd_args) Which is equivalent to: result = some_function("spam", 1, [3], b=7, c=9) Which was equivalent to: result = apply(some_function, pos_args, kwd_args) Thanks a lot. o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
newbie: decorator
Hi, I need an understandable Decorator-Example? Who can help? Thanks. o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list
Python-2.4.1 Build error on AIX
All, I get the below error when trying to build python on AIX. Is there a way to ignore _tkinter. Please help Sri I do the following in my command line. export CC=gcc ld: 0706-006 Cannot find or open library file: -l tk8.3 ld:open(): A file or directory in the path name does not exist. ld: 0706-006 Cannot find or open library file: -l tcl8.3 ld:open(): A file or directory in the path name does not exist. *** WARNING: renaming "_tkinter" since importing it failed: No such file or directory error: No such file or directory make: *** [sharedmods] Error 1 Start your day with Yahoo! - make it your home page http://www.yahoo.com/r/hs -- http://mail.python.org/mailman/listinfo/python-list
python2.4/site-packages
All, I have been successful in build/install of python2.4 on AIX. Now ,Is it mandatory that I build the third-party packages ( python2.4/site-packages) .If so is there a list that needs to be built and installed . Please advise. Start your day with Yahoo! - make it your home page http://www.yahoo.com/r/hs -- http://mail.python.org/mailman/listinfo/python-list
Query : sys.excepthook exception in Python
Hi, Sometimes during execution of python scripts below mentioned error string is displayed on the console. "Unhandled exception in thread started by Error in sys.excepthook: Original exception was:" The scripts are not terminated, they continue to execute normally. Is this is a problem with python? Is there any known solution. I am using Python 2.4. Thanks in Advance With Best Regards, Pramod TK -- http://mail.python.org/mailman/listinfo/python-list
Query regarding support for IPv6 in python
Hello All, I have some queries related to python support for IPv6. Can you kindly clarify the doubts which I have - 1. Does python support IPv6? [128 bit IP addresses?] 2. Does it support setting of QoS flags? 3. Does it support tunneling of IPv6 on a IPv4 network? 4. If an IPv4 address is given, does it support this on a IPv6 network? If not can you kindly let me know, Are there any plans for supporting these features in future? For Example - In IPv4 we have gethostbyname() function, which is deprecated in IPv6. In IPv6, getaddrinfo() and new data structure like struct addrinfo is introduced. Is this new function getaddrinfo() of IPv6 is supported in Win32 Extensions for python. Thanks in Advance, Pramod TK -- http://mail.python.org/mailman/listinfo/python-list
Query : sys.excepthook exception in Python
Title: Query : sys.excepthook exception in Python Hi, Sometimes during execution of python scripts below mentioned error string is displayed on the console. "Unhandled exception in thread started by Error in sys.excepthook: Original exception was:" The scripts are not terminated, they continue to execute normally. Is this is a problem with python? Is there any known solution. I am using Python 2.4. Thanks in Advance With Best Regards, Pramod TK -- http://mail.python.org/mailman/listinfo/python-list