Re: 0 in [True,False] returns True

2005-12-13 Thread Antoon Pardon
Op 2005-12-12, Fredrik Lundh schreef [EMAIL PROTECTED]: Pierre Quentel wrote: In some program I was testing if a variable was a boolean, with this test : if v in [True,False] My script didn't work in some cases and I eventually found that for v = 0 the test returned True So I changed my

Re: 0 in [True,False] returns True

2005-12-13 Thread bonono
Antoon Pardon wrote: Op 2005-12-12, Fredrik Lundh schreef [EMAIL PROTECTED]: Pierre Quentel wrote: In some program I was testing if a variable was a boolean, with this test : if v in [True,False] My script didn't work in some cases and I eventually found that for v = 0 the test

Re: ElementTree - Why not part of the core?

2005-12-13 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: ElementTree on the other hand provides incredibly easy access to XML elements and works in a more Pythonic way. Why has the API not been included in the Python core? $ svn up $ make ... $ python Python 2.5a0 (#1, Dec 12 2005, 19:26:49) import xml.etree.ElementTree

Re: 0 in [True,False] returns True

2005-12-13 Thread Steve Holden
Pierre Quentel wrote: Hi all, In some program I was testing if a variable was a boolean, with this test : if v in [True,False] My script didn't work in some cases and I eventually found that for v = 0 the test returned True So I changed my test for the obvious if type(v) is bool, but

Re: ActivePython and Amara

2005-12-13 Thread Steve Holden
Jay wrote: Woah woah woah, calm your ass down a little. I didn't say that the hijacker made it go off topic. Did I? I just said that the thread was going off topic from the dam title. We weren't talking about XML no more now were we. And who the hell are you talking to thinking that I

Re: 0 in [True,False] returns True

2005-12-13 Thread Paul Rubin
Steve Holden [EMAIL PROTECTED] writes: The really interesting question your post raises, though, is Why do you feel it's necessary to test to see whether a variable is a Boolean?. What's the point of having Booleans, if you can't tell them from integers? --

Re: 0 in [True,False] returns True

2005-12-13 Thread Antoon Pardon
Op 2005-12-13, Steve Holden schreef [EMAIL PROTECTED]: Pierre Quentel wrote: Hi all, In some program I was testing if a variable was a boolean, with this test : if v in [True,False] My script didn't work in some cases and I eventually found that for v = 0 the test returned True So I

Re: 0 in [True,False] returns True

2005-12-13 Thread Erik Max Francis
Paul Rubin wrote: Steve Holden [EMAIL PROTECTED] writes: The really interesting question your post raises, though, is Why do you feel it's necessary to test to see whether a variable is a Boolean?. What's the point of having Booleans, if you can't tell them from integers? Because

python configuration problems

2005-12-13 Thread ivan . pavlov
I am running Debian/Linux unstable. Trying to upgrade packages depending on python (via aptitude) has started to give errors and leaves all packeges unconfigured. When I run dpkg --configure pyhton2.3 the following errors occur. Any advice on what to do? Setting up python2.3 (2.3.5-8) ...

Re: python configuration problems

2005-12-13 Thread ivan . pavlov
I solved the problem myself. Just removed the folder where the errors were occuring. Don't know how it came to exists in the first place though. Now everything seems to work fine, for now... -- http://mail.python.org/mailman/listinfo/python-list

Re: 0 in [True,False] returns True

2005-12-13 Thread Steve Holden
Paul Rubin wrote: Steve Holden [EMAIL PROTECTED] writes: The really interesting question your post raises, though, is Why do you feel it's necessary to test to see whether a variable is a Boolean?. What's the point of having Booleans, if you can't tell them from integers? Booleans are

Re: 0 in [True,False] returns True

2005-12-13 Thread Fredrik Lundh
Erik Max Francis wrote: What's the point of having Booleans, if you can't tell them from integers? Because return True is clearer than return 1 if the purpose of the return value is to indicate a Boolean rather than an arbitrary integer. the real reason booleans were added was that

Re: ActivePython and Amara

2005-12-13 Thread James
Jay, Profanity is unwelcome in this newsgroup. Alex's advice is very well placed and you will realize that once you stop seeing it as a personal attack. Different newsgroups have different attitudes. comp.lang.python is not exactly a tech support group. Bug reports posters here are frequently

Re: python configuration problems

2005-12-13 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: I am running Debian/Linux unstable. Trying to upgrade packages depending on python (via aptitude) has started to give errors and leaves all packeges unconfigured. When I run dpkg --configure pyhton2.3 the following errors occur. the srcb package uses 2.4 features

Re: 0 in [True,False] returns True

2005-12-13 Thread Robin Becker
Carsten Haese wrote: ... Where/how did you search? http://docs.python.org/lib/typesseq.html states unambiguously that x in s returns True if an item of s is equal to x, else False . exactly and I see 0==False True so I guess nothing is wrong :) -- Robin Becker --

Re: 0 in [True,False] returns True

2005-12-13 Thread bonono
Erik Max Francis wrote: Paul Rubin wrote: Steve Holden [EMAIL PROTECTED] writes: The really interesting question your post raises, though, is Why do you feel it's necessary to test to see whether a variable is a Boolean?. What's the point of having Booleans, if you can't tell them

Re: 0 in [True,False] returns True

2005-12-13 Thread Steve Holden
Antoon Pardon wrote: Op 2005-12-13, Steve Holden schreef [EMAIL PROTECTED]: Pierre Quentel wrote: Hi all, In some program I was testing if a variable was a boolean, with this test : if v in [True,False] My script didn't work in some cases and I eventually found that for v = 0 the test

Re: Developing a network protocol with Python

2005-12-13 Thread Laszlo Zsolt Nagy
Tom Anderson wrote: I think to be effective, I need to use TCP_NODELAY, and manually buffered transfers. Why? Because of the big delays when sending small messages (size 1500 bytes). Personally, i'd steer clear of doing it like this, and try to use an existing, language-neutral

How To Read Excel Files In Python?

2005-12-13 Thread Anand
Hello, Can I get some help on how to read the excel files using python? from win32com.client import Dispatch xlApp = Dispatch(Excel.Application) xlWb = xlApp.Workbooks.Open(Read.xls) xlSht = xlWb.WorkSheets(1) But sadly, I am unable to proceed further about how to read the cells of the

Re: 0 in [True,False] returns True

2005-12-13 Thread Erik Max Francis
[EMAIL PROTECTED] wrote: True, but if that is the only reason, Two built-in value of True/False(0/1) serves the need which is what is now(well sort of). Why have seperate types and distinguish them ? Because of this: x = True y = 1 # but I mean it to represent true

Re: 0 in [True,False] returns True

2005-12-13 Thread bonono
Erik Max Francis wrote: [EMAIL PROTECTED] wrote: True, but if that is the only reason, Two built-in value of True/False(0/1) serves the need which is what is now(well sort of). Why have seperate types and distinguish them ? Because of this: x = True y = 1 # but I mean it

Re: 0 in [True,False] returns True

2005-12-13 Thread Erik Max Francis
[EMAIL PROTECTED] wrote: True too, and could be the reason(or similar too) why the OP wants to test the type rather than the logical value of it. The type is for the self-documentation purposes. The value is the same; so no, that's not a good reason either. -- Erik Max Francis [EMAIL

RE: How To Read Excel Files In Python?

2005-12-13 Thread Tim Golden
[Anand] Can I get some help on how to read the excel files using python? from win32com.client import Dispatch xlApp = Dispatch(Excel.Application) xlWb = xlApp.Workbooks.Open(Read.xls) xlSht = xlWb.WorkSheets(1) But sadly, I am unable to proceed further about how to read the cells of the

Re: 0 in [True,False] returns True

2005-12-13 Thread Duncan Booth
wrote: if the purpose of the return value is to indicate a Boolean rather than an arbitrary integer. True, but if that is the only reason, Two built-in value of True/False(0/1) serves the need which is what is now(well sort of). Why have seperate types and distinguish them ? True == 1

Re: How To Read Excel Files In Python?

2005-12-13 Thread Dennis Benzinger
Anand schrieb: Hello, Can I get some help on how to read the excel files using python? [...] Besides using the Excel component you could use the pyExcelerator http://sourceforge.net/projects/pyexcelerator module. You even don't need Windows for it. Bye, Dennis --

Re: 0 in [True,False] returns True

2005-12-13 Thread quentel . pierre
Ok, I'll explain why I wanted to test if the value was a boolean I have a program that generates HTML tags with attributes. The principle is that TAG('text',arg1=val1,arg2=val2) generates TAG arg1=val1 arg2=val2text/TAG For HTML attributes that don't have an explicit value (such as the SELECTED

Re: 0 in [True,False] returns True

2005-12-13 Thread bonono
Erik Max Francis wrote: [EMAIL PROTECTED] wrote: True too, and could be the reason(or similar too) why the OP wants to test the type rather than the logical value of it. The type is for the self-documentation purposes. The value is the same; so no, that's not a good reason either. I

Re: 0 in [True,False] returns True

2005-12-13 Thread quentel . pierre
Thanks for the link Carsten, the explanation is clear I didn't know where to search in the Python documentation, there isn't a section about keywords (always wondered why without daring to say - now it's done). So I typed ' in operator Python ' in Google, which gave : - on the first page a link

Re: How To Read Excel Files In Python?

2005-12-13 Thread Steve Holden
Anand wrote: Hello, Can I get some help on how to read the excel files using python? from win32com.client import Dispatch xlApp = Dispatch(Excel.Application) xlWb = xlApp.Workbooks.Open(Read.xls) xlSht = xlWb.WorkSheets(1) But sadly, I am unable to proceed further about how to read

RE: 0 in [True,False] returns True

2005-12-13 Thread Ron Griswold
I haven't read all of the responses to this thread, so perhaps this has already been suggested. But it occurs to me that if one needs to determine whether a variable is a bool or int it could be done like so: Booltype = False var = 0 Booltype == var True Booltype.__class__ == var.__class__

Re: 0 in [True,False] returns True

2005-12-13 Thread Fredrik Lundh
Duncan Booth wrote: Another reason to have a boolean type is of course to provide a cast: def isNameSet(self): return boolean(self.name) instead of: def isNameSet(self): if self.name: return True else: return False given that Python

Re: 0 in [True,False] returns True

2005-12-13 Thread Duncan Booth
wrote: For HTML attributes that don't have an explicit value (such as the SELECTED attribute in OPTION) the keyword argument to the function must have the value True A better way to do this (given that HTML defines exactly which attributes do not take a value) is to use the attribute name

Re: 0 in [True,False] returns True

2005-12-13 Thread bonono
Fredrik Lundh wrote: Duncan Booth wrote: Another reason to have a boolean type is of course to provide a cast: def isNameSet(self): return boolean(self.name) instead of: def isNameSet(self): if self.name: return True else:

Re: 0 in [True,False] returns True

2005-12-13 Thread Fredrik Lundh
Duncan Booth wrote: For HTML attributes that don't have an explicit value (such as the SELECTED attribute in OPTION) the keyword argument to the function must have the value True A better way to do this (given that HTML defines exactly which attributes do not take a value) is to use the

Re: 0 in [True,False] returns True

2005-12-13 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: I see you skip another use case of XMLRPC Duncan mentioned, is that a valid reason ? the PEP has the answer. also see my reply to Erik Max Francis: http://groups.google.com/group/comp.lang.python/msg/adb5e9389ea20b3c (the silly Boolean class in that post is taken

Re: OO in Python? ^^

2005-12-13 Thread Magnus Lycka
Welcome to Python Matthias. I hope you will enjoy it! Matthias Kaeppler wrote: Another thing which is really bugging me about this whole dynamically typing thing is that it seems very error prone to me: foo = some string! # ... if (something_fubar): fo = another string Oops,

Re: 0 in [True,False] returns True

2005-12-13 Thread Stefan Rank
on 13.12.2005 11:39 Fredrik Lundh said the following: Duncan Booth wrote: Another reason to have a boolean type is of course to provide a cast: def isNameSet(self): return boolean(self.name) [snip] given that Python already had a function for this, that wasn't much of a reason:

Datetime, pytz and strange offset

2005-12-13 Thread David Pratt
Hi. I am creating a couple of small methods to help me manage time from UTC as standard but I am getting strange results. If I start with a datetime of 2005-12-12 14:30:00 in timezone 'America/Halifax' and I want to turn this into a UTC representation. from datetime import datetime from

Re: 0 in [True,False] returns True

2005-12-13 Thread Fredrik Lundh
Duncan Booth wrote: A better way to do this (given that HTML defines exactly which attributes do not take a value) is to use the attribute name and simply generate the attribute only if the value is non-false. another approach (which may or may not be suitable in this case) is to use the

Re: I want a Python Puppy !

2005-12-13 Thread Diez B. Roggisch
Knoppix failed to access my USB ports and it comes with Python 2.3 and I am using already Python 2.4.2 . In the current c't there is an article how to customize knoppicilin, the knoppix-based antivirus distribution. I didn't have a deeper look so far, but I'm eager to see if that couldn't be

Re: 0 in [True,False] returns True

2005-12-13 Thread Antoon Pardon
Op 2005-12-13, Steve Holden schreef [EMAIL PROTECTED]: Antoon Pardon wrote: Op 2005-12-13, Steve Holden schreef [EMAIL PROTECTED]: Pierre Quentel wrote: Hi all, In some program I was testing if a variable was a boolean, with this test : if v in [True,False] My script didn't work in some

Re: IsString

2005-12-13 Thread Steven D'Aprano
On Mon, 12 Dec 2005 18:51:36 -0600, Larry Bates wrote: [snippidy-doo-dah] I had the same thought, but reread the post. He asks if a given variable is a character or a number. I figured that even if he is coming from another language he knows the difference between a given variable and the

Re: ANN: Dao Language v.0.9.6-beta is release!

2005-12-13 Thread Marc 'BlackJack' Rintsch
In [EMAIL PROTECTED], Zeljko Vrba wrote: Actually, after I learned Python, I value funny squiggles in other languages even more. It's very annoying, for example, that I can't split a long line in the following way: print a + b + c + d print other statement I guess I'm required to

Re: IsString

2005-12-13 Thread Gary Herron
Tuvas wrote: I need a function that will tell if a given variable is a character or a number. Is there a way to do this? Thanks! In Python, all values have an associated type which you can query with type(v) thus: from types import * if type(v) == IntType: ... whatever ...

Re: Python is incredible!

2005-12-13 Thread Cameron Laird
In article [EMAIL PROTECTED], Tom Anderson [EMAIL PROTECTED] wrote: On Mon, 12 Dec 2005, Cameron Laird wrote: While there is indeed much to love about Lisp, please be aware that meaningful AI work has already been done in Python Wait - meaningful AI work has been done?

Re: I want a Python Puppy !

2005-12-13 Thread Martin Christensen
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Diez == Diez B Roggisch [EMAIL PROTECTED] writes: Diez In the current c't there is an article how to customize Diez knoppicilin, the knoppix-based antivirus distribution. I didn't Diez have a deeper look so far, but I'm eager to see if that couldn't

Re: IsString

2005-12-13 Thread Duncan Booth
Gary Herron wrote: In Python, all values have an associated type which you can query with type(v) thus: from types import * if type(v) == IntType: ... whatever ... Several types would qualify as numbers: IntType, FloatType, LongType, and ComplexType, and several as

How do i read line from an input file, without the /n

2005-12-13 Thread doritrieur
How do i read line from an input file, without the /n ? the readline function returns also the /n character at the end. i need to read a line without the training /n is this possible? thanks, Dorit -- http://mail.python.org/mailman/listinfo/python-list

Re: How do i read line from an input file, without the /n

2005-12-13 Thread Aggelos Orfanakos
f.readline().rstrip('\n') should do it. If you are sure that lines always end in '\n', then you could even use f.readline()[:-1] -- http://mail.python.org/mailman/listinfo/python-list

Re: How do i read line from an input file, without the /n

2005-12-13 Thread Fredrik Lundh
doritrieur [EMAIL PROTECTED] wrote: How do i read line from an input file, without the /n ? the readline function returns also the /n character at the end. i need to read a line without the training /n so strip if off! line = line[:-1] # remove last char see also:

writing IM bots

2005-12-13 Thread Amit Khemka
Hello, I am trying to write an IM Bot, which automatically replies to a message, in Python. I was wondering If there are python modules for connecting to Yahoo!, msn networks ... ideally I would like to have a multithreaded module. This is one I found for msn, if anyone has used it please

Re: I want a Python Puppy !

2005-12-13 Thread Magnus Lycka
Claudio Grondi wrote: I have just discovered the existance of Puppy Linux which is a complete operating system with a suite of GUI apps, only about 50 - 60M booting directly off the CDROM ( http://www.puppylinux.org ). This approach appears to me very Pythonic, so it were a nice thing to

Re: sql using characters like é and ã

2005-12-13 Thread Magnus Lycka
Diez B. Roggisch wrote: Select * from table where name like '%s%%' % José.decode(latin-1).encode(utf-8) Ouch! Please use parameter passing instead of building full SQL statements with embedded parameter values. You're opening up for SQL injection attacks if you allow user provided input in SQL

Re: Pattern matching with string and list

2005-12-13 Thread BartlebyScrivener
Taking you literally, I'm not sure you need regex. If you know or can find position n, then can't you just: sentence = the color is $red patterns = [blue,red,yellow] pos = sentence.find($) for x in patterns: if x==sentence[pos+1:]: print x, pos+1 But maybe I'm oversimplifying. rpd

Re: Developing a network protocol with Python

2005-12-13 Thread Lawrence Oluyede
Il 2005-12-12, Laszlo Zsolt Nagy [EMAIL PROTECTED] ha scritto: Hello, I would like to develop a new network protocol, where the server and the clients are Python programs. You should use Twisted for this: Writing clients

Re: PythonWin troubleshooting

2005-12-13 Thread Colin J. Williams
chuck wrote: Build 205 for the win32 ext. I have been having similar problems with build 205. Colin W. -- http://mail.python.org/mailman/listinfo/python-list

Re: Question about start using ZServerSSL on win box...

2005-12-13 Thread Thomas G. Apostolou
After reading and searching for a while i found that all about running ZService as service start from C:\Program Files\Plone 2\Data\bin\zopeservice.py But still i cannot fully understand where the server is called so that i replace it with z2s.py or what ever needed... Any ideas? Thomas G.

Re: 0 in [True,False] returns True

2005-12-13 Thread Chris Mellon
On 13 Dec 2005 11:29:10 GMT, Antoon Pardon [EMAIL PROTECTED] wrote: Op 2005-12-13, Steve Holden schreef [EMAIL PROTECTED]: Antoon Pardon wrote: Op 2005-12-13, Steve Holden schreef [EMAIL PROTECTED]: Pierre Quentel wrote: Hi all, In some program I was testing if a variable was a

Re: PythonWin troubleshooting

2005-12-13 Thread chuck
Sticking with 2.4.2 I reverted to win32 ext 204 and problems were the same or worse. Then I uninstalled both, removed the dangling py*24.dll and then installed ActivePython 2.3.5.236. All the problems went away. I hate to go back to 2.3 cause there are some nice updates in the 2.4 library that

Re: 0 in [True,False] returns True

2005-12-13 Thread bonono
Chris Mellon wrote: Granted, of course, it's your code. But I wouldn't accept it in anything I was in charge of. That says it all. It is his code, whether you would accept it means nothing. If you can point out that it is functionally wrong, it may mean something. Otherise, it is nothing more

Re: newbie: generate a function based on an expression

2005-12-13 Thread Jacob Rael
Overall I am trying to learn OOP by porting CppSim (http://www-mtl.mit.edu/~perrott) to Python. In CppSim, classes are defined that allow various functions to be defined, like amplifiers. In some cases they are linear: y = A*x some have offsets: y = A*x + off some are non-linear y = A*x -

Re: newbie: generate a function based on an expression

2005-12-13 Thread Jacob Rael
Another example is a filter. From the CppSim doc: Filter filt(1+1/(2*pi*fz)s,C3*s + C3/(2*pi*fp)*s^2,C3,fz,fp,Ts,1/gain,fz,fp,Ts); jr -- http://mail.python.org/mailman/listinfo/python-list

Re: Developing a network protocol with Python

2005-12-13 Thread Lawrence Oluyede
Il 2005-12-13, Laszlo Zsolt Nagy [EMAIL PROTECTED] ha scritto: I need to send Python objects too. They are too elaborate to convert them to XML. (They are using cyclic weak references and other Python specific stuff.) I can be sure that on both sides, there are Python programs. Is there any

Re: OO in Python? ^^

2005-12-13 Thread bonono
Magnus Lycka wrote: The static typing means that you either have to make several implementations of many algorithms, or you need to work with those convoluted templates that were added to the language as an afterthought. I don't see this in Haskell. While feature-by-feature comparisions of

Re: 0 in [True,False] returns True

2005-12-13 Thread Antoon Pardon
Op 2005-12-13, Chris Mellon schreef [EMAIL PROTECTED]: However I must say the coupling in that interface has a very definite code smell. Why not use two variables, a Boolean registered and an integer ID that is meaningless when registered is False? Because the integer ID can be meaningless

Re: writing IM bots

2005-12-13 Thread Josef Meile
Hi, I am trying to write an IM Bot, which automatically replies to a message, in Python. I was wondering If there are python modules for connecting to Yahoo!, msn networks ... ideally I would like to have a multithreaded module. This is one I found for msn, if anyone has used it please

Re: 0 in [True,False] returns True

2005-12-13 Thread Grant Edwards
On 2005-12-13, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Fredrik Lundh wrote: [EMAIL PROTECTED] wrote: but seriously, unless you're writing an introspection tool, testing for bool is pretty silly. just use if v or if not v, and leave the rest to Python. The OP's code(and

Re: lambda (and reduce) are valuable

2005-12-13 Thread Christopher Subich
Chris Mellon wrote: functions with real names is crucial to maintainable code. The only reason to ever use a lamdba in Python is because you don't want to give a function a name, and that is just not a compelling use case for GUI events. Ah, but that neglects the sheer utility of

Re: sql using characters like é and ã

2005-12-13 Thread tjerk
I will try it with the José.decode(latin-1).encode(utf-8) Utf-8 is the same as Unicode? Herdsman again -- http://mail.python.org/mailman/listinfo/python-list

Re: 0 in [True,False] returns True

2005-12-13 Thread Grant Edwards
On 2005-12-13, Paul Rubin wrote: Steve Holden [EMAIL PROTECTED] writes: The really interesting question your post raises, though, is Why do you feel it's necessary to test to see whether a variable is a Boolean?. What's the point of having Booleans, if you can't tell them from integers?

Re: IsString

2005-12-13 Thread Tuvas
LOL. As to me being a newbie to programming, well, I've been programming to some extent for the last 10 years, although never professionally. The first few questions were enough to help me solve the problem that I had. And I've been programming Python for 4 months or so, but it's been pretty

Re: IsString

2005-12-13 Thread Tom Anderson
On Tue, 13 Dec 2005, Steven D'Aprano wrote: On Mon, 12 Dec 2005 18:51:36 -0600, Larry Bates wrote: [snippidy-doo-dah] I had the same thought, but reread the post. He asks if a given variable is a character or a number. I figured that even if he is coming from another language he knows

Re: 0 in [True,False] returns True

2005-12-13 Thread bonono
Grant Edwards wrote: He seems to be testing boolean type, not whether it is true or false. Right. But that's almost always pointless. Knowing whether a variable is a boolean or not is very rarely useful. What one wants to know is whether a varible is true or not. The code for that is:

Re: Python is incredible!

2005-12-13 Thread Tom Anderson
On Mon, 12 Dec 2005, Xavier Morel wrote: Luis M. Gonzalez wrote: You are not the first lisper who fell inlove with Python... Check this out: http://www.paulgraham.com/articles.html Paul Graham is not in love with Python though, he's still very much in love with Lisp. He merely admits

Re: sql using characters like é and ã

2005-12-13 Thread fumanchu
Diez B. Roggisch wrote: Select * from table where name like '%s%%' % José.decode(latin-1).encode(utf-8) Make it easy on yourself and encode the whole statement: conn.execute(query.encode('utf8')) Robert Brewer System Architect Amor Ministries [EMAIL PROTECTED] --

Re: Python Graph API

2005-12-13 Thread Steven Bethard
Nathan Gilbert wrote: Has there been any work done lately on the Python Graph API? Well there doesn't really seem to be a standard one. The wiki was last updated in August. http://wiki.python.org/moin/PythonGraphApi STeVe -- http://mail.python.org/mailman/listinfo/python-list

Re: Python is incredible!

2005-12-13 Thread Tom Anderson
On Tue, 13 Dec 2005, Cameron Laird wrote: In article [EMAIL PROTECTED], Tom Anderson [EMAIL PROTECTED] wrote: On Mon, 12 Dec 2005, Cameron Laird wrote: While there is indeed much to love about Lisp, please be aware that meaningful AI work has already been done in Python Wait - meaningful

Still Loving Python

2005-12-13 Thread Kamilche
I switched to Python a couple years ago, and haven't looked back. I've used Python for many applications, including several commercial plugins for Poser. I don't post on here much, because I don't need to; working in Python is so obvious and easy, it's rare that I get stumped by the limitations

Re: 0 in [True,False] returns True

2005-12-13 Thread Mike Meyer
Fredrik Lundh [EMAIL PROTECTED] writes: Duncan Booth wrote: For HTML attributes that don't have an explicit value (such as the SELECTED attribute in OPTION) the keyword argument to the function must have the value True A better way to do this (given that HTML defines exactly which

Re: I want a Python Puppy !

2005-12-13 Thread Claudio Grondi
Magnus Lycka wrote: Claudio Grondi wrote: I have just discovered the existance of Puppy Linux which is a complete operating system with a suite of GUI apps, only about 50 - 60M booting directly off the CDROM ( http://www.puppylinux.org ). This approach appears to me very Pythonic, so

Re: Still Loving Python

2005-12-13 Thread Lawrence Oluyede
Il 2005-12-13, Kamilche [EMAIL PROTECTED] ha scritto: Python still suffers from the lack of a good GUI, which I believe is slowing its acceptance by the programming community at large. (I know about tKinter, no need to post links to it, thanks.) Let me say I'm not agree, I'm developing a lot

Re: writing IM bots

2005-12-13 Thread David Wahler
Amit Khemka wrote: Hello, I am trying to write an IM Bot, which automatically replies to a message, in Python. I was wondering If there are python modules for connecting to Yahoo!, msn networks ... ideally I would like to have a multithreaded module. I have found that the best solution is

Re: Documentation suggestions

2005-12-13 Thread A.M. Kuchling
On 8 Dec 2005 08:00:25 -0800, BartlebyScrivener [EMAIL PROTECTED] wrote: The bulleted points in BeginnersGuide/Overview are, again, things that are important to programmers (Automatic garbage collection frees you from the hassles of memory management means nothing to me, even now

Re: PythonWin troubleshooting

2005-12-13 Thread Sibylle Koczian
chuck schrieb: Sticking with 2.4.2 I reverted to win32 ext 204 and problems were the same or worse. Then I uninstalled both, removed the dangling py*24.dll and then installed ActivePython 2.3.5.236. All the problems went away. I hate to go back to 2.3 cause there are some nice updates in

Re: 0 in [True,False] returns True

2005-12-13 Thread Fredrik Lundh
Mike Meyer wrote: (for example, in img ismap, ismap is the value, not the attribute name. it's up to the parser to figure out (from the DTD) that this value can only be used by the ismap attribute, and interpret it as img ismap=ismap) But this isn't necessarilly true: img alt=ismap is

PyQt on Mac OS X

2005-12-13 Thread Michael McGarry
Hi, I am using the default Python installation that comes with Mac OS X Tiger. I want to use the Qt module. How can I install the Qt module? Qt is already installed. Michael -- http://mail.python.org/mailman/listinfo/python-list

Re: debug 'continue' does not appear to work right

2005-12-13 Thread newsposter
Ok, thanks. I see what the problem is. I am working on an application which requires Python 2.1, but I also installed Python 2.4.2. It appears that my path for the command-lines is setup with 2.1 first. Thanks, Chris -- http://mail.python.org/mailman/listinfo/python-list

Re: Still Loving Python

2005-12-13 Thread Ivan Voras
Lawrence Oluyede wrote: Python *does* have GUI, you only have to decide which one you prefer. ps. the customer wants Windows as a platform, we develop on Linux using PyGTK, postgre and sql server for some old data. This is the true power of cross-platform :) Maybe the OP really wants a GUI

Re: PyQt on Mac OS X

2005-12-13 Thread Kevin Walzer
Michael McGarry wrote: Hi, I am using the default Python installation that comes with Mac OS X Tiger. I want to use the Qt module. How can I install the Qt module? Qt is already installed. Michael See http://sourceforge.net/projects/pyqt-mac --

Re: Still Loving Python

2005-12-13 Thread Lawrence Oluyede
Il 2005-12-13, Ivan Voras [EMAIL PROTECTED] ha scritto: More than 5 years ago, i programmed in Visual Basic and Delphi and I still miss the wonderful ease of graphically creating the user interface in WYSIWYG mode. If you haven't tried it, you don't know what you're missing :) I used

Re: PyQt on Mac OS X

2005-12-13 Thread Fredrik Lundh
Michael McGarry wrote: I am using the default Python installation that comes with Mac OS X Tiger. I want to use the Qt module. How can I install the Qt module? http://pdb.finkproject.org/pdb/search.php?summary=pyqt ? /F -- http://mail.python.org/mailman/listinfo/python-list

py2exe 0.6.3 and pyparallel 0.2

2005-12-13 Thread Hervé Broutin
I'm trying to create a .exe file under windows xp1. When i run the script file an error occurs.i use ctypes version 0.9.6 running py2exe*** searching for required modules ***error: compiling 'D:\appli\Python23\lib\site-packages\parallel\parallelioctl.py' faile Cordialement,

threading IOError

2005-12-13 Thread Gabriel Genellina
Hi I'm using Python 2.4.2 on Windows 98 SE. In a program with several threads, sometimes (I cant determine exactly when or why) one thread dies with the following traceback: 12/13/05 02:17:47 (WatchDog ) Unhandled thread exception Traceback (most recent call last): File

Horribly noobful string question

2005-12-13 Thread SeNTry
Hi Everyone, My first post here as I just begin to learn programming in general and python in particular. I have all the noobie confused questions, but as I work thru the tutorials I'm sure I'll find most my answers. This one is eluding me tho... I am working in the tutorials, writing scripts

how can i change the default python?

2005-12-13 Thread Koray Bostancı
Hi all, When i type python in terminal it runs the python2.3 interpreter, but i want to use 2.4 and Python2.4 package is already installed. How can i change the default python in my system? I searched google for a little but couldn't find. Using Debian GNU/Linux. koray --

Visual Python, really Visual?

2005-12-13 Thread Tolga
After a very rapid entrance into the Python, I have immediately looked for a good IDE. Komodo and Wing IDE look very good and I think they are enough. But now, I am searching for a Pyhton environment which should look like Delphi / Kylix, Borland's C++ builder or Allegro Common Lisp. I have found

Re: IsString

2005-12-13 Thread Steve Holden
Tom Anderson wrote: On Tue, 13 Dec 2005, Steven D'Aprano wrote: On Mon, 12 Dec 2005 18:51:36 -0600, Larry Bates wrote: [snippidy-doo-dah] I had the same thought, but reread the post. He asks if a given variable is a character or a number. I figured that even if he is coming from

Re: Horribly noobful string question

2005-12-13 Thread Fredrik Lundh
SeNTry wrote: My first post here as I just begin to learn programming in general and python in particular. I have all the noobie confused questions, but as I work thru the tutorials I'm sure I'll find most my answers. This one is eluding me tho... I am working in the tutorials, writing

Re: 0 in [True,False] returns True

2005-12-13 Thread Steve Holden
Antoon Pardon wrote: Op 2005-12-13, Chris Mellon schreef [EMAIL PROTECTED]: [...] If you have a consistent API and you're checking for error values from your GTK functions, then you already have a lot more code than using 2 varaibles will cost you. 10 lines, maybe. The fact that you think

Re: Visual Python, really Visual?

2005-12-13 Thread Ravi Teja
No! Visual Python does not have a WYSIWYG GUI Builder. Boa Constructor is the closest. PythonCard is another contender. Once, XAML comes in, this will become less of an issue. -- http://mail.python.org/mailman/listinfo/python-list

  1   2   3   >