[Stackless] Fwd: Cannot re-initialize Python

Richard Tew richard.m.tew at gmail.com
Sun Feb 15 14:14:49 CET 2009

---------- Forwarded message ----------
From: OvermindDL1 <overminddl1 at gmail.com>
Date: Sat, Feb 14, 2009 at 6:10 PM
Subject: Re: [Stackless] Cannot re-initialize Python
To: Richard Tew <richard.m.tew at gmail.com>

On Sat, Feb 14, 2009 at 8:17 AM, Richard Tew <richard.m.tew at gmail.com> wrote:
> On Sat, Feb 14, 2009 at 9:03 AM, Mark Gants <mgants4 at hotmail.com> wrote:
>> I have embedded Stackless Python 2.6.1 into a C++ application of mine. At
>> certain points in the application I would like to 're-init' Python to clean
>> things up without having to shutdown and re-launch my application. First
>> time initializing Python works fine. I encounter a crash though when trying
>> to initialize Python a second time.
> ...
>> Does anyone know if this issue has been addressed in Stackless Python 3.0? I
>> would like to use v3.0, but chose v2.6.1 due to the warnings about bugs in
>> v3.0.
> There is no reason to believe it would be fixed in 3.0, as no explicit
> fixes have been made for this.

I ran into this myself long ago as well.  As such I came up with the
fact that Python was not designed, nor will ever be designed to be
cleanly shutdown, it just will not clean up well, it expects the
program to shut down as soon as it shuts down, so the program shutdown
will clean the rest up.  As such, it will never re-init well as well,
not without some major patching anyway.
It has nothing to do with Stackless though, this is a pure Python annoyance.

More information about the Stackless mailing list