Remove superfluous error messages and handle uncaught exceptions
This commit is contained in:
parent
ef04f49152
commit
ee743ac327
|
@ -262,7 +262,6 @@ class SpectrumBackend:
|
|||
|
||||
def handleConvMessagePayload(self, data):
|
||||
payload = protocol_pb2.ConversationMessage()
|
||||
self.logger.error("handleConvMessagePayload")
|
||||
if (payload.ParseFromString(data) == False):
|
||||
#TODO: ERROR
|
||||
return
|
||||
|
|
|
@ -437,6 +437,8 @@ class Session(YowsupApp):
|
|||
try:
|
||||
buddy = self.buddies[buddy]
|
||||
except KeyError:
|
||||
# Sometimes whatsapp send our own presence
|
||||
if buddy != self.legacyName:
|
||||
self.logger.error("Buddy not found: %s", buddy)
|
||||
return
|
||||
|
||||
|
|
|
@ -62,7 +62,13 @@ logging.basicConfig( \
|
|||
|
||||
# Handler
|
||||
def handleTransportData(data):
|
||||
try:
|
||||
plugin.handleDataRead(data)
|
||||
except SystemExit as e:
|
||||
raise e
|
||||
except:
|
||||
logger = logging.getLogger('transwhat')
|
||||
logger.error(traceback.format_exc())
|
||||
|
||||
e4u.load()
|
||||
|
||||
|
|
Loading…
Reference in a new issue