> steps.sort(key = lambda s: s.time) This is why attrgetter in the operator module was invented. from operator import attrgetter ... steps.sort(key=attrgettr("time")) HTH, -- Miki <miki.tebeka at gmail.com> http://pythonwise.blogspot.com