Re: [Python-Dev] PEP 384 status

2010-08-29 Thread Antoine Pitrou
On Sun, 29 Aug 2010 09:20:56 +1000 Nick Coghlan wrote: > > Four options come to mind: > > - just leave it out of the limited API, extensions can do their own > thing to print objects > - leave PyObject_Print out of the limited API, but create a > PyObject_PrintEx that takes a Python IO stream vi

Re: [Python-Dev] PEP 384 status

2010-08-29 Thread Nick Coghlan
On Sun, Aug 29, 2010 at 6:24 PM, Antoine Pitrou wrote: > On Sun, 29 Aug 2010 09:20:56 +1000 > Nick Coghlan wrote: >> >> Four options come to mind: >> >> - just leave it out of the limited API, extensions can do their own >> thing to print objects >> - leave PyObject_Print out of the limited API,

Re: [Python-Dev] PEP 384 status

2010-08-29 Thread Antoine Pitrou
On Sun, 29 Aug 2010 18:41:45 +1000 Nick Coghlan wrote: > On Sun, Aug 29, 2010 at 6:24 PM, Antoine Pitrou wrote: > > On Sun, 29 Aug 2010 09:20:56 +1000 > > Nick Coghlan wrote: > >> > >> Four options come to mind: > >> > >> - just leave it out of the limited API, extensions can do their own > >>

Re: [Python-Dev] PEP 384 status

2010-08-29 Thread Nick Coghlan
On Sun, Aug 29, 2010 at 7:10 PM, Antoine Pitrou wrote: > On Sun, 29 Aug 2010 18:41:45 +1000 > Nick Coghlan wrote: >> I believe both that option, and my third option, would run into >> trouble due to the potential for errno confusion. > > I don't understand. What's the difference with the macro yo

Re: [Python-Dev] PEP 384 status

2010-08-29 Thread Antoine Pitrou
On Sun, 29 Aug 2010 22:16:57 +1000 Nick Coghlan wrote: > > However, since even platforms other than Windows aren't immune to > version upgrades of the standard C runtime, I'm still more comfortable > with the idea that the strict ABI should refuse to pass FILE* pointers > across extension module

Re: [Python-Dev] PEP 384 status

2010-08-29 Thread James Y Knight
On Aug 29, 2010, at 8:16 AM, Nick Coghlan wrote: > However, since even platforms other than Windows aren't immune to > version upgrades of the standard C runtime Aren't they? I don't know of any other platform that lets you have two versions of libc linked into a single address space. Linux has h

Re: [Python-Dev] r84355 - python/branches/py3k/Lib/test/test_ssl.py

2010-08-29 Thread Antoine Pitrou
On Sun, 29 Aug 2010 22:56:56 +0200 (CEST) giampaolo.rodola wrote: > +with self.assertRaises(IOError) as err: > +ssl.wrap_socket(socket.socket(), certfile=WRONGCERT) > +self.assertEqual(err.errno, errno.ENOENT) The assertEqual will never get executed since the previ

Re: [Python-Dev] r84355 - python/branches/py3k/Lib/test/test_ssl.py

2010-08-29 Thread Michael Foord
On 30/08/2010 00:23, Antoine Pitrou wrote: On Sun, 29 Aug 2010 22:56:56 +0200 (CEST) giampaolo.rodola wrote: +with self.assertRaises(IOError) as err: +ssl.wrap_socket(socket.socket(), certfile=WRONGCERT) +self.assertEqual(err.errno, errno.ENOENT) The assertEqua

Re: [Python-Dev] PEP 384 status

2010-08-29 Thread Nick Coghlan
On Mon, Aug 30, 2010 at 1:43 AM, Antoine Pitrou wrote: > On Sun, 29 Aug 2010 22:16:57 +1000 > Nick Coghlan wrote: > (actually, I'm baffled that Windows has such problems, and I would > suggest that it's not Python's job to shield Windows > application developers from Windows-specific development

Re: [Python-Dev] PEP 384 status

2010-08-29 Thread Antoine Pitrou
On Mon, 30 Aug 2010 07:31:34 +1000 Nick Coghlan wrote: > Since part of the point of > PEP 384 is to support multiple versions of the C runtime in a single > process, [...] I think that's quite a maximalist goal. The point of PEP 384 should be to define a standard API for Python, (hopefully) spann

Re: [Python-Dev] r84355 - python/branches/py3k/Lib/test/test_ssl.py

2010-08-29 Thread Giampaolo Rodolà
Sorry, I didn't get how the context-manager actually worked. Fixed in r84356. 2010/8/29 Michael Foord : >  On 30/08/2010 00:23, Antoine Pitrou wrote: >> >> On Sun, 29 Aug 2010 22:56:56 +0200 (CEST) >> giampaolo.rodola  wrote: >>> >>> +        with self.assertRaises(IOError) as err: >>> +          

Re: [Python-Dev] PEP 384 status

2010-08-29 Thread David Cournapeau
On Mon, Aug 30, 2010 at 6:43 AM, Antoine Pitrou wrote: > On Mon, 30 Aug 2010 07:31:34 +1000 > Nick Coghlan wrote: >> Since part of the point of >> PEP 384 is to support multiple versions of the C runtime in a single >> process, [...] > > I think that's quite a maximalist goal. The point of PEP 38