@njsmith --- we do not support Python 2.4 anyway. For Python 2.5, can I use `from __future__ import with_statement` ? That would make the code very similar.