[Python-Dev] Re: license issues with profiler.py and md5.h/md5c.c

2005-02-17 Thread Fredrik Lundh
Gregory P. Smith wrote: I don't quite like the module name 'hashes' that i chose for the generic interface (too close to the builtin hash() function). Other suggestions on a module name? 'digest' comes to mind. hashtools, hashlib, and _hash are common names for helper modules like this.

Re: [Python-Dev] 2.4 func.__name__ breakage

2005-02-17 Thread Michael Hudson
Tim Peters [EMAIL PROTECTED] writes: Rev 2.66 of funcobject.c made func.__name__ writable for the first time. That's great, but the patch also introduced what I'm pretty sure was an unintended incompatibility: after 2.66, func.__name__ was no longer *readable* in restricted execution mode.

Re: [Python-Dev] [ python-Bugs-1124637 ] test_subprocess is far too slow (fwd)

2005-02-17 Thread Nick Coghlan
Peter Astrand wrote: I'd like to have your opinion on this bug. Personally, I'd prefer to keep test_no_leaking as it is, but if you think otherwise... One thing that actually can motivate that test_subprocess takes 20% of the overall time is that this test is a good generic Python stress test -

[Python-Dev] Re: [ python-Bugs-1124637 ] test_subprocess is far tooslow (fwd)

2005-02-17 Thread Fredrik Lundh
Nick Coghlan wrote: One thing that actually can motivate that test_subprocess takes 20% of the overall time is that this test is a good generic Python stress test - this test might catch some other startup race condition, for example. test_decimal has a short version which tests basic

Re: [Python-Dev] Re: [ python-Bugs-1124637 ] test_subprocess is far tooslow (fwd)

2005-02-17 Thread Michael Hudson
Fredrik Lundh [EMAIL PROTECTED] writes: Nick Coghlan wrote: One thing that actually can motivate that test_subprocess takes 20% of the overall time is that this test is a good generic Python stress test - this test might catch some other startup race condition, for example. test_decimal

Re: [Python-Dev] 2.4 func.__name__ breakage

2005-02-17 Thread Tim Peters
[Michael Hudson] ... Well, I fixed it on reading the bug report and before getting to python-dev mail :) Sorry if this duplicated your work, but hey, it was only a two line change... Na, the real work was tracking it down in the bowels of Zope's C-coded security machinery -- we'll let you do

Re: [Python-Dev] 2.4 func.__name__ breakage

2005-02-17 Thread Michael Hudson
Tim Peters [EMAIL PROTECTED] writes: [Michael Hudson] ... Well, I fixed it on reading the bug report and before getting to python-dev mail :) Sorry if this duplicated your work, but hey, it was only a two line change... Na, the real work was tracking it down in the bowels of Zope's C-coded

Re: [Python-Dev] Re: [ python-Bugs-1124637 ] test_subprocess is far tooslow (fwd)

2005-02-17 Thread Tim Peters
[Fredrik Lundh] does anyone ever use the -u options when running tests? Yes -- I routinely do -uall, under both release and debug builds, but only on Windows. WinXP in particular seems to do a good job when hyper-threading is available -- running the tests doesn't slow down anything else I'm

Re: [Python-Dev] 2.4 func.__name__ breakage

2005-02-17 Thread Tim Peters
[sorry for the near-duplicate msgs -- looks like gmail lied when it claimed the first msg was still in draft status] Did you add a test to ensure this remains fixed? [mwh] Yup. Bless you. Did you attach a contributor agreement and mark the test as being contributed under said contributor

Re: [Python-Dev] 2.4 func.__name__ breakage

2005-02-17 Thread Michael Hudson
Tim Peters [EMAIL PROTECTED] writes: [sorry for the near-duplicate msgs -- looks like gmail lied when it claimed the first msg was still in draft status] Did you add a test to ensure this remains fixed? [mwh] Yup. Bless you. Did you attach a contributor agreement and mark the test

Re: [Python-Dev] [ python-Bugs-1124637 ] test_subprocess is far too slow (fwd)

2005-02-17 Thread Guido van Rossum
I'd like to have your opinion on this bug. Personally, I'd prefer to keep test_no_leaking as it is, but if you think otherwise... One thing that actually can motivate that test_subprocess takes 20% of the overall time is that this test is a good generic Python stress test - this test might

RE: [Python-Dev] [ python-Bugs-1124637 ] test_subprocess is far tooslow (fwd)

2005-02-17 Thread Raymond Hettinger
Let's keep the really long-running tests out of the regular test suite. For test_subprocess, consider adopting the technique used by test_decimal. When -u decimal is not specified, a small random selection of the resource intensive tests are run. That way, all of the tests eventually get run

