[Python-Dev] Re: C API for the bool type?

2005-03-23 Thread Terry Reedy
"Bo Thorsen" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > If this is not the correct place to post this problem, I apologize. In > that case, please be gentle and point me to a better mailing list. The general Python mailing list (pyrhon-list ?) also at python.org. Or comp.lan

Re: [Python-Dev] docstring before function declaration

2005-03-23 Thread Anthony Baxter
On Tuesday 22 March 2005 05:58, Nicholas Jacobson wrote: > Oops, you're right. > > What I should have said is to use a blank docstring as > follows: It's still unclear to me what a file containing a single docstring followed by a def() line means. And this ambiguity doesn't seem to be solvable, so

Re: [Python-Dev] bdist_deb checkin comments

2005-03-23 Thread Sean Reifschneider
On Sat, Mar 19, 2005 at 06:20:44PM -0500, Kurt B. Kaiser wrote: >Sean Reifschneider <[EMAIL PROTECTED]> writes: >> Does anyone have any feedback on this before I do so? > >I made a few comments on the Tracker. Thanks a lot, they look great. I'll try to get the submitter to follow up on it. Sean

Re: [Python-Dev] docstring before function declaration

2005-03-23 Thread Nicholas Jacobson
Oops, you're right. What I should have said is to use a blank docstring as follows: "" """Function docstring.""" def foo: ... or: """Module docstring.""" "" def foo: ... --- Anthony Baxter <[EMAIL PROTECTED]> wrote: > On Monday 21 March 2005 20:08, Nicholas Jacobson > wrote: >

[Python-Dev] C API for the bool type?

2005-03-23 Thread Bo Thorsen
Hi people, If this is not the correct place to post this problem, I apologize. In that case, please be gentle and point me to a better mailing list. I'm coding a text editor in Qt that uses Python for macros. The problem I have is that want to use the bool type introduced in 2.3, but I can't se

Re: [Python-Dev] Re: Re: Ye don't be needin' these!

2005-03-23 Thread Josiah Carlson
Tim Lesher <[EMAIL PROTECTED]> wrote: > > On Wed, 23 Mar 2005 22:58:51 +0100, Florian Schulze > <[EMAIL PROTECTED]> wrote: > > BTW, Herman Toothrot is from Monkey Island. > > Right. That's what leads me to believe 1) it's not a serious post, > and 2) it's from someone who's old enough to know b

python-dev@python.org

2005-03-23 Thread Greg Ward
On 23 March 2005, Oleg Broytmann said: >I'd like to remove all those redirects. Any opinion? +0.5. The beauty of Python is that it generally provides thin wrappers: when writing a convenient wrapper, it's OK to expose the underlying beast, warts and all. (I had a minor epiphany about this re

python-dev@python.org

2005-03-23 Thread Fred L. Drake, Jr.
On Wednesday 23 March 2005 08:25, Rodrigo Dias Arruda Senra wrote: > Under some linux distros (I'm positive for some Mdk releases), Mozilla is > compiled dumping a lot of info to stdout/stderr. Since one of the goals of > webbrowser is to give the end-user a stress-free experience, there goes >

python-dev@python.org

2005-03-23 Thread Fred L. Drake, Jr.
On Wednesday 23 March 2005 07:40, Oleg Broytmann wrote: >While I'm working on webbrowser... Why do all graphical browsers are > called with their stdout/stderr redirected to /dev/null? Do we really > need to hide problems from the user? Browsers are usually silent beasts > - they interact w

Re: [Python-Dev] Re: Re: Ye don't be needin' these!

2005-03-23 Thread Tim Lesher
On Wed, 23 Mar 2005 22:58:51 +0100, Florian Schulze <[EMAIL PROTECTED]> wrote: > BTW, Herman Toothrot is from Monkey Island. Right. That's what leads me to believe 1) it's not a serious post, and 2) it's from someone who's old enough to know better. -- Tim Lesher <[EMAIL PROTECTED]>

[Python-Dev] Re: Re: Ye don't be needin' these!

2005-03-23 Thread Florian Schulze
On Wed, 23 Mar 2005 13:59:29 -0500, Tim Lesher <[EMAIL PROTECTED]> wrote: On Wed, 23 Mar 2005 11:34:09 -0500, Terry Reedy <[EMAIL PROTECTED]> wrote: "Herman Toothrot" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Avast! Why be there builtins divmod and pow, when operators **, /, a

Re: [Python-Dev] Shorthand for lambda

2005-03-23 Thread Josiah Carlson
Ka-Ping Yee <[EMAIL PROTECTED]> wrote: > > On Wed, 23 Mar 2005, Josiah Carlson wrote: > > Paul Moore <[EMAIL PROTECTED]> wrote: > > > I thought about it, but couldn't convince myself that it would work > > > properly in all cases. I was thinking in terms of operator overloading > > > of everythin

python-dev@python.org

2005-03-23 Thread Delaney, Timothy C (Timothy)
Rodrigo Dias Arruda Senra wrote: > However, there are two other issues: > 1) If a *graphical* application dumps messages to the console, >that might be disruptive to other console applications. >IMVHO, a log file should be used instead. (strong argument) Perhaps instead webbrowser.py sho

