ipython/ipython — pull request #921 by minrk (2011-10-22 18:32:51+00:00)
Title: Show invalid config message on TraitErrors during init

implemented via `@catch_config` decorator

Now, the event that was triggered by invalid app config (see `--log-level 5`) is triggered by bad config at any point during initialization.

This *will* catch TraitError-raising bugs in IPython itself, but only during initialization.

A less aggressive approach would be to look for all possible TraitError-raising points, and protect only those.

Also includes a tiny commit which unregisters crash_handler in `__call__`, because it should never be called twice. The fact that it calls `exit()` demonstrates that if it ever does get called twice, we are in a great big mess, and we should at least avoid printing pages and pages of extra crash messages.