If so, then have a dict (key, sorting function and reverse bool tuple) which you could even put at the top of the file as a constant (and then use that in a single sorting function). It doesn't make me any more comfortable to know that there may be more of these functions coming.