# HG changeset patch # User Houzefa Abbasbhay <houzefa.abba@xcg-consulting.fr> # Date 1465820911 -7200 # Mon Jun 13 14:28:31 2016 +0200 # Branch odoo8 # Node ID 715ccc1ac22d0cb60e4dad959028697e7b80bdd2 # Parent dbfb9451a23b3fbef8dd0bcc5d93cc465b9f2aec Code formatting (flake8 valid) diff --git a/__openerp__.py b/__openerp__.py --- a/__openerp__.py +++ b/__openerp__.py @@ -32,7 +32,8 @@ option if not recommended to allow users to have a password stored in odoo at the same time as having a SALM provider and id. -This module is covered by the Gnu Affero General Public License, AGPLV3 or later +This module is covered by the GNU Affero General Public License, version 3 or +later. The full source code and history can always be downloaded, modified and redistributed from here: diff --git a/model/res_users.py b/model/res_users.py --- a/model/res_users.py +++ b/model/res_users.py @@ -87,7 +87,7 @@ login.acceptSso() except lasso.Error as error: raise Exception( - 'Invalid assertion : %s' % lasso.strError(error[0]) + 'Invalid assertion : %s' % lasso.strError(error[0]) ) attrs = {} @@ -142,10 +142,10 @@ elif not matching_value and matching_attribute != "subject.nameId": raise Exception( - "Matching attribute %s not found in user attrs: %s" % ( - matching_attribute, - attrs, - ) + "Matching attribute %s not found in user attrs: %s" % ( + matching_attribute, + attrs, + ) ) validation = {'user_id': matching_value} @@ -239,7 +239,10 @@ token ) - except (openerp.exceptions.AccessDenied, passlib.exc.PasswordSizeError): + except ( + openerp.exceptions.AccessDenied, + passlib.exc.PasswordSizeError, + ): # since normal auth did not succeed we now try to find if the user # has an active token attached to his uid res = token_osv.search(