Contribute Media
A thank you to everyone who makes this possible: Read More

Magic Method, on the wall, who, now, is the `__fairest__` one of all?

Description

Magic methods are a very powerful feature of Python and can open a whole new door for you. However, with great power comes great responsibility.

In this talk we explore magic method's capabilities by first designing new interfaces in a series of fun experiments. Secondly, we play with creating undeletable objects and learn about the mighty Garbage Collector in cPython and how a single magic method can overturn the fate of the object. Lastly, we create a lazy Redis client to illustrate a practical application of magic methods and learn about lazy loading.

Once you see what magic methods can bring to the table, the limit is only your imagination!

Details

Improve this page