Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-30 Thread Nikolaus Rath
Armin Rigo writes: > Hi Jeff, > > On Mon, Apr 29, 2013 at 11:58 PM, Jeff Allen <"ja...py"@farowl.co.uk> wrote: >> In Jython, (...) > > Thanks Jeff for pointing this out. Jython thus uses a custom > mechanism similar to PyPy's, which is also similar to atexit's. It > should not be too hard to imp

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-30 Thread Armin Rigo
Hi Jeff, On Mon, Apr 29, 2013 at 11:58 PM, Jeff Allen <"ja...py"@farowl.co.uk> wrote: > In Jython, (...) Thanks Jeff for pointing this out. Jython thus uses a custom mechanism similar to PyPy's, which is also similar to atexit's. It should not be too hard to implement it in CPython 3 as well, i

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-29 Thread Nikolaus Rath
Armin Rigo writes: > Hi Nikolaus, > > On Sat, Apr 27, 2013 at 4:39 AM, Nikolaus Rath wrote: >> It's indeed very informative, but it doesn't fully address the question >> because of the _pyio module which certainly can't use any custom C code. >> Does that mean that when I'm using x = _pyio.Buffer

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-29 Thread Jeff Allen
On 29/04/2013 15:42, Armin Rigo wrote: On Sat, Apr 27, 2013 at 4:39 AM, Nikolaus Rath wrote: It's indeed very informative, but it doesn't fully address the question because of the _pyio module which certainly can't use any custom C code. Does that mean that when I'm using x = _pyio.BufferedWrit

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-29 Thread Antoine Pitrou
Le Mon, 29 Apr 2013 16:42:38 +0200, Armin Rigo a écrit : > Hi Nikolaus, > > On Sat, Apr 27, 2013 at 4:39 AM, Nikolaus Rath > wrote: > > It's indeed very informative, but it doesn't fully address the > > question because of the _pyio module which certainly can't use any > > custom C code. Does th

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-29 Thread Armin Rigo
Hi Nikolaus, On Sat, Apr 27, 2013 at 4:39 AM, Nikolaus Rath wrote: > It's indeed very informative, but it doesn't fully address the question > because of the _pyio module which certainly can't use any custom C code. > Does that mean that when I'm using x = _pyio.BufferedWriter(), I could loose >

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-26 Thread Guido van Rossum
There are no guarantees in life. On the other hand: Don't worry, be happy. On Fri, Apr 26, 2013 at 7:39 PM, Nikolaus Rath wrote: > Guido van Rossum writes: >> On Monday, April 15, 2013, Nikolaus Rath wrote: >>> Brian Curtin > writes: >>> > On Fri, Apr 12, 2013 at 12:04 AM, Nikolaus Rath >>> > >

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-26 Thread Nikolaus Rath
Guido van Rossum writes: > On Monday, April 15, 2013, Nikolaus Rath wrote: >> Brian Curtin > writes: >> > On Fri, Apr 12, 2013 at 12:04 AM, Nikolaus Rath >> > > >> wrote: >> >> [ Note: I already asked this on >> >> http://stackoverflow.com/questions/15917502 but didn't get any >> >> satisfactory

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-15 Thread Guido van Rossum
You got your snswer 16 hours ago on S.O. On Monday, April 15, 2013, Nikolaus Rath wrote: > Brian Curtin > writes: > > On Fri, Apr 12, 2013 at 12:04 AM, Nikolaus Rath > > > > wrote: > >> [ Note: I already asked this on > >> http://stackoverflow.com/questions/15917502 but didn't get any > >> satis

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-15 Thread Nikolaus Rath
Brian Curtin writes: > On Fri, Apr 12, 2013 at 12:04 AM, Nikolaus Rath wrote: >> [ Note: I already asked this on >> http://stackoverflow.com/questions/15917502 but didn't get any >> satisfactory answers] > > Sorry, but that's not a reason to repost your question to this list. > If you have to ask

Re: [Python-Dev] Destructors and Closing of File Objects

2013-04-11 Thread Brian Curtin
On Fri, Apr 12, 2013 at 12:04 AM, Nikolaus Rath wrote: > [ Note: I already asked this on > http://stackoverflow.com/questions/15917502 but didn't get any > satisfactory answers] Sorry, but that's not a reason to repost your question to this list. If you have to ask somewhere else, it would be pyt

[Python-Dev] Destructors and Closing of File Objects

2013-04-11 Thread Nikolaus Rath
[ Note: I already asked this on http://stackoverflow.com/questions/15917502 but didn't get any satisfactory answers] Hello, The description of tempfile.NamedTemporaryFile() says: , | If delete is true (the default), the file is deleted as soon as it is | closed. ` In some circumstance