This is a misdiagnosis. The fancy handling is invoked only when the exception reaches the top level (i.e. when the python interpreter is about to exit anyway). It is not done when an exception is raised, and adds no overhead to code that uses exceptions at runtime.
Think of it as similar to the bash handler that searches for known executable names on failed commands and prompts you for an apt-get line to install the software. It takes significant time, but only runs on error.
Think of it as similar to the bash handler that searches for known executable names on failed commands and prompts you for an apt-get line to install the software. It takes significant time, but only runs on error.