python 2.5 compatability for t.wrap