-
Notifications
You must be signed in to change notification settings - Fork 1.2k
index: fix fs cache location #9969
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
dvc/cachemgr.py
Outdated
@@ -73,6 +74,16 @@ def __init__(self, repo): | |||
legacy_odb = _get_odb(repo, settings, hash_name="md5-dos2unix", **kwargs) | |||
self._odb["legacy"] = legacy_odb | |||
|
|||
@property | |||
def fs(self): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will be confusing with fs
the filesystem. Maybe file_storage
or file_store
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also thought about that, but it is a property of cache manager, not particular cache. It is meant to mean fs_storage
or fs_cache
, since it is a per-fs cache. E.g. we have dvc.cache.local
, dvc.cache.repo
, dvc.cache.s3
(obsoleted) and dvc.cache.fs
. I'll rename it to fs_cache
then.
Codecov ReportPatch coverage is
📢 Thoughts on this report? Let us know!. |
@@ -73,6 +74,16 @@ def __init__(self, repo): | |||
legacy_odb = _get_odb(repo, settings, hash_name="md5-dos2unix", **kwargs) | |||
self._odb["legacy"] = legacy_odb | |||
|
|||
@property | |||
def fs_cache(self): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also could you please write a docstring on what this is being used for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, added.
Existing logic might result in weird fs cache location like `.dvc/cache/files/md5/fs`, while we really only want `.dvc/cache/fs`, since it is not an odb cache.
Existing logic might result in weird fs cache location like
.dvc/cache/files/md5/fs
, while we really only want.dvc/cache/fs
, since it is not an odb cache.