mirror of
https://github.com/Stone-Red-Code/dvc.git
synced 2026-11-09 23:10:24 +01:00
use realpath for is_in_repo calculation (#5954)
This is because, the repo root is used from a realpath, and the stage.wdir is abspath. We might need to use same kinds of path, but this patch seems to be the easiest/fastest way to fix the flaky tests (if all the tests agree).
This commit is contained in:
+3
-3
@@ -73,9 +73,9 @@ class LocalOutput(BaseOutput):
|
||||
if os.path.isabs(self.def_path):
|
||||
return False
|
||||
|
||||
if self.repo and not self.path_info.isin(self.repo.root_dir):
|
||||
return False
|
||||
return True
|
||||
return self.repo and path_isin(
|
||||
os.path.realpath(self.path_info), self.repo.root_dir
|
||||
)
|
||||
|
||||
def dumpd(self):
|
||||
ret = super().dumpd()
|
||||
|
||||
Reference in New Issue
Block a user