i have code, which does something like this:
item.previous.parent.parent.aTag['href']
now i would like to be able to add filters fast, so hardcoding is no longer an option. how can i access the same tags with a path coded in a string?
of course i could invent some format like [('getattr', 'previous'), ('getattr', 'parent'), ..., ('getitem', 'href)] and parse it with _getattr_ and _getitem_.
Now the question: Is there already a more beautiful way of doing it, or do i need to implement it myself?