Skip to content
This repository has been archived by the owner on Apr 22, 2024. It is now read-only.

Commit

Permalink
Merge 1912570 into 5b01912
Browse files Browse the repository at this point in the history
  • Loading branch information
hdiogenes committed Dec 13, 2019
2 parents 5b01912 + 1912570 commit dcd1da4
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions kytos/core/controller.py
Expand Up @@ -85,7 +85,7 @@ def __init__(self, options=None, loop=None):
#: dict: mapping of events and event listeners.
#:
#: The key of the dict is a KytosEvent (or a string that represent a
#: regex to match agains KytosEvents) and the value is a list of
#: regex to match against KytosEvents) and the value is a list of
#: methods that will receive the referenced event
self.events_listeners = {'kytos/core.connection.new':
[self.new_connection]}
Expand Down Expand Up @@ -772,11 +772,16 @@ def load_napp(self, username, napp_name):
username, napp_name, err)
return
except FileNotFoundError as err:
msg = "NApp module not found, assuming it's a meta napp: %s"
msg = "NApp module not found, assuming it's a meta-napp: %s"
self.log.warning(msg, err.filename)
return

napp = napp_module.Main(controller=self)
try:
napp = napp_module.Main(controller=self)
except: # noqa pylint: disable=bare-except
self.log.critical("NApp initialization failed: %s/%s",
username, napp_name, exc_info=True)
return

self.napps[(username, napp_name)] = napp

Expand Down

0 comments on commit dcd1da4

Please sign in to comment.