Re: [Python-Dev] Re: webbrowser.py

2005-03-23 Thread Rodrigo Dias Arruda Senra
On Wed, 23 Mar 2005 21:29:30 +0300 Oleg Broytmann <[EMAIL PROTECTED]> wrote: > Suggested resolutions: > http://python.org/sf/754022 >Review and apply! ;) Reviewed. Thank you Oleg, fine integration job. I added a +1 comment to the tracker and copied your remaining obs to 754022 history. So a

[Python-Dev] Re: Shorthand for lambda

2005-03-23 Thread Reinhold Birkenfeld
Ka-Ping Yee wrote: > On Wed, 23 Mar 2005, Reinhold Birkenfeld wrote: >> What does you implementation do for this: >> >> >>> somevar = False >> >>> filter(_ and False, numbers) > > It fails. (For the same reason that __len__ doesn't work -- > Python insists that __nonzero__ must return an int.) T

Re: [Python-Dev] Re: Ye don't be needin' these!

2005-03-23 Thread Tim Lesher
On Wed, 23 Mar 2005 11:34:09 -0500, Terry Reedy <[EMAIL PROTECTED]> wrote: > > "Herman Toothrot" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > > Avast! Why be there builtins divmod and pow, when operators **, /, and % > > should be good enough for ya? It runs counter to TOOWTDI

Re: [Python-Dev] Re: Shorthand for lambda

2005-03-23 Thread Bob Ippolito
On Mar 23, 2005, at 1:16 PM, Ka-Ping Yee wrote: On Wed, 23 Mar 2005, Reinhold Birkenfeld wrote: What does you implementation do for this: somevar = False filter(_ and False, numbers) It fails. (For the same reason that __len__ doesn't work -- Python insists that __nonzero__ must return an int.) T

Re: [Python-Dev] Re: webbrowser.py

2005-03-23 Thread Oleg Broytmann
On Tue, Mar 22, 2005 at 01:28:42PM +0300, Oleg Broytmann wrote: > On Sun, Mar 20, 2005 at 11:40:27AM -0300, [EMAIL PROTECTED] wrote: > > Perhaps you could focus in 728278. It addresses some of the issues you > > have addressed in 754022, but it is not properly formatted. If you could > > merge into

Re: [Python-Dev] Re: Shorthand for lambda

2005-03-23 Thread Ka-Ping Yee
On Wed, 23 Mar 2005, Reinhold Birkenfeld wrote: > What does you implementation do for this: > > >>> somevar = False > >>> filter(_ and False, numbers) It fails. (For the same reason that __len__ doesn't work -- Python insists that __nonzero__ must return an int.) Though i must say i have no idea

[Python-Dev] Re: Shorthand for lambda

2005-03-23 Thread Reinhold Birkenfeld
Ka-Ping Yee wrote: > It dawned on me that you could use this idea to make the whole > filter/lambda experience vastly more pleasant. I whipped up a quick > implementation: > > >>> from placeholder import _ > >>> numbers = [5, 9, 56, 34, 1, 24, 37, 89] > >>> filter(_ < 30, numbers) >

Re: [Python-Dev] Shorthand for lambda

2005-03-23 Thread Ka-Ping Yee
On Wed, 23 Mar 2005, Josiah Carlson wrote: > Paul Moore <[EMAIL PROTECTED]> wrote: > > I thought about it, but couldn't convince myself that it would work > > properly in all cases. I was thinking in terms of operator overloading > > of everything possible - how did you do it? > > PyTables allows s

Re: [Python-Dev] Shorthand for lambda

2005-03-23 Thread Josiah Carlson
Paul Moore <[EMAIL PROTECTED]> wrote: > > On Wed, 23 Mar 2005 10:33:53 -0600 (CST), Ka-Ping Yee > <[EMAIL PROTECTED]> wrote: > > It dawned on me that you could use this idea to make the whole > > filter/lambda experience vastly more pleasant. I whipped up a quick > > implementation: > > > >

[Python-Dev] Re: Ye don't be needin' these!

2005-03-23 Thread Terry Reedy
"Herman Toothrot" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Avast! Why be there builtins divmod and pow, when operators **, /, and % > should be good enough for ya? It runs counter to TOOWTDI, I be thinking. Questions like this should be asked on comp.lang.python or the py

Re: [Python-Dev] Shorthand for lambda

2005-03-23 Thread Paul Moore
On Wed, 23 Mar 2005 10:33:53 -0600 (CST), Ka-Ping Yee <[EMAIL PROTECTED]> wrote: > It dawned on me that you could use this idea to make the whole > filter/lambda experience vastly more pleasant. I whipped up a quick > implementation: > > >>> from placeholder import _ > >>> numbers = [5, 9

Re: [Python-Dev] Shorthand for lambda

2005-03-23 Thread Jeremy Hylton
For filter and map, list comprehensions and generator expressions are the answer. >>> numbers = [5, 9, 56, 34, 1, 24, 37, 89] >>> [x for x in numbers if x < 30] [5, 9, 1, 24] >>> (x for x in numbers if x < 30) >>> list(_) [5, 9, 1, 24] Jeremy On Wed, 23 Mar 2005 10:33:53 -0600 (CST), Ka-Ping Ye

[Python-Dev] Shorthand for lambda

2005-03-23 Thread Ka-Ping Yee
Hey folks, I'm sitting over here in the AppleScript talk and Jacob is explaining a module called 'appscript' that interfaces to the Apple Events system. What caught my eye was this example: from appscript import * ab = app('Address Book') people = ab.people.filter(its.emails != [])

[Python-Dev] Re: Ye don't be needin' these!

2005-03-23 Thread Robert Kern
Herman Toothrot wrote: Avast! Why be there builtins divmod and pow, when operators **, /, and % should be good enough for ya? It runs counter to TOOWTDI, I be thinking. Arr. Well, divmod(x, y) does both / and % in one shot, which can be very useful. pow(x, y[, z]) has an optional third argume

Re: [Python-Dev] Ye don't be needin' these!

2005-03-23 Thread Aahz
On Wed, Mar 23, 2005, Herman Toothrot wrote: > > Avast! Why be there builtins divmod and pow, when operators **, /, and % > should be good enough for ya? It runs counter to TOOWTDI, I be thinking. > Arr. This is off-topic for python-dev. Please post to comp.lang.python instead. -- Aahz ([EM

python-dev@python.org

2005-03-23 Thread Oleg Broytmann
Oops... > PS. This, of course, should must be fixed - pydoc must use webbrowser.py! ^^ delete (-: Oleg. -- Oleg Broytmannhttp://phd.pp.ru/[EMAIL PROTECTED] Programmers don't die, they just GOSUB without RETURN. __

python-dev@python.org

2005-03-23 Thread Oleg Broytmann
On Wed, Mar 23, 2005 at 11:59:24AM -0300, Rodrigo Dias Arruda Senra wrote: > Has this same issue been dealt in another stdlib module ? pydoc.py: rc = os.system('netscape -remote "openURL(%s)" &' % url) if rc: os.system('netscape "%s" &' % url) PS. This, of course, should must be fixed - pyd

[Python-Dev] Ye don't be needin' these!

2005-03-23 Thread Herman Toothrot
Avast! Why be there builtins divmod and pow, when operators **, /, and % should be good enough for ya? It runs counter to TOOWTDI, I be thinking. Arr. H. Toothrot _ Express yourself instantly with MSN Messenger! Download today -

python-dev@python.org

2005-03-23 Thread Rodrigo Dias Arruda Senra
[Rod Senra]: > > Under some linux distros (I'm positive for some Mdk releases), Mozilla is > > compiled dumping a lot of info to stdout/stderr. Since one of the goals of > > webbrowser is to give the end-user a stress-free experience, there goes the > > mentioned nullification . [Oleg Broytmann]:

python-dev@python.org

2005-03-23 Thread Oleg Broytmann
On Wed, Mar 23, 2005 at 10:25:12AM -0300, Rodrigo Dias Arruda Senra wrote: > > Why do all graphical browsers are called with their stdout/stderr > > redirected > > to /dev/null? > > Under some linux distros (I'm positive for some Mdk releases), Mozilla is > compiled dumping a lot of info to std

python-dev@python.org

2005-03-23 Thread Rodrigo Dias Arruda Senra
On Wed, 23 Mar 2005 15:40:20 +0300 Oleg Broytmann <[EMAIL PROTECTED]> wrote: > Hello! > >While I'm working on webbrowser... Great. > Why do all graphical browsers are called with their stdout/stderr redirected > to /dev/null? Under some linux distros (I'm positive for some Mdk releases),

python-dev@python.org

2005-03-23 Thread Oleg Broytmann
Hello! While I'm working on webbrowser... Why do all graphical browsers are called with their stdout/stderr redirected to /dev/null? Do we really need to hide problems from the user? Browsers are usually silent beasts - they interact with the user using windows, not stdio. (Text-mode browser

Re: [Python-Dev] bug in pythondotnet implementation. Maybe related to a bug in cpython implementation...help!!!!

2005-03-23 Thread Paul Moore
On Wed, 23 Mar 2005 12:13:56 +0100, Stan Pinte <[EMAIL PROTECTED]> wrote: > I would welcome any help regarding: > > -how can I get/give more info on what's happening? > -how to solve that stuff? > > thanks a lot in advance. > > here is the problem: > > I have a python (actually pythondotnet) pr

[Python-Dev] bug in pythondotnet implementation. Maybe related to a bug in cpython implementation...help!!!!

2005-03-23 Thread Stan Pinte
hello, I would welcome any help regarding: -how can I get/give more info on what's happening? -how to solve that stuff? thanks a lot in advance. here is the problem: I have a python (actually pythondotnet) process freezing on windows, like that: Thread Start Address: >Symbol Name:

Re: [Python-Dev] New PyPI broken package editing

2005-03-23 Thread Walter Dörwald
[EMAIL PROTECTED] wrote: Zitat von Walter Dörwald <[EMAIL PROTECTED]>: I've uploaded a new package to the new PyPI. Editing this new packages gives me a unicode error. The URL is http://www.python.org/pypi?:action=submit_form&name=ll-ansistyle&version=0.6.1 I see that the package is online now, so