import logging
try:
- # pylint: disable-msg=E0611
+ # pylint: disable=E0611
from pyinotify import pyinotify
except ImportError:
import pyinotify
from ganeti import daemon
from ganeti import errors
+
# We contributed the AsyncNotifier class back to python-pyinotify, and it's
# part of their codebase since version 0.8.7. This code can be removed once
# we'll be ready to depend on python-pyinotify >= 0.8.7
"""An asyncore dispatcher for inotify events.
"""
- # pylint: disable-msg=W0622,W0212
+ # pylint: disable=W0622,W0212
def __init__(self, watch_manager, default_proc_fun=None, map=None):
"""Initializes this class.
@param watch_manager: inotify watch manager
"""
- # pylint: disable-msg=W0231
+ # pylint: disable=W0231
# no need to call the parent's constructor
self.watch_manager = watch_manager
if self._watch_handle is not None and self.RemoveWatch(self._watch_handle):
self._watch_handle = None
- # pylint: disable-msg=C0103
+ # pylint: disable=C0103
# this overrides a method in pyinotify.ProcessEvent
def process_IN_IGNORED(self, event):
# Since we monitor a single file rather than the directory it resides in,
self._watch_handle = None
self._callback(False)
- # pylint: disable-msg=C0103
+ # pylint: disable=C0103
# this overrides a method in pyinotify.ProcessEvent
def process_IN_MODIFY(self, event):
# This gets called when the monitored file is modified. Note that this