def get_revision(self):
        r = self.revision
        if r:
            try:
                r = int(r)
            except __HOLE__:
                raise  # or r = None, I'm not sure which is more correct behaviour
        return r
dataset/ETHPy150Open adlibre/Adlibre-DMS/adlibre_dms/apps/core/models.py/Document.get_revision