Skip to content

Conversation

@karajan1001
Copy link
Contributor

@karajan1001 karajan1001 commented May 11, 2022

2022-05-11T08:38:52.3563156Z ================================== FAILURES ===================================
2022-05-11T08:38:52.3563536Z ______________ test_ls_repo_with_removed_dvc_dir_with_path_file _______________
2022-05-11T08:38:52.3564566Z [gw0] win32 -- Python 3.8.10 C:\hostedtoolcache\windows\Python\3.8.10\x64\python.exe
2022-05-11T08:38:52.3564805Z 
2022-05-11T08:38:52.3565269Z tmp_dir = WindowsTmpDir('C:/Users/runneradmin/AppData/Local/Temp/pytest-of-runneradmin/pytest-0/popen-gw0/test_ls_repo_with_removed_dvc_3')
2022-05-11T08:38:52.3566004Z dvc = Repo: 'C:\Users\runneradmin\AppData\Local\Temp\pytest-of-runneradmin\pytest-0\popen-gw0\test_ls_repo_with_removed_dvc_3'
2022-05-11T08:38:52.3566746Z scm = Git: 'C:\Users\runneradmin\AppData\Local\Temp\pytest-of-runneradmin\pytest-0\popen-gw0\test_ls_repo_with_removed_dvc_3\.git'
2022-05-11T08:38:52.3567081Z 
2022-05-11T08:38:52.3567266Z     def test_ls_repo_with_removed_dvc_dir_with_path_file(tmp_dir, dvc, scm):
2022-05-11T08:38:52.3567593Z         create_dvc_pipeline(tmp_dir, dvc)
2022-05-11T08:38:52.3567820Z     
2022-05-11T08:38:52.3568051Z         path = os.path.join("out", "file")
2022-05-11T08:38:52.3568420Z >       files = Repo.ls(os.fspath(tmp_dir), path)
2022-05-11T08:38:52.3568613Z 
2022-05-11T08:38:52.3568748Z D:\a\dvc\dvc\tests\func\test_ls.py:295: 
2022-05-11T08:38:52.3569035Z _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
2022-05-11T08:38:52.3569195Z 
2022-05-11T08:38:52.3569654Z url = 'C:\\Users\\runneradmin\\AppData\\Local\\Temp\\pytest-of-runneradmin\\pytest-0\\popen-gw0\\test_ls_repo_with_removed_dvc_3'
2022-05-11T08:38:52.3570247Z path = 'out\\file', rev = None, recursive = None, dvc_only = False
2022-05-11T08:38:52.3570453Z 
2022-05-11T08:38:52.3570621Z     def ls(url, path=None, rev=None, recursive=None, dvc_only=False):
2022-05-11T08:38:52.3570974Z         """Methods for getting files and outputs for the repo.
2022-05-11T08:38:52.3571210Z     
2022-05-11T08:38:52.3571393Z         Args:
2022-05-11T08:38:52.3571607Z             url (str): the repo url
2022-05-11T08:38:52.3571901Z             path (str, optional): relative path into the repo
2022-05-11T08:38:52.3572226Z             rev (str, optional): SHA commit, branch or tag name
2022-05-11T08:38:52.3572632Z             recursive (bool, optional): recursively walk the repo
2022-05-11T08:38:52.3573744Z             dvc_only (bool, optional): show only DVC-artifacts
2022-05-11T08:38:52.3574047Z     
2022-05-11T08:38:52.3574215Z         Returns:
2022-05-11T08:38:52.3574428Z             list of `entry`
2022-05-11T08:38:52.3574627Z     
2022-05-11T08:38:52.3574804Z         Notes:
2022-05-11T08:38:52.3575045Z             `entry` is a dictionary with structure
2022-05-11T08:38:52.3575268Z             {
2022-05-11T08:38:52.3575473Z                 "path": str,
2022-05-11T08:38:52.3575694Z                 "isout": bool,
2022-05-11T08:38:52.3575911Z                 "isdir": bool,
2022-05-11T08:38:52.3576133Z                 "isexec": bool,
2022-05-11T08:38:52.3576338Z             }
2022-05-11T08:38:52.3576504Z         """
2022-05-11T08:38:52.3576704Z         from . import Repo
2022-05-11T08:38:52.3576900Z     
2022-05-11T08:38:52.3577322Z         with Repo.open(url, rev=rev, subrepos=True, uninitialized=True) as repo:
2022-05-11T08:38:52.3577647Z             path = path or ""
2022-05-11T08:38:52.3577834Z     
2022-05-11T08:38:52.3578080Z             if path and not repo.repo_fs.exists(path):
2022-05-11T08:38:52.3578523Z >               raise PathMissingError(path, repo, dvc_only=dvc_only)
2022-05-11T08:38:52.3579628Z E               dvc.exceptions.PathMissingError: The path 'out\file' does not exist in the target repository 'C:\Users\runneradmin\AppData\Local\Temp\pytest-of-runneradmin\pytest-0\popen-gw0\test_ls_repo_with_removed_dvc_3' neither as a DVC output nor as a Git-tracked file.
2022-05-11T08:38:52.3580164Z 
2022-05-11T08:38:52.3580315Z D:\a\dvc\dvc\dvc\repo\ls.py:35: PathMissingError

Reverts #6120

@karajan1001 karajan1001 requested a review from a team as a code owner May 11, 2022 11:52
@karajan1001 karajan1001 requested review from efiop and pmrowla and removed request for pmrowla May 11, 2022 11:52
@efiop efiop merged commit 45a01c6 into main May 11, 2022
@efiop efiop deleted the revert-6120-fix5841 branch May 11, 2022 11:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants