built-in exception classes built-in exception categories default printing and state custom print displays custom data and behavior providing exception details providing exception methods summary test your knowledgequiz test your knowledgeanswers designing with exceptions nesting exception handlers examplecontrol-flow nesting examplesyntactic nesting exception idioms breaking out of multiple nested loops"go toexceptions aren' always errors functions can signal conditions with raise closing files and server connections debugging with outer try statements running in-process tests more on sys exc_info displaying errors and tracebacks exception design tips and gotchas what should be wrapped catching too muchavoid empty except and exception catching too littleuse class-based categories core language summary the python toolset development tools for larger projects summary test your knowledgequiz test your knowledgeanswers test your knowledgepart vii exercises part viii advanced topics unicode and byte strings string changes in string basics xxvi table of contents