Looks like order is unimportant so COLLECTION_URL can now be removed now, below you can use:

    for collection_name, collection in root.by_item_type.iteritems():
        ...