Skip to content

Represent Domain Failures with Custom Exceptions

Step 13 of 41

Design a Small Exception Hierarchy

Introduction

This lesson covers objective 2.2 of PCAP-31-03: extending the Python exception hierarchy with self-defined exceptions. It belongs to the Exceptions section, worth 14% of the score and 5 of the 40 items. Together with the two previous lessons it completes the section: you can now choose handlers, trace propagation and cleanup, and design the exception classes your own programs raise.