diff libervia/server/server.py @ 1184:eee7a896cf0e

server: show BridgeException traceback on unknown registering status
author Goffi <goffi@goffi.org>
date Tue, 14 May 2019 19:40:51 +0200
parents 5cddb52dacbb
children ba45dcdbeeaf
line wrap: on
line diff
--- a/libervia/server/server.py	Tue May 14 19:22:53 2019 +0200
+++ b/libervia/server/server.py	Tue May 14 19:40:51 2019 +0200
@@ -2372,9 +2372,9 @@
         def registered(result):
             return C.REGISTRATION_SUCCEED
 
-        def registeringError(failure):
+        def registeringError(failure_):
             # FIXME: better error handling for bridge error is needed
-            status = failure.value.fullname.split('.')[-1]
+            status = failure_.value.fullname.split('.')[-1]
             if status == "ConflictError":
                 return C.ALREADY_EXISTS
             elif status == "InvalidCertificate":
@@ -2383,8 +2383,8 @@
                 return C.INTERNAL_ERROR
             else:
                 log.error(
-                    _(u"Unknown registering error status: {status}").format(
-                        status=status
+                    _(u"Unknown registering error status: {status}\n{traceback}").format(
+                        status=status, traceback=failure_.value.message
                     )
                 )
                 return status