Re: [Python-Dev] Possible GIL/threading issue involving subprocess and PyMem_MALLOC...

2012-12-21 Thread Kristján Valur Jónsson
I ran into this the other day. I had put in hooks in the PyMem_MALLOC to track memory per tasklet, and it crashed in those cases because it was being called without the GIL. My local patch was simply to _not_ release the GIL. Clearly, calling PyMem_MALLOC without the GIL is an API violation. K

Re: [Python-Dev] Possible GIL/threading issue involving subprocess and PyMem_MALLOC...

2012-12-21 Thread Antoine Pitrou
Le Fri, 21 Dec 2012 09:31:44 +, Kristján Valur Jónsson a écrit : > I ran into this the other day. I had put in hooks in the > PyMem_MALLOC to track memory per tasklet, and it crashed in those > cases because it was being called without the GIL. My local patch > was simply to _not_ release th

Re: [Python-Dev] Possible GIL/threading issue involving subprocess and PyMem_MALLOC...

2012-12-21 Thread Trent Nelson
On Fri, Dec 21, 2012 at 01:43:11AM -0800, Antoine Pitrou wrote: > Le Fri, 21 Dec 2012 09:31:44 +, > Kristján Valur Jónsson a écrit : > > I ran into this the other day. I had put in hooks in the > > PyMem_MALLOC to track memory per tasklet, and it crashed in those > > cases because it was bein

Re: [Python-Dev] PEP 3145 (With Contents)

2012-12-21 Thread Brett Cannon
On Thu, Dec 20, 2012 at 7:35 PM, Chris Jerdonek wrote: > On Thu, Dec 20, 2012 at 1:12 PM, Brett Cannon wrote: > > > > On Thu, Dec 20, 2012 at 3:55 PM, Chris Jerdonek < > chris.jerdo...@gmail.com> > > wrote: > >> > >> On Thu, Dec 20, 2012 at 12:18 PM, Brett Cannon > wrote: > >> > > >> > And pleas

[Python-Dev] Summary of Python tracker Issues

2012-12-21 Thread Python tracker
ACTIVITY SUMMARY (2012-12-14 - 2012-12-21) Python tracker at http://bugs.python.org/ To view or respond to any of the issues listed below, click on the issue. Do NOT respond to this message. Issues counts and deltas: open3844 (+18) closed 24677 (+46) total 28521 (+64) Open issues wit

Re: [Python-Dev] compile python 3.3 with bz2 support

2012-12-21 Thread Oleg Broytman
Hello. We are sorry but we cannot help you. This mailing list is to work on developing Python (adding new features to Python itself and fixing bugs); if you're having problems learning, understanding or using Python, please find another forum. Probably python-list/comp.lang.python mailing list/

Re: [Python-Dev] Testing the tests by modifying the ordering of dict items.

2012-12-21 Thread csebasha
Hello Mark, Did you raise bug for this? -- View this message in context: http://python.6.n6.nabble.com/Testing-the-tests-by-modifying-the-ordering-of-dict-items-tp3221386p5000138.html Sent from the Python - python-dev mailing list archive at Nabble.com.

Re: [Python-Dev] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Jesse Noller
On Friday, December 21, 2012 at 1:57 PM, Guido van Rossum wrote: > Dear python-dev *and* python-ideas, > > I am posting PEP 3156 here for early review and discussion. As you can > see from the liberally sprinkled TBD entries it is not done, but I am > about to disappear on vacation for a few we

Re: [Python-Dev] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Guido van Rossum
On Fri, Dec 21, 2012 at 11:06 AM, Jesse Noller wrote: > I really do like tulip as the name. It's quite pretty. I chose it because Twisted and Tornado both start with T. But those have kind of dark associations; I wanted to offset that with something lighter. (OTOH we could use a black tulip as a

Re: [Python-Dev] PEP 3145 (With Contents)

2012-12-21 Thread exarkun
Please stop copying me on this thread. Thanks, Jean-Paul ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Antoine Pitrou
Hello, > To get the current event loop, use get_event_loop(). This returns an > instance of the EventLoop class defined below or an equivalent > object. It is possible that get_event_loop() returns a different > object depending on the current thread, or depending on some other > notion of contex

Re: [Python-Dev] peps: Specify start_serving(). Add Post-History.

2012-12-21 Thread Antoine Pitrou
On Fri, 21 Dec 2012 20:34:18 +0100 (CET) guido.van.rossum wrote: > > - In either case, once it has a socket, it will wrap it in a > - transport, and then enter a loop accepting connections (the best way > - to implement such a loop depends on the platform). Each time a > - connection is acc

Re: [Python-Dev] peps: Specify start_serving(). Add Post-History.

2012-12-21 Thread Guido van Rossum
I really meant *synchronously*... I usually start with working sync code and then figure out what to do to make it async. I'll give what you suggest a try. --Guido van Rossum (sent from Android phone) On Dec 21, 2012 11:54 AM, "Antoine Pitrou" wrote: > On Fri, 21 Dec 2012 20:34:18 +0100 (CET) >

Re: [Python-Dev] peps: Specify start_serving(). Add Post-History.

2012-12-21 Thread Antoine Pitrou
On Fri, 21 Dec 2012 12:37:25 -0800 Guido van Rossum wrote: > I really meant *synchronously*... I usually start with working sync code > and then figure out what to do to make it async. I'll give what you suggest > a try. Ah. Then I hope the doc example can help you: http://docs.python.org/dev/lib

Re: [Python-Dev] [Python-ideas] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Laurens Van Houtven
Looks reasonable to me :) Comments: create_transport "combines" a transport and a protocol. Is that process reversible? that might seem like an exotic thing (and I guess it kind of is), but I've wanted this e.g for websockets, and I guess there's a few other cases where it could be useful :) eof_

Re: [Python-Dev] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Guido van Rossum
Inline. --Guido van Rossum (sent from Android phone) On Dec 21, 2012 11:47 AM, "Antoine Pitrou" wrote: > > > Hello, > > > To get the current event loop, use get_event_loop(). This returns an > > instance of the EventLoop class defined below or an equivalent > > object. It is possible that get_ev

Re: [Python-Dev] PEP 3145 (With Contents)

2012-12-21 Thread Chris Jerdonek
On Fri, Dec 21, 2012 at 6:46 AM, Brett Cannon wrote: > > On Thu, Dec 20, 2012 at 7:35 PM, Chris Jerdonek > wrote: >> >> I don't disagree that he shouldn't have cross-posted. I was just >> pointing out that the language should be clarified. What's confusing >> is that the current language implie

Re: [Python-Dev] [Python-ideas] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Jonathan Slenders
As far as I understand, "yield from" will always work, because a Future object can act like an iterator, and you can delegate your own generator to this iterator at the place of "yield from". "yield" only works if the parameter behind yield is already a Future object. Right Guido? In case of sleep

Re: [Python-Dev] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Nick Coghlan
We were tentatively calling it "concurrent.eventloop" at the 2011 language summit. -- Sent from my phone, thus the relative brevity :) ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http

Re: [Python-Dev] [Python-ideas] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Guido van Rossum
On Fri, Dec 21, 2012 at 1:04 PM, Laurens Van Houtven <_...@lvh.cc> wrote: > Looks reasonable to me :) Comments: > > create_transport "combines" a transport and a protocol. Is that process > reversible? that might seem like an exotic thing (and I guess it kind of > is), but I've wanted this e.g for

Re: [Python-Dev] [Python-ideas] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Guido van Rossum
On Fri, Dec 21, 2012 at 2:26 PM, Jonathan Slenders wrote: > As far as I understand, "yield from" will always work, because a Future > object can act like an iterator, and you can delegate your own generator to > this iterator at the place of "yield from". > "yield" only works if the parameter behi

Re: [Python-Dev] peps: Specify start_serving(). Add Post-History.

2012-12-21 Thread Guido van Rossum
On Fri, Dec 21, 2012 at 1:00 PM, Antoine Pitrou wrote: > On Fri, 21 Dec 2012 12:37:25 -0800 > Guido van Rossum wrote: >> I really meant *synchronously*... I usually start with working sync code >> and then figure out what to do to make it async. I'll give what you suggest >> a try. > > Ah. Then I

Re: [Python-Dev] peps: Specify start_serving(). Add Post-History.

2012-12-21 Thread Benjamin Peterson
2012/12/21 Guido van Rossum : > On Fri, Dec 21, 2012 at 1:00 PM, Antoine Pitrou wrote: >> On Fri, 21 Dec 2012 12:37:25 -0800 >> Guido van Rossum wrote: >>> I really meant *synchronously*... I usually start with working sync code >>> and then figure out what to do to make it async. I'll give what

Re: [Python-Dev] [Python-ideas] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Guido van Rossum
On Fri, Dec 21, 2012 at 5:17 PM, Jasper St. Pierre wrote: > On Fri, Dec 21, 2012 at 8:02 PM, Guido van Rossum wrote: > > ... snip ... > >> In PEP 3156 conformant code you're supposed always to use 'yield >> from'. The only time you see a bare yield is when it's part of the >> implementation's int

Re: [Python-Dev] [Python-ideas] PEP 3156 - Asynchronous IO Support Rebooted

2012-12-21 Thread Jasper St. Pierre
On Fri, Dec 21, 2012 at 8:02 PM, Guido van Rossum wrote: ... snip ... In PEP 3156 conformant code you're supposed always to use 'yield > from'. The only time you see a bare yield is when it's part of the > implementation's internals. (However I think tulip actually will > handle a yield the same