On Oct 17, 2013 7:13 AM, "Jonathan Slenders" <[email protected]>
wrote:
> There is one exception, called Gevent. what Gevent does, is patching IO
routines and swapping the current call stack for another using a
C-extension. That's a dangerous practice, which is unsafe by design (Also
why Guido van Rossem only wants to have an explicit 'yield' for
coroutinus.) I'm not sure, but if we want to support gevent with thread
locals, we meight need to hook into gevent and swap our pure-python stacks
as well.

Thread locals are "greenlet locals" in gevent so this isn't an issue.

But like Russell I doubt this proposal actually solves the problem.

For instance, thread locals are strictly equivalent to regular variables in
tests because they are single threaded (with a handful of exceptions). But
allowing testing in isolation is a major goal of "removing global state".

-- 
Aymeric.

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CANE-7mWG%3Dj-nNoiwRrryjMEk9Vqy5q69dn%3DoOOfWax0vB9ovRg%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to