-
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
remove: granular support #5772
Comments
My personal opinion is that this is not the behavior I would expect.
I think i would go with |
cc'ing @dberenbaum |
Agree with @daavoo. Including a suggestion in the exception message is definitely a good idea. The message probably also needs to explain the issue first (something like "DVC is tracking |
After implementing and reviewing #5757 we come to the conclusion that we should further discuss about how to approach adding "granular support" to
dvc remove
or even if it is needed.Context
Given the following example yaml:
With #5757 you can now run (previously raised
StageFileDoesNotExistError
):And successfully remove only that output file.
Howeve, in the same scenario, if we have several output files under
logs
:And run:
The current behavior (after #5757) will remove the full
logs
directory. See test case:dvc/tests/func/test_remove.py
Line 51 in c871f3b
Discussion
Given the previous context, the question that arise is:
And further:
If this is the expected behavior, should we:
A) Leave the implementation as it is.
B) Add a warning to inform users that might not expect the bevaiour
C) other ideas
On the other hand, if this is not the expected behavior, should we:
A) Prevent the user from running the command (i.e. raising an exception)
B) Add support for granular remove, so that
dvc remove logs.json
only removes that specific file and not the full folder.C) other ideas
The text was updated successfully, but these errors were encountered: