diff --git a/dvc/remote/base.py b/dvc/remote/base.py index 9efd0180e..5f77d8636 100644 --- a/dvc/remote/base.py +++ b/dvc/remote/base.py @@ -140,14 +140,6 @@ class RemoteBASE(object): def cache(self): return getattr(self.repo.cache, self.scheme) - @property - def cache_dir(self): - return ( - getattr(self.path_info, "fspath", self.path_info.url) - if self.path_info - else None - ) - def get_file_checksum(self, path_info): raise NotImplementedError diff --git a/dvc/remote/local/__init__.py b/dvc/remote/local/__init__.py index 0a0a4b84d..168c1f9c0 100644 --- a/dvc/remote/local/__init__.py +++ b/dvc/remote/local/__init__.py @@ -97,6 +97,10 @@ class RemoteLOCAL(RemoteBASE): def state(self): return self.repo.state + @property + def cache_dir(self): + return self.path_info.fspath if self.path_info else None + @classmethod def supported(cls, config): return True @@ -332,7 +336,9 @@ class RemoteLOCAL(RemoteBASE): else: logger.debug("Collecting information from remote cache...") remote_exists = list( - remote.cache_exists(md5s, jobs=jobs, name=remote.cache_dir) + remote.cache_exists( + md5s, jobs=jobs, name=str(remote.path_info) + ) ) self._fill_statuses(ret, local_exists, remote_exists)