Re: [Python-Dev] Add an optional timeout to lock operations

2009-11-18 Thread Antoine Pitrou
Hello, > > I've submitted a patch (*) to add an optional timeout to locking > > operations (Lock.acquire() etc.). Since it's a pretty basic > > functionality, I would like to know if there was any good reason for > > not doing it. > > I always assumed it was because as a least-common-denominator

Re: [Python-Dev] Add an optional timeout to lock operations

2009-11-18 Thread David Bolen
Antoine Pitrou writes: > I've submitted a patch (*) to add an optional timeout to locking > operations (Lock.acquire() etc.). Since it's a pretty basic > functionality, I would like to know if there was any good reason for > not doing it. I always assumed it was because as a least-common-denomin

[Python-Dev] 2to3 for .c code (was Static analysis of CPython using coccinelle/spatch)

2009-11-18 Thread David Malcolm
On Tue, 2009-11-17 at 19:45 -0500, Terry Reedy wrote: > A.M. Kuchling wrote: > > On Mon, Nov 16, 2009 at 03:27:53PM -0500, David Malcolm wrote: > >> Has anyone else looked at using Coccinelle/spatch[1] on CPython source > >> code? > > > > For an excellent explanation of Coccinelle, see > >

Re: [Python-Dev] Static analysis of CPython using coccinelle/spatch

2009-11-18 Thread David Malcolm
On Tue, 2009-11-17 at 13:03 -0800, Brett Cannon wrote: > On Mon, Nov 16, 2009 at 12:27, David Malcolm wrote: > > Has anyone else looked at using Coccinelle/spatch[1] on CPython source > > code? [snip] > Running the tool over the code base and reporting the found bugs would > be appreciated. Disc

Re: [Python-Dev] Add an optional timeout to lock operations

2009-11-18 Thread Jesse Noller
On Wed, Nov 18, 2009 at 8:50 AM, Antoine Pitrou wrote: > Jesse Noller gmail.com> writes: >> >> Nick is right, many of the BSDs and FreeBSD up until fairly recently >> did not have named shared semaphore support. Still yet, the behavior >> is broken on some OSes such as OS X which you have to work

Re: [Python-Dev] Add an optional timeout to lock operations

2009-11-18 Thread Antoine Pitrou
Jesse Noller gmail.com> writes: > > Nick is right, many of the BSDs and FreeBSD up until fairly recently > did not have named shared semaphore support. Still yet, the behavior > is broken on some OSes such as OS X which you have to work around. The core locking support only uses anonymous se

Re: [Python-Dev] Add an optional timeout to lock operations

2009-11-18 Thread Jesse Noller
On Nov 18, 2009, at 5:38 AM, Nick Coghlan wrote: Antoine Pitrou wrote: Guido van Rossum python.org> writes: Will locks be interruptible with ^C? That is an oft-requested feature which also wasn't supported at that time; what's the situation nowadays? They still aren't interruptible. Fr

Re: [Python-Dev] Add an optional timeout to lock operations

2009-11-18 Thread Nick Coghlan
Antoine Pitrou wrote: > Guido van Rossum python.org> writes: >> Will locks be interruptible with ^C? That is an oft-requested feature >> which also wasn't supported at that time; what's the situation >> nowadays? > > They still aren't interruptible. From what I can read it may be possible to > m