Implement BuildHooksEnv for NoHooksLU
[ganeti-local] / lib / locking.py
index 874b7c0..9fb6507 100644 (file)
 
 """Module implementing the Ganeti locking code."""
 
-# pylint: disable-msg=W0613,W0201
+# pylint: disable-msg=W0212
+
+# W0212 since e.g. LockSet methods use (a lot) the internals of
+# SharedLock
 
 import threading
 # Wouldn't it be better to define LockingError in the locking module?
@@ -761,7 +764,8 @@ class GanetiLockManager:
     """
     return BGL in self.__keyring[LEVEL_CLUSTER]._list_owned()
 
-  def _contains_BGL(self, level, names): # pylint: disable-msg=C0103
+  @staticmethod
+  def _contains_BGL(level, names): # pylint: disable-msg=C0103
     """Check if the level contains the BGL.
 
     Check if acting on the given level and set of names will change