dsoprea / PyInotify

An efficient and elegant inotify (Linux filesystem activity monitor) library for Python. Python 2 and 3 compatible.
GNU General Public License v2.0
245 stars 73 forks source link

Fix constant in adapter to match with DELETE events #58

Closed XaF closed 4 years ago

XaF commented 6 years ago

The previous behavior was duplicating a block of code and making one of the two useless. This fixes that by replacing the constant to IN_DELETE instead of IN_MOVED_FROM in one of the two blocks.

Signed-off-by: Raphaël Beamonte raphael.beamonte@gmail.com

XaF commented 6 years ago

Please note that failing tests are not related...

Elias481 commented 5 years ago

Again, Your fix is right - but sourrunding fixes need to be applied at same time otherwise test will fail. See also my comment at #57 . But for these errors You just need the fix from #57 (or a different one that I need but that fixes the same issue btw... that#s the reason I'm in to this..) to have the superficial argument promoted (=used for decision whether watch handle should be removed from inotify in the fix I have in mind). Otherwise the remove_watch raises Exception in trying to already automatically removed directory from inotify. So You should probably put them into one merge request (including the missing fix to get #57 to not break anything but fix issues as #51 and #46 ).