gluon/tools.py: correct error codes for Jsonrpc-2.0 exceptions.
gluon/contrib/login_methods/oauth20_account.py: removed dead code.
This commit is contained in:
@@ -157,8 +157,6 @@ server for requests. It can be used for the optional"scope" parameters for Face
|
||||
grant_type='authorization_code'
|
||||
)
|
||||
|
||||
if False and self.args:
|
||||
data.update(self.args)
|
||||
open_url = None
|
||||
opener = self.__build_url_opener(self.token_url)
|
||||
try:
|
||||
|
||||
+3
-3
@@ -4434,12 +4434,12 @@ class Service(object):
|
||||
return return_error(id, e.code, e.info)
|
||||
except BaseException:
|
||||
etype, eval, etb = sys.exc_info()
|
||||
code = -32001
|
||||
data = '%s: %s\n' % (etype.__name__, eval) + request.is_local and traceback.format_tb(etb)
|
||||
code = -32099
|
||||
data = '%s: %s\n' % (etype.__name__, eval) + str(request.is_local and traceback.format_tb(etb))
|
||||
return return_error(id, code, data=data)
|
||||
except:
|
||||
etype, eval, etb = sys.exc_info()
|
||||
return return_error(id, 32099, data='Exception %s: %s' % (etype, eval))
|
||||
return return_error(id, -32099, data='Exception %s: %s' % (etype, eval))
|
||||
|
||||
|
||||
def serve_xmlrpc(self):
|
||||
|
||||
Reference in New Issue
Block a user