def sorted_groupby(seq, key):
    if not hasattr(key, '__call__'):
        key = operator.attrgetter(key)
    return itertools.groupby(sorted(seq, key=key), key=key)
Returns path of this tree in repository.
dataset/ETHPy150Open mozilla/addons-server/src/olympia/amo/utils.py/sorted_groupby--crossover with--dataset/ETHPy150Open Djacket/djacket/core/backend/git/object.py/GitTree.get_path