Merge branch 'lint-fixes' into 'dev'

Lint fixes

See merge request crafty-controller/crafty-commander!147
This commit is contained in:
Andrew 2022-01-26 02:16:07 +00:00
commit 35334f010b
2 changed files with 6 additions and 2 deletions

View File

@ -77,8 +77,10 @@ class WebSocketHelper:
def broadcast_with_fn(self, filter_fn, event_type: str, data):
clients = list(filter(filter_fn, self.clients))
logger.debug(f"Sending to {len(clients)} out of {len(self.clients)} clients: {json.dumps({'event': event_type, 'data': data})}")
try:
logger.debug(f"Sending to {len(clients)} out of {len(self.clients)} clients: {json.dumps({'event': event_type, 'data': data})}")
except:
logger.debug("Our logging statement actually just farted line 83 websocket helper.")
for client in clients:
try:

View File

@ -84,6 +84,8 @@ if __name__ == '__main__':
args = parser.parse_args()
helper.ensure_logging_setup()
setup_logging(debug=args.verbose)
# setting up the logger object