Squinting at Python Objects
log in to bookmark this presentaton
Novice /
July 30th 4:30 p.m. – 5:30 p.m.
Python classes can gain attributes as if by magic. Thanks to
properties, descriptors, and (if all else fails) ``__getattr__()`` and
``__getattribute__()``, the attempt to access ``obj.something`` can
result in arbitrary code execution. If you are wondering how your
Python program is using memory, this can result in a problem: each time
you look to see if something is there, it *is*, because it is pulled in
dynamically the moment you look for it. In this talk, you will learn
how to prod Python objects gently, and hopefully learn their secrets -
and their memory usage - without actually invoking code.

