Re: updating NumPy in EPD

2010-06-08 Thread Nick Matzke
Oh yes -- I would just update my version of EPD, which is where my NumPy came from -- however, Enthought only has available for academic download a version of EPD that works on OS X 10.5 or later, and my Mac is a 10.4.11 and I'd rather not completely reinstall the OS just to get one little lib

Re: GUIs - A Modest Proposal

2010-06-08 Thread Kevin Walzer
On 6/8/10 7:58 PM, rantingrick wrote: The same people who would fight to the death to protect Tkinter's existence in the stdlib never use the library anyway and personally hate it! I want to keep it in the stdlib because I use it for all my apps, and personally prefer it to any other GUI toolk

Re: GUIs - A Modest Proposal

2010-06-08 Thread Mark Lawrence
On 09/06/2010 00:58, rantingrick wrote: On Jun 8, 5:40 pm, geremy condra wrote: On Tue, Jun 8, 2010 at 3:09 PM, Lie Ryan wrote: On 06/09/10 01:17, bart.c wrote: "Grant Edwards" wrote in message news:[email protected]... On 2010-06-08, Kevin Walzer wrote: Since Tk already

Re: why any( ) instead of firsttrue( ) ?

2010-06-08 Thread Tim Chase
On 06/08/2010 06:18 PM, MRAB wrote: danieldelay wrote: firsttrue(line.strip() for line in '\n\n \n CHEERS \n'.split('\n')) Should 'firsttrue' return None? Surely, if none are true then it should raise an exception. which can fairly elegantly be written with stock-Python as # try: resu

Re: GUIs - A Modest Proposal

2010-06-08 Thread geremy condra
On Tue, Jun 8, 2010 at 4:46 PM, Steven D'Aprano wrote: > On Tue, 08 Jun 2010 15:40:51 -0700, geremy condra wrote: > >> On Tue, Jun 8, 2010 at 3:09 PM, Lie Ryan wrote: > >>> Nobody complains that python included a regular expression engine in >>> its standard distribution; so why complain that pyt

Re: GUIs - A Modest Proposal

2010-06-08 Thread rantingrick
On Jun 8, 5:38 am, Steven D'Aprano wrote: > Hmmm... there's something terribly familiar about this style of speech... > rantingrick, did you used to post under the name "r" using an gmail > account starting with "rt8"? Steven, i've always thought of you as one of the more intelligent readers of

Re: GUIs - A Modest Proposal

2010-06-08 Thread Adam Tauno Williams
On Tue, 2010-06-08 at 18:12 -0700, geremy condra wrote: > > * IronPython relies on the .Net environment for everything > Since .Net (effectively) depends on Windows, 100% False; not "effectively" true at all. I run [and develop] .NET applications on LINUX every day. IL and the CLR are standards

Re: GUIs - A Modest Proposal

