-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
remote: verify cache exists on dir checksum #3225
Conversation
@@ -233,6 +241,9 @@ def _collect_dir(self, path_info): | |||
return sorted(result, key=itemgetter(self.PARAM_RELPATH)) | |||
|
|||
def get_dir_checksum(self, path_info): | |||
if not self.cache: |
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.
Would it make sense to unify it somehow with https://github.com/iterative/dvc/blob/master/dvc/output/base.py#L102 ?
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.
@efiop Do you mean, using same error in both places, or using self.REMOTE.scheme
to point user in right direction?
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.
@pared Well, maybe both? :)
29e55c8
to
db0e699
Compare
dvc/exceptions.py
Outdated
def __init__(self, scheme): | ||
super().__init__( | ||
"Remote cache for '{}' remote is required to perform this " | ||
"operation".format(scheme) |
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.
Could we add something helpful or add a link to docs?
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 "this operation" is not very clear. Maybe we could include path too to be more precise about what path has caused this exception?
3d63fc0
to
4c7b31d
Compare
4c7b31d
to
6557fed
Compare
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.
Thanks!
β Have you followed the guidelines in the Contributing to DVC list?
π Check this box if this PR does not require documentation updates, or if it does and you have created a separate PR in dvc.org with such updates (or at least opened an issue about it in that repo). Please link below to your PR (or issue) in the dvc.org repo.
β Have you checked DeepSource, CodeClimate, and other sanity checks below? We consider their findings recommendatory and don't expect everything to be addressed. Please review them carefully and fix those that actually improve code or fix bugs.
Thank you for the contribution - we'll try to review it as soon as possible. π
Fixes #2647