For those who have been following progress on getting mod_wsgi to work with Python 3.0, looks like have found new problem in Python 3.0.
Issue am seeing is that when destroying Python, am seeing strange exceptions when atexit callbacks processed. This is possibly due to atexit module no longer being friendly to multiple sub interpreters. Specifically, callbacks no longer registered at Python code level in sub interpreter but at C code level. As no separation, callback list is global across all sub interpreters. When Py_Finalize() is called, it will call callbacks for all sub interpreters against context of main sub interpreter. This is wrong to start with, but mod_wsgi compounds it as it attempts to call callbacks for a sub interpreter, but list being global means all callbacks get called for all interpreters. That is, called multiple times and with wrong interpreter context when called. See: http://bugs.python.org/issue4200 May have to install own 'atexit' module into sub interpreters that replaces Python supplied one, implemented so as to ensure that callbacks are isolated to specific sub interpreter, if they can't or will not address this problem. This makes two bugs in Python 3.0 holding things up. The other is: http://bugs.python.org/issue3723 Am starting to wander in what other ways they have broken support for multiple interpreters. From conversations with some people before, there is a bit of a movement against the code in Python for multiple sub interpreters, with most people not perhaps really understanding it. Thus, when people make changes to Python, they aren't taking into consideration the requirements for multiple sub interpreters. There is a big discussion on Python mailing list about multiple interpreters at the moment. I haven't had a chance to read it all yet, but did note one comment by someone where they said 'The argument seems to be that Apache's mod_python somehow depends on it (for reasons I don't understand).' That comment about not understanding why mod_python (and thus mod_wsgi) would want to use multiple sub interpreters is typical of comments I have seen from various people. If people don't want to try and understand how it can be used, doesn't bode well for the future and could well see multiple sub interpreter support get ditched at some point. The thread for this discussion is: http://groups.google.com/group/comp.lang.python/browse_frm/thread/9d995e4a1153a1b2 Graham --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "modwsgi" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/modwsgi?hl=en -~----------~----~----~----~------~----~------~--~---