2010-06-08 Thread Adam Tauno Williams
On Tue, 2010-06-08 at 16:58 -0700, rantingrick wrote: > We have a problem No, we don't. Or at least, I don't. > """I don't use Tkinter so i don't care! +1 > ... well just keep your negativity to yourself. When you have real > solutions or real ideas that could foster real solutions then

Re: GUIs - A Modest Proposal

2010-06-08 Thread Ben Finney
rantingrick writes: > On Jun 8, 5:38 am, Steven D'Aprano cybersource.com.au> wrote: > > > Hmmm... there's something terribly familiar about this style of > > speech... rantingrick, did you used to post under the name "r" using > > an gmail account starting with "rt8"? > > Steven, i've always tho

Re: GUIs - A Modest Proposal

2010-06-08 Thread rantingrick
On Jun 8, 7:15 pm, Kevin Walzer wrote: > On 6/8/10 7:58 PM, rantingrick wrote: > > > The same people who would fight > > to the death to protect Tkinter's existence in the stdlib never use > > the library anyway and personally hate it! > > I want to keep it in the stdlib because I use it for all m

Re: GUIs - A Modest Proposal

2010-06-08 Thread geremy condra
On Tue, Jun 8, 2010 at 6:20 PM, Adam Tauno Williams wrote: > On Tue, 2010-06-08 at 18:12 -0700, geremy condra wrote: >> > * IronPython relies on the .Net environment for everything >> Since .Net (effectively) depends on Windows, > > 100% False;  not "effectively" true at all.  I run [and develop]

Re: Syntax problem - cannot solve it by myself

2010-06-08 Thread alex23
Deadly Dirk wrote: > The book covers Python3 but my understanding was that it should also > cover Python 2.5 and 2.6. The "SECOND EDITION Covers Python 3" banner across the top of the cover would seem to indicate otherwise. The first line of the About section confirms it: "This book is intended

Re: Non Sequitur: Re: Python Forum

2010-06-08 Thread Jack Diederich
On Tue, Jun 8, 2010 at 6:47 PM, Mark Young wrote: > According to the Oxford Dictionary: > > fish noun, verb noun (pl.fish or fishes)Fish is the usual plural form. The > older form, fishes, can be used to refer to different kinds of fish... > > However, I would correct anyone that ever used "fishes

Re: capitalize() NOT the same as var[0].upper _ var[1:]

2010-06-08 Thread alex23
James Mills wrote: > The behavior you've demonstrated is "exactly" what the documentation > says the .capitalize() method does. Look on the plus side, at least it's not yet another question on SQL parameters & Python string substitutions. I'm amazed at the endless willingness of this group to he

Re: introducing Lettuce, BDD tool for python with Django integration

2010-06-08 Thread alex23
On Jun 9, 3:29 am, Terry Reedy wrote: > On 6/8/2010 2:26 AM, Gabriel Falcão wrote: > > There is not much to say, > except to explain 'BDD'. If only there was some kind of way to quickly look up the meaning of definitions, preferably one known to people of the programming persuasion... -- http:/

Re: GUIs - A Modest Proposal

2010-06-08 Thread rantingrick
On Jun 8, 8:35 pm, Ben Finney wrote: > Yes, thank you, Steven, for identifying this irritant. I'll add > identity-hopping to the list of offenses, and add this new identity to > my kill-file. So you put up with my antics fine up until you learned of my past identity. So now i am somehow so annoy

Re: Non Sequitur: Re: Python Forum

2010-06-08 Thread rantingrick
On Jun 8, 9:00 pm, Jack Diederich wrote: > On Tue, Jun 8, 2010 at 6:47 PM, Mark Young wrote: > > According to the Oxford Dictionary: > > > fish noun, verb noun (pl.fish or fishes)Fish is the usual plural form. The > > older form, fishes, can be used to refer to different kinds of fish... > > > Ho

Re: Syntax problem - cannot solve it by myself

2010-06-08 Thread Deadly Dirk
On Tue, 08 Jun 2010 18:52:44 -0700, alex23 wrote: > Unless you have a clear need for 3rd party libraries that currently > don't have 3.x versions, starting with Python 3 isn't a bad idea. >From what I see, most of the people are still using Python 2.x. My reason for learning Python is the fact

Re: why any( ) instead of firsttrue( ) ?

2010-06-08 Thread Carl Banks
On Jun 8, 4:08 pm, danieldelay wrote: > Le 09/06/2010 00:24, Ian Kelly a crit : > > > Because it was designed as a replacement for "reduce(lambda x, y: x or > > y, iterable)".  The problem arises when the iterable is empty.  What > > false value should be returned?  If the iterable is a sequence o

Re: GUIs - A Modest Proposal

2010-06-08 Thread Robert Kern
On 6/8/10 10:20 PM, rantingrick wrote: On Jun 8, 8:35 pm, Ben Finney wrote: Yes, thank you, Steven, for identifying this irritant. I'll add identity-hopping to the list of offenses, and add this new identity to my kill-file. So you put up with my antics fine up until you learned of my past i

Re: updating NumPy in EPD

2010-06-08 Thread Robert Kern
On 6/8/10 8:05 PM, Nick Matzke wrote: Hi all, I have a slightly weird question. I would like to install the PyCogent library. However, this requires NumPy 1.3 or higher. I only have NumPy 1.1.1, because I got it as part of the Enthought Python Distribution (4.1) back in 2008. Now, when I downlo

Re: updating NumPy in EPD

2010-06-08 Thread Nick Matzke
Hi again, I got the solution on the NumPy list, I thought I would share for posterity... Jeff Hsu wrote: > Check which version of numpy python is importing with "import numpy; > printnumpy.__file__". I had a similar question and this worked after I > removed that installation of numpy. I

Re: introducing Lettuce, BDD tool for python with Django integration

2010-06-08 Thread Tycho Andersen
On Tue, Jun 8, 2010 at 9:18 PM, alex23 wrote: > On Jun 9, 3:29 am, Terry Reedy wrote: >> On 6/8/2010 2:26 AM, Gabriel Falcão wrote: >> > There is not much to say, >> except to explain 'BDD'. > > If only there was some kind of way to quickly look up the meaning of > definitions, preferably one kno

Re: Syntax problem - cannot solve it by myself

2010-06-08 Thread alex23
Deadly Dirk wrote: > From what I see, most of the people are still using Python 2.x. My reason > for learning Python is the fact that my CTO decided that the new company > standard for scripting languages will be Python. I've been using Perl for > 15 years and it was completely adequate but, appar

Re: introducing Lettuce, BDD tool for python with Django integration

2010-06-08 Thread alex23
Tycho Andersen wrote: > I think his point may have been that there could be more than one > meaning. My first guess would have been binary decision diagram. Ah, good point. My apologies for the dig, Terry :) -- http://mail.python.org/mailman/listinfo/python-list

Re: GUIs - A Modest Proposal

2010-06-08 Thread Steven D'Aprano
On Tue, 08 Jun 2010 18:12:05 -0700, geremy condra wrote: > I didn't argue that Tcl is bad. I argued that a dependency on it is bad > for python. Would you argue that Python should ship with Perl and Java > because there are best-of-breed tools in those languages and python > could leverage that? O

Re: GUIs - A Modest Proposal

2010-06-08 Thread geremy condra
On Tue, Jun 8, 2010 at 9:29 PM, Steven D'Aprano wrote: > On Tue, 08 Jun 2010 18:12:05 -0700, geremy condra wrote: > >> I didn't argue that Tcl is bad. I argued that a dependency on it is bad >> for python. Would you argue that Python should ship with Perl and Java >> because there are best-of-bree

Re: GUIs - A Modest Proposal

2010-06-08 Thread rantingrick
On Jun 8, 10:09 pm, Robert Kern wrote: > It means that he, very charitably, gives new irritants the benefit of the > doubt. > By changing identities, you are abusing this good behavior. By connecting your > identity to the previous one, his doubt is removed. And again you miss the very meat and

how to get a reference to the "__main__" module

2010-06-08 Thread WH
Hi, I want to use one of two functions in a script: def func_one(): pass def func_two(): pass func = getattr(x, 'func_'+number) func() 'x' in getattr() should be a reference to the "__main__" module, right? How to get it? The 'if' clause should work here. I am just curious if we can use the

Re: how to get a reference to the "__main__" module

2010-06-08 Thread Chris Rebert
On Tue, Jun 8, 2010 at 10:29 PM, WH wrote: > Hi, > > I want to use one of two functions in a script: > > def func_one(): pass > def func_two(): pass > > func = getattr(x, 'func_'+number) > func() > > 'x' in getattr() should be a reference to the "__main__" module, right? >  How to get it? from sy

Re: how to get a reference to the "__main__" module

2010-06-08 Thread Steven D'Aprano
On Tue, 08 Jun 2010 22:29:04 -0700, WH wrote: > Hi, > > I want to use one of two functions in a script: > > def func_one(): pass > def func_two(): pass > > func = getattr(x, 'func_'+number) > func() > > 'x' in getattr() should be a reference to the "__main__" module, right? > How to get it?

Re: Non Sequitur: Re: Python Forum

2010-06-08 Thread MRAB
Mark Young wrote: According to the Oxford Dictionary: *fish** noun **, **verb *noun *(**pl.**fish** or **fishes**)*Fish is the usual plural form. The older form, fishes, can be used to refer to different kinds of

Re: Syntax problem - cannot solve it by myself

2010-06-08 Thread MRAB
Deadly Dirk wrote: On Tue, 08 Jun 2010 18:52:44 -0700, alex23 wrote: Unless you have a clear need for 3rd party libraries that currently don't have 3.x versions, starting with Python 3 isn't a bad idea. From what I see, most of the people are still using Python 2.x. My reason for learning P

Re: Syntax problem - cannot solve it by myself

2010-06-08 Thread Steven D'Aprano
On Wed, 09 Jun 2010 02:45:36 +, Deadly Dirk wrote: > On Tue, 08 Jun 2010 18:52:44 -0700, alex23 wrote: > > >> Unless you have a clear need for 3rd party libraries that currently >> don't have 3.x versions, starting with Python 3 isn't a bad idea. > > From what I see, most of the people are

Re: GUIs - A Modest Proposal

2010-06-08 Thread Steven D'Aprano
On Tue, 08 Jun 2010 16:58:26 -0700, rantingrick wrote: > We have a problem You keep saying that, but you've given no good reasons for why we should believe you, or what the nature of this problem supposedly is. The current situation has broad community support: there's a relatively lightweigh

Re: GUIs - A Modest Proposal

2010-06-08 Thread Robert Kern
On 6/9/10 1:12 AM, rantingrick wrote: On Jun 8, 10:09 pm, Robert Kern wrote: It means that he, very charitably, gives new irritants the benefit of the doubt. By changing identities, you are abusing this good behavior. By connecting your identity to the previous one, his doubt is removed. And

Re: GUIs - A Modest Proposal

2010-06-08 Thread geremy condra
On Wed, Jun 9, 2010 at 2:12 AM, Robert Kern wrote: > On 6/9/10 1:12 AM, rantingrick wrote: >> But you know i think it boils down to fear really. He is comfortable >> in his life and wishes to keep it as cookie cutter as he can. Any >> outside influence must be quashed before these meddling forc

Re: GUIs - A Modest Proposal

2010-06-08 Thread Gregory Ewing
Kevin Walzer wrote: PyGUI ... certainly is *not* a lightweight GUI toolkit that could easily be incorporated into the Python core library--it instead has rather complex dependencies on both other GUI toolkits and Python wrappers of those toolkits. I don't see how the dependencies could be reg

Re: why any( ) instead of firsttrue( ) ?

2010-06-08 Thread Raymond Hettinger
On Jun 8, 2:16 pm, danieldelay wrote: >    def firsttrue(iterable): >      for element in iterable: >          if element: >              return element >      return None > > This function "firsttrue( )" could probably be used anywhere "any( )" is > used, but with the ability to retrieve the firs

<    1   2