Skip to content
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

Cannot remove watched subdirectory under Linux #128

Open
SineStriker opened this issue Oct 4, 2021 · 2 comments
Open

Cannot remove watched subdirectory under Linux #128

SineStriker opened this issue Oct 4, 2021 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@SineStriker
Copy link

Suppose a file system structure like this (Under deepin-x86_64),


|-- test1
    |-- test1-1
        |-- test1-1-1
    |-- test1-2
|-- test2

When I add test1 and test1-1 both recursively to the watcher, then the test1-1 cannot be removed.

Generally, if a dir has been added, then once its subdir is added then the subdir can't be removed. Addition of subdir after removing will cause an error of file repeated

EfswFileWatcher.zip
.

@SpartanJ
Copy link
Owner

SpartanJ commented Oct 5, 2021

I understand. The real issue is that addWatch shouldn't add the watch/directory that it's already observed by the first recursive watcher.
I never thought about it because it's kinda unintuitive and not really a correct way of using the recursive watcher. You should not use recursive watchers for that use case. I'll add a patch for this soon.

@SpartanJ SpartanJ self-assigned this Oct 5, 2021
@SpartanJ SpartanJ added the bug Something isn't working label Oct 5, 2021
@SineStriker
Copy link
Author

But that way of use works correctly under windows and mac. Now I set up a tree structure of absoulte path to check in advance and seemingly avoid such issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants