Rodrigo Girão Serrão
Rodrigo Girão Serrão is the author of multiple independently published books on Python, programming, and mathematics, and frequently blogs about those same topics.
Rodrigo has also presented talks and tutorials at some of the largest Python conferences in the world, including PyCon US, EuroPython, and multiple European PyCons.
By creating technical content that is easily digestible by those looking to improve their Python knowledge, Rodrigo is working to help everyone appreciate the elegance of the Python language and to make an effective use of the tools it provides.
When he is not working or writing, Rodrigo can be found playing board games, walking his dog, or exercising at the gym.
Sessions
The decorator pattern is a functional pattern that Python developers leverage to write more modular and composable functions.
This means that your functions end up being shorter and more focused, which is good since a function should do one thing and it should do it well.
Then, you can use decorators to introduce extra useful functionality that is not part of the spec of the function.
For example, you can add caching, profiling, or logging.
Moreover, because you do this with decorators, you can reuse that logic for other functions.
In this hands-on tutorial you will learn how to determine when decorators should be used and how to write your own decorators.
This will help you write code that is easier to reason about and maintain.
By the time you are done, you will have implemented a dozen decorators, you will know the full anatomy of a decorator, and you will have explored common useful decorators from the standard library and more.
The decorator pattern is a functional pattern that Python developers leverage to write more modular and composable functions.
This means that your functions end up being shorter and more focused, which is good since a function should do one thing and it should do it well.
Then, you can use decorators to introduce extra useful functionality that is not part of the spec of the function.
For example, you can add caching, profiling, or logging.
Moreover, because you do this with decorators, you can reuse that logic for other functions.
In this hands-on tutorial you will learn how to determine when decorators should be used and how to write your own decorators.
This will help you write code that is easier to reason about and maintain.
By the time you are done, you will have implemented a dozen decorators, you will know the full anatomy of a decorator, and you will have explored common useful decorators from the standard library and more.