(For more, visit https://pythontutorials.eu !) In this video, I demonstrate the basics of function decorators in Python. I also demonstrate the @functools.wraps decorator for preserving docstrings of decorated functions.
You can download the Jupyter Notebook for this video from https://osf.io/szwhk/