[Python-Dev] Five review rule on the /dev/ page?

2005-02-17 Thread Skip Montanaro
I am frantically trying to get ready to be out of town for a week of vacation. Someone sent me some patches for datetime and asked me to look at them. I begged off but referred him to http://www.python.org/dev/ and made mention of the five patch review idea. Can someone make sure that's

Re: [Python-Dev] [ python-Bugs-1124637 ] test_subprocess is far too slow (fwd)

2005-02-17 Thread Walter Dörwald
Guido van Rossum wrote: [...] There used to be a farm of machines that did nothing but run the test suite (snake-farm). This seems to have stopped (it was run by volunteers at a Swedish university). Maybe we should revive such an effort, and make sure it runs with -u all. I've changed the job that

Re: [Python-Dev] [ python-Bugs-1124637 ] test_subprocess is far tooslow (fwd)

2005-02-17 Thread Michael Hudson
Raymond Hettinger [EMAIL PROTECTED] writes: Let's keep the really long-running tests out of the regular test suite. For test_subprocess, consider adopting the technique used by test_decimal. When -u decimal is not specified, a small random selection of the resource intensive tests are run.

Re: [Python-Dev] Five review rule on the /dev/ page?

2005-02-17 Thread Aahz
On Thu, Feb 17, 2005, Skip Montanaro wrote: I am frantically trying to get ready to be out of town for a week of vacation. Someone sent me some patches for datetime and asked me to look at them. I begged off but referred him to http://www.python.org/dev/ and made mention of the five patch

Re: [Python-Dev] builtin_id() returns negative numbers

2005-02-17 Thread Armin Rigo
Hi Tim, On Mon, Feb 14, 2005 at 10:41:35AM -0500, Tim Peters wrote: # This is a puzzle: there's no way to know the natural width of # addresses on this box (in particular, there's no necessary # relation to sys.maxint). Isn't this natural width nowadays available as:

[Python-Dev] Re: Re: string find(substring) vs. substring in string

2005-02-17 Thread Fredrik Lundh
Raymond Hettinger wrote: but refactoring the contains code to use find_internal sounds like a good first step. any takers? I'm up for it. excellent! just fyi, unless my benchmark is mistaken, the Unicode implementation has the same problem: str in - 25.8 µsec per loop unicode in

Re: [Python-Dev] Five review rule on the /dev/ page?

2005-02-17 Thread Brett C.
[removed pydotorg from people receiving this email] Aahz wrote: On Thu, Feb 17, 2005, Skip Montanaro wrote: I am frantically trying to get ready to be out of town for a week of vacation. Someone sent me some patches for datetime and asked me to look at them. I begged off but referred him to

Re: [Python-Dev] [ python-Bugs-1124637 ] test_subprocess is far too slow (fwd)

2005-02-17 Thread Marcus Alanen
Guido van Rossum wrote: The Python test suite already has a way (the -u flag) to distinguish between regular broad-coverage testing and deep coverage for specific (or all) areas. Let's keep the really long-running tests out of the regular test suite. There used to be a farm of machines that did

RE: [Python-Dev] Windows Low Fragementation Heap yields speedup of ~15%

2005-02-17 Thread Gfeller Martin
Hi, what immediately comes to mind are Modules/cPickle.c and Modules/cStringIO.c, which (I believe) are heavily used by ZODB (which in turn is heavily used by the application). The lists also get fairly large, although not huge - up to typically 5 (complex) objects in the tests I've

Re: [Python-Dev] Windows Low Fragementation Heap yields speedup of ~15%

2005-02-17 Thread Tim Peters
[Gfeller Martin] what immediately comes to mind are Modules/cPickle.c and Modules/cStringIO.c, which (I believe) are heavily used by ZODB (which in turn is heavily used by the application). I probably guessed right the first time wink: LFH doesn't help with the lists directly, but helps

Re: [Python-Dev] license issues with profiler.py and md5.h/md5c.c

2005-02-17 Thread Donovan Baarda
On Wed, 2005-02-16 at 22:53 -0800, Gregory P. Smith wrote: fyi - i've updated the python sha1/md5 openssl patch. it now replaces the entire sha and md5 modules with a generic hashes module that gives access to all of the hash algorithms supported by OpenSSL (including appropriate legacy

[Python-Dev] Prospective Peephole Transformation

2005-02-17 Thread Raymond Hettinger
Based on some ideas from Skip, I had tried transforming the likes of x in (1,2,3) into x in frozenset([1,2,3]). When applicable, it substantially simplified the generated code and converted the O(n) lookup into an O(1) step. There were substantial savings even if the set contained only a single