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.

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 krist...@ccpgames.com 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

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 krist...@ccpgames.com 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

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

2012-12-21 Thread Brett Cannon
On Thu, Dec 20, 2012 at 7:35 PM, Chris Jerdonek chris.jerdo...@gmail.comwrote: On Thu, Dec 20, 2012 at 1:12 PM, Brett Cannon br...@python.org 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

[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

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

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 weeks

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 jnol...@gmail.com 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

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 context.

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 python-check...@python.org 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

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 solip...@pitrou.net wrote: On Fri, 21 Dec 2012

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 gu...@python.org 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:

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 :)

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 solip...@pitrou.net 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

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

2012-12-21 Thread Chris Jerdonek
On Fri, Dec 21, 2012 at 6:46 AM, Brett Cannon br...@python.org wrote: On Thu, Dec 20, 2012 at 7:35 PM, Chris Jerdonek chris.jerdo...@gmail.com 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

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:

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 jonat...@slenders.be 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

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 solip...@pitrou.net wrote: On Fri, 21 Dec 2012 12:37:25 -0800 Guido van Rossum gu...@python.org 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

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

2012-12-21 Thread Benjamin Peterson
2012/12/21 Guido van Rossum gu...@python.org: On Fri, Dec 21, 2012 at 1:00 PM, Antoine Pitrou solip...@pitrou.net wrote: On Fri, 21 Dec 2012 12:37:25 -0800 Guido van Rossum gu...@python.org wrote: I really meant *synchronously*... I usually start with working sync code and then figure out

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 jstpie...@mecheye.net wrote: On Fri, Dec 21, 2012 at 8:02 PM, Guido van Rossum gu...@python.org 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

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 gu...@python.org 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