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 ncoghlan
Recipients bkabrda, ncoghlan, nedbat, pitrou, serhiy.storchaka
Date 2012-07-29.12:37:21
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Nothing too complicated - just noting that a test suite like ours that launches Python subprocesses to test process global state handling could fairly easily arrange to pass appropriate -C options to trigger things like recording coverage data or profiling options.

I'll also note that if you put a "" on sys.path (e.g. in the current directory if using -m for invocation), you could easily do "-C 'import preinit'" to do arbitrarily complex custom setups, including preconfiguring your test framework.

A lot of my thoughts on this come out of looking into migrating the various stdlib modules like trace, pdb and profile over to supporting everything that runpy (and hence the main executable) supports, and a lot of the complexity lies in the mechanics of how to daisy chain the two "__main__" modules together. Running a bit of extra code in __main__ as supplied on the command line before kicking off the full import process helps avoid a lot of pain.
Date User Action Args
2012-07-29 12:37:21ncoghlansetrecipients: + ncoghlan, pitrou, nedbat, serhiy.storchaka, bkabrda
2012-07-29 12:37:21ncoghlansetmessageid: <>
2012-07-29 12:37:21ncoghlanlinkissue14803 messages
2012-07-29 12:37:21ncoghlancreate