Popular recipes tagged "debugging" and "exception"http://code.activestate.com/recipes/tags/debugging+exception/popular/2015-07-05T23:46:59-07:00ActiveState Code RecipesRecursionError exception: concise and informative output (Python)
2015-07-05T23:46:59-07:00elazarhttp://code.activestate.com/recipes/users/4187847/http://code.activestate.com/recipes/578660-recursionerror-exception-concise-and-informative-o/
<p style="color: grey">
Python
recipe 578660
by <a href="/recipes/users/4187847/">elazar</a>
(<a href="/recipes/tags/debugging/">debugging</a>, <a href="/recipes/tags/exception/">exception</a>, <a href="/recipes/tags/handler/">handler</a>, <a href="/recipes/tags/recursion/">recursion</a>).
Revision 3.
</p>
<p>Replaces the default exception hook with one that, upon "infinite recursion", removes the last cycle. This results in a significantly cleaner and shorter error message.</p>
<p>Usage: simply import <module> as _</p>
<p>For more details see the descussion here:
<a href="https://mail.python.org/pipermail/python-ideas/2013-September/023190.html" rel="nofollow">https://mail.python.org/pipermail/python-ideas/2013-September/023190.html</a></p>
Easy Exception, Error Handling and Debugging with Auto Logging (Python)
2010-04-06T20:40:05-07:00AJ. Mayorgahttp://code.activestate.com/recipes/users/4173476/http://code.activestate.com/recipes/577144-easy-exception-error-handling-and-debugging-with-a/
<p style="color: grey">
Python
recipe 577144
by <a href="/recipes/users/4173476/">AJ. Mayorga</a>
(<a href="/recipes/tags/debug/">debug</a>, <a href="/recipes/tags/debugging/">debugging</a>, <a href="/recipes/tags/error_propagation/">error_propagation</a>, <a href="/recipes/tags/exception/">exception</a>, <a href="/recipes/tags/logging/">logging</a>).
Revision 5.
</p>
<p>Being new to Python and trying to chase where in my project exceptions were taking place always seems to take up a large amount of time. So I created this class that I now pretty use in all my projects to help me save time tracking exceptions and errors. its also has the ability to generate error logs or to output SQL query and data tuples for Database logging. Ive added sample code to give you an idea of how I normally use it. Hope this helps its saved me hours in tracking error/exception. Feed back would be great, mind you havent been Python all that long</p>