This does not seem to work. Raises "AttributeError: can't set attribute".
Solved it anyway. See commit 5bd78b7