Join us and get access to hundreds of tutorials and a community of expert Pythonistas.

Unlock This Lesson

This lesson is for members only. Join us and get access to hundreds of tutorials and a community of expert Pythonistas.

Unlock This Lesson

Hint: You can adjust the default video playback speed in your account settings.
Sorry! Looks like there’s an issue with video playback 🙁 This might be due to a temporary outage or because of a configuration issue with your browser. Please see our video player troubleshooting guide to resolve the issue.

Else, Finally & Exceptions Recap

Give Feedback

In this lesson, you’ll learn how to use the else and finally keywords when handling exceptions. You’ll see that else clauses only get run if no exceptions occurred and finally clauses get run whether there were exceptions or not, making them useful for tidying up when programs fail unexpectedly.

Comments & Discussion

Robert on March 14, 2019

Very nice, I’ll keep watching

Anonymous on March 15, 2019

Thanks for f'text{var}'! Previously I used 'text{}'.format(var) and it was messy when a lot of variables need to be provided.

Paul on March 15, 2019

Well done. Good, clear, concise overview.

Anonymous on March 15, 2019

Really helpful! I can use what I learned today!

Anonymous on March 16, 2019

Very helpful. Straight to the point!

Daniel on March 18, 2019

Great videos. Very helpful.

Blaise Pabon on March 19, 2019

Now I realize that I never really understood try, catch, finally.

Chaitanya on March 21, 2019

A nice way of explaining the introduction part about try, except, else, finally

andrewcheryl on March 26, 2019

Super helpful and clear!

rklyba on July 5, 2019

Thank you.It’s very simple and clear. Now I gonna read “Python Exceptions: An Introduction”

Tatchi Wiggers on Sept. 4, 2019

Excellent!! Thank you!

DanielHao5 on Nov. 26, 2019

It’s short and sweet. Wish it can be expanded with some more examples… next serise.

SyedRehanAhmed on Dec. 7, 2019

Do you have quiz for exceptions ?

kihntonyk on Feb. 9, 2020

Great presentation. Thank you.

DaveLyu on Feb. 11, 2020

Great presentation. Thank you.

isayahc on May 18, 2020

Awesome tutorial!

JulianV on May 31, 2020

A very bioled down intro. Thanks.

Carlo Barrientos on May 31, 2020

Simple, clear, concise, covers all basics. Uses simple examples along with large font with bpython syntax-aware color-coded fonts. This is incredibly easy to follow especially for the topic of Exception handlers because many other tutorials go far beyond “the basics” and thus lose the audience. I hope to see more from Darren in future. BTW: I would like “some mention” of how Exceptions down deep in the call stack can percolate up to the top main

Become a Member to join the conversation.