Error Handling in the Real World - Portland Python User Group

preview_player
Показать описание
Error handling is hard. Regardless of the approach you take, it usually means littering your application with checks and validations that greatly reduce code readability. In this talk, I'm going to show you how to prevent error handling from making a mess of your code.

Рекомендации по теме
Комментарии
Автор

You should have gotten to speak at Pycon. This is great! Better than any error handling talks I've watched that were at Pycon. Merry should be used everywhere.

adamhendry
Автор

What a wise presentation, i've struggled with error handling across so many languages, this is the cleanest explanation!

onlybryanliu
Автор

Literally one of the best Python advices I ever got!

iznk
Автор

Exactly what I needed, this video should have a lot more views !

muneebahmed
Автор

Thank you so so much! This is going to be so useful for my university project and also a suitable topic for my associated research!

Vivian-veqt
Автор

After briefly learning Rust, I have always disliked the "pythonic" way of performing error handling, and this looks like a great alternative.

Demonithese
Автор

Thank you for this different pattern. Appears to be a great alternative to what is normal within Python. I have been frustrated with this topic for a long time over many different languages, especially now when working with cloud and big data solutions that have many clients and reach across the globe. This was actually inspiring for me. I have been working with Airflow over the past few years... and been looking for alternative ways to traverse errors, logging, and environments. I will definitely be trying this out. Thanks again!

Cty
Автор

Hey Hy Miguel ..! Really outstanding video, you had changed the prospective of error handling mech. I tried to implement this and able to do this ..

chaithu
Автор

@YouAreNotFree I agree. Either implement `__enter__` and `__exit__` in class `Merry` and/or use `contextlib`. Then case 2 can be handled without `try...except`

adamhendry
Автор

16:55 - Why not use contextlib.suppress? 2 lines as opposed to 4, and more readable.

YouAreNotFree
Автор

Why are error codes not welcome in Python?

FXguy
Автор

If you hate indentation, why use Python? 😜😜

MagnusAnand