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 dangermouseb
Recipients dangermouseb
Date 2011-12-05.15:36:33
SpamBayes Score 8.117895e-12
Marked as misclassified No
Message-id <1323099394.97.0.36914155274.issue13533@psf.upfronthosting.co.za>
In-reply-to
Content
I'm building a dll add-in (on Windows) in which I want to use the installed version of Python, not provide my own installation. When py_initialize fails it appears to call exit(). This doesn't seem very friendly behaviour for an embeddable scripting language as the host application is terminated (out of my control).

So my request is that either py_initialize is changed to return a code indicating failure or sucess or another function is added to th api to test if the installation is good or not. That way I can report to the user that there is a problem in the python installation rather than apparently crashing the host app.

Currently the only strategy I've thought of to get around this is to fork a seperate process, and inspect it after a delay to see if it is running (indicating that py_initialize hasn't failed), terminate the new process and then call py_initialize in the host application process.

This has been raised before but only in terms of consistency with the documentation, not about if a embeddable scripting engine should terminate the hosting process without regard to that host.

Many thanks,

David
History
Date User Action Args
2011-12-05 15:36:35dangermousebsetrecipients: + dangermouseb
2011-12-05 15:36:34dangermousebsetmessageid: <1323099394.97.0.36914155274.issue13533@psf.upfronthosting.co.za>
2011-12-05 15:36:34dangermouseblinkissue13533 messages
2011-12-05 15:36:33dangermousebcreate