def save(self, doc):
        if doc.id:
            return self.update(doc)
        else:
            return self.insert(doc)
def handle_sigint(self, signum, _frame):
        raise KeyboardInterrupt("User interrupted execution with control-c!")