checkout: let index checkout error-out on missing hashes

This ensures we don't assume that everything needs to have hash_info to be
checked out (e.g. we can totally checkout directly from FileStorage).

Related https://github.com/iterative/dvc/pull/9424
This commit is contained in:
Ruslan Kuprieiev
2023-06-07 14:56:19 +03:00
parent 358c5e0c39
commit d0291e8039
2 changed files with 1 additions and 12 deletions
-11
View File
@@ -153,15 +153,4 @@ def checkout( # noqa: C901
self.state.save_link(out_path, self.fs)
stats[typ_map[typ]].append(_fspath_dir(out_path))
failed = []
for out in view.outs:
if not out.use_cache:
continue
if not out.hash_info:
failed.append(_fspath_dir(out.fs_path))
if not allow_missing and failed:
raise CheckoutError(failed, stats)
return stats
+1 -1
View File
@@ -34,7 +34,7 @@ dependencies = [
"configobj>=5.0.6",
"distro>=1.3",
"dpath<3,>=2.1.0",
"dvc-data>=0.54.3,<0.55",
"dvc-data>=0.55,<0.56",
"dvc-http>=2.29.0",
"dvc-render>=0.3.1,<1",
"dvc-studio-client>=0.9.2,<1",