@command(index=int)
    def do_reset(self, index):
        """
        Usage: reset <index>
        """
        docs = list(self.cache._for_adf('archives').iteritems())
        docs = sorted(docs, key=compose(creation, operator.itemgetter(1)))

        if index <= 0 or len(docs) < index:
            print "No such archive."
        else:
            fname = docs[index-1][0]
            if UploadState.has_state(fname):
                UploadState.reset(fname)
                print "archive upload status reset."
            else:
                print "No such upload."
dataset/ETHPy150Open longaccess/longaccess-client/lacli/command.py/LaArchiveCommand.do_reset/original