This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author pitrou
Recipients bquinlan, dmalcolm, jnoller, kristjan.jonsson, lukasz.langa, neologix, pitrou, sandro.tosi, ysj.ray
Date 2011-04-25.21:39:31
SpamBayes Score 1.0732901e-07
Marked as misclassified No
Message-id <>
> I think that if we were to call PyThread_set_key_value twice on the
> same key it's either an error, or we want the last version to be
> stored, not the old one.

Not necessarily. You can have several interpreters (and therefore several thread states) in a single thread, using Py_NewInterpreter(). It's used by mod_wsgi and probably other software. If you overwrite the old value with the new one, it may break such software.

Would it be possible to cleanup the autoTLS mappings in PyOS_AfterFork() instead?
Date User Action Args
2011-04-25 21:39:33pitrousetrecipients: + pitrou, bquinlan, kristjan.jonsson, jnoller, dmalcolm, sandro.tosi, ysj.ray, neologix, lukasz.langa
2011-04-25 21:39:33pitrousetmessageid: <>
2011-04-25 21:39:32pitroulinkissue10517 messages
2011-04-25 21:39:31pitroucreate