Example #1
0
    def get_rev(self):
        from dvc.fs.local import LocalFileSystem

        assert self.scm
        if isinstance(self.fs, LocalFileSystem):
            from dvc.scm import map_scm_exception

            with map_scm_exception():
                return self.scm.get_rev()
        return self.fs.rev
Example #2
0
    def wrapper(exp, *args, **kwargs):
        from dvc.scm import map_scm_exception

        with map_scm_exception(), exp.scm_lock:
            return f(exp, *args, **kwargs)