Python’s decorators allow you to intercept the definition or execution of a function (or class), and to inject or replace the code with your own. This talk, by Colton Myers, introduces this powerful technique, stepping through its syntax and use in different ways. He also demonstrates use of the wrapt library, which makes it easier and cleaner to create decorators.
“Refactoring” is an important concept in software engineering. It allows us to change (and hopefully improve) our code, without changing what it does. In this (now-famous) talk, Katrina Owen shows us how refactoring is something that we can and should do often — and that it’s good for us, as well as for our code.