From the course: Python Essential Training

Unlock the full course today

Join today to access over 23,200 courses taught by industry experts.

Errors and exceptions

Errors and exceptions

- [Instructor] We've seen a lot of errors working with Python so far. You know, it's that thing that happens when you divide something by zero. You get a zero division error. Working with Python, you'll see that sometimes these things are called errors and sometimes they're called exceptions. And if you read the official Python documentation, you'll find something like exceptions are decided during runtime and are retryable, errors are not retryable, eh. There are so many, well, exceptions to this rule even within the official Python code it's not really worth worrying too much about. They all work the same anyway. Controversial opinion, but errors and exceptions are the same thing. All Python errors and exceptions ultimately extend a class called the base exception. So division by zero error extends arithmetic error which extends the exception which extends base exception. And base exception is the thing that gives us…

Contents