Skip to content

Instantly share code, notes, and snippets.

"""
http://code.activestate.com/recipes/577982-recursively-walk-python-objects/
A small function that walks over pretty much any Python object and yields the
objects contained within (if any) along with the path to reach them. I wrote it
and am using it to validate a deserialized data-structure, but you can probably
use it for many things.
Example use: In one configuration mechanism I implemented, there exists an
UNCONFIGURED sentinel that marks configuration items that are required but