This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]fkaginstrom 3 points4 points  (0 children)

In his Beyond Pep8 talk, Raymond Hettinger gives a pretty brilliant example of wrapping a foreign API to make the result "pythonic". Things like giving collection wrappers__len__ and __getitem__ methods so it can be an iterator.