project8/dragonfly

level warning from AMQP handler

Opened this issue · 1 comments

We have a hard-coded warning print statement in the amqp handler:
https://github.com/project8/dragonfly/blob/develop/dragonfly/status_log_handlers/amqp_handler.py#L48

Which results in seeing this message for every dragonfly command. We should probably remind ourselves what the desired behavior is, remove this warning, and make an issue to get the desired behavior. Or if it's easy just do it all at once.

a little more detail on when/why this occurs:

To achieve a warning-less version matching our current implementation:

  • replace line 25 of AMQPHandler with super(AMQPHandler, self).setLevel(logging.WARNING)
  • replace the entire setLevel method with a dummy method to do nothing, so that bin/dragonfly doesn't overwrite the setting

Future improvement - we have an outstanding issue to disable these slack broadcasts when running interactively (see #110), which can be done by changing the log level of the AMQP handler or disabling it. We should not do conflicting things in resolving these two issues.