[Python-Dev] Draft PEP and reference implementation of a Python launcher for Windows
digitalxero at gmail.com
Sun Mar 20 13:56:22 CET 2011
On Sun, Mar 20, 2011 at 5:37 AM, "Martin v. Löwis" <martin at v.loewis.de> wrote:
> I see three problems with creating child processes:
> - WaitForSingleObject and GetExitProcessCode must work correctly. I
> think this is possible to achieve
> - applications using the debug API, PSAPI, etc. will be confused if
> the action all happens in a child process. I can accept that they
> have to adjust, though.
> - TerminateProcess must work correctly, and I see no way to achieve
> that (i.e. terminating the parent process won't terminate the child)
Before Mark wrote up this pep I had started experimenting with how to
make the launcher and I was able to get it to launch python while
exiting py.exe and as far as I could tell it behaved just as if I had
launched the app directly by double clicking it.
I tested it with long running scripts and a full application (openrpg)
that has many external dependencies and in both cases py.exe exited
and the script/app ran as expected leaving the python console open
until the script/app exited on it's own. I did not test adding
debugger breakpoint in the code though to see how it behaved though.
More information about the Python-Dev