fixed signature for init on callbacks

also removed passing display to base class which already handles this
pull/13451/head
Brian Coca 9 years ago
parent 59dadc4f6b
commit d2108e9ff3

@ -50,9 +50,9 @@ class CallbackModule(CallbackBase):
CALLBACK_NAME = 'hipchat' CALLBACK_NAME = 'hipchat'
CALLBACK_NEEDS_WHITELIST = True CALLBACK_NEEDS_WHITELIST = True
def __init__(self, display): def __init__(self):
super(CallbackModule, self).__init__(display) super(CallbackModule, self).__init__()
if not HAS_PRETTYTABLE: if not HAS_PRETTYTABLE:
self.disabled = True self.disabled = True

@ -45,9 +45,9 @@ class CallbackModule(CallbackBase):
TIME_FORMAT="%b %d %Y %H:%M:%S" TIME_FORMAT="%b %d %Y %H:%M:%S"
MSG_FORMAT="%(now)s - %(category)s - %(data)s\n\n" MSG_FORMAT="%(now)s - %(category)s - %(data)s\n\n"
def __init__(self, display): def __init__(self):
super(CallbackModule, self).__init__(display) super(CallbackModule, self).__init__()
if not os.path.exists("/var/log/ansible/hosts"): if not os.path.exists("/var/log/ansible/hosts"):
os.makedirs("/var/log/ansible/hosts") os.makedirs("/var/log/ansible/hosts")

@ -40,9 +40,9 @@ class CallbackModule(CallbackBase):
CALLBACK_NAME = 'osx_say' CALLBACK_NAME = 'osx_say'
CALLBACK_NEEDS_WHITELIST = True CALLBACK_NEEDS_WHITELIST = True
def __init__(self, display): def __init__(self):
super(CallbackModule, self).__init__(display) super(CallbackModule, self).__init__()
# plugin disable itself if say is not present # plugin disable itself if say is not present
# ansible will not call any callback if disabled is set to True # ansible will not call any callback if disabled is set to True

@ -71,11 +71,11 @@ class CallbackModule(CallbackBase):
CALLBACK_NAME = 'profile_tasks' CALLBACK_NAME = 'profile_tasks'
CALLBACK_NEEDS_WHITELIST = True CALLBACK_NEEDS_WHITELIST = True
def __init__(self, display): def __init__(self):
self.stats = {} self.stats = {}
self.current = None self.current = None
super(CallbackModule, self).__init__(display) super(CallbackModule, self).__init__()
def _record_task(self, name): def _record_task(self, name):
""" """

@ -28,9 +28,9 @@ class CallbackModule(CallbackBase):
CALLBACK_NAME = 'syslog_json' CALLBACK_NAME = 'syslog_json'
CALLBACK_NEEDS_WHITELIST = True CALLBACK_NEEDS_WHITELIST = True
def __init__(self, display): def __init__(self):
super(CallbackModule, self).__init__(display) super(CallbackModule, self).__init__()
self.logger = logging.getLogger('ansible logger') self.logger = logging.getLogger('ansible logger')
self.logger.setLevel(logging.DEBUG) self.logger.setLevel(logging.DEBUG)

@ -16,9 +16,9 @@ class CallbackModule(CallbackBase):
CALLBACK_NAME = 'timer' CALLBACK_NAME = 'timer'
CALLBACK_NEEDS_WHITELIST = True CALLBACK_NEEDS_WHITELIST = True
def __init__(self, display): def __init__(self):
super(CallbackModule, self).__init__(display) super(CallbackModule, self).__init__()
self.start_time = datetime.now() self.start_time = datetime.now()

@ -36,8 +36,8 @@ class CallbackModule(CallbackBase):
CALLBACK_NAME = 'tree' CALLBACK_NAME = 'tree'
CALLBACK_NEEDS_WHITELIST = True CALLBACK_NEEDS_WHITELIST = True
def __init__(self, display): def __init__(self):
super(CallbackModule, self).__init__(display) super(CallbackModule, self).__init__()
self.tree = TREE_DIR self.tree = TREE_DIR
if not self.tree: if not self.tree:

Loading…
Cancel
Save