NOTICE: If you're reading this on GitHub.com please be aware this is a mirror of the primary remote located at https://code.richard.do/explore/projects. Please direct issues and pull requests there.
hasattr()
in Python 2 hides all exceptions, hasattr_safe()
does not, as is the behaviour in Python 3.
pip install hasattr-safe
import hasattr_safe
cake_is_a_lie = hasattr_safe(TheCake, 'lies')