← Back to team overview

openerp-india team mailing list archive

[Bug 1103439] [NEW] [7.0] Login signup form raises traceback if the username already exists

 

Public bug reported:

When a document is shared with a partner , an e.mail is sent with a link to the OpenERP server showing a Signup form.
In this form, if the username already exists, and ugly traceback is raised, instead of a friendlier message.

(Also, the person is able to change the Username in the form, which will
probably make useless the access rules created to share the documents,
but I'm just guessing here).


OpenERP WebClient Error

Client Traceback (most recent call last):
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/web/http.py", line 195, in dispatch
    response["result"] = method(self, **self.params)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/controllers/main.py", line 61, in signup
    self._signup_with_values(req, dbname, token, values)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/controllers/main.py", line 70, in _signup_with_values
    res_users.signup(cr, openerp.SUPERUSER_ID, values, token)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/res_users.py", line 205, in signup
    self._signup_create_user(cr, uid, values, context=context)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/res_users.py", line 229, in _signup_create_user
    return self.copy(cr, uid, template_user_id, values, context=context)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/base/res/res_users.py", line 334, in copy
    return super(res_users, self).copy(cr, uid, id, default, context)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/osv/orm.py", line 5026, in copy
    new_id = self.create(cr, uid, data, context)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/crm/crm_meeting.py", line 76, in create
    user_id = super(res_users, self).create(cr, uid, data, context=context)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/res_users.py", line 274, in create
    user_id = super(res_users, self).create(cr, uid, values, context=context)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/mail/res_users.py", line 77, in create
    user_id = super(res_users, self).create(cr, uid, data, context=context)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/base/res/res_users.py", line 747, in create
    return super(users_view, self).create(cr, uid, values, context)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/base/res/res_users.py", line 582, in create
    user_id = super(users_implied, self).create(cr, uid, values, context)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/osv/orm.py", line 4436, in create
    cr.execute('insert into "'+self._table+'" (id'+upd0+") values ("+str(id_new)+upd1+')', tuple(upd2))
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/sql_db.py", line 162, in wrapper
    return f(self, *args, **kwargs)
  File "/home/erp_user/openerp/build-oe/v7/server/openerp/sql_db.py", line 227, in execute
    res = self._obj.execute(query, params)
IntegrityError: duplicate key value violates unique constraint "res_users_login_key"
DETAIL:  Key (login)=(my.name@xxxxxxxxxxxxx) already exists.

** Affects: openobject-addons
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Addons.
https://bugs.launchpad.net/bugs/1103439

Title:
  [7.0] Login signup form raises traceback if the username already
  exists

Status in OpenERP Addons (modules):
  New

Bug description:
  When a document is shared with a partner , an e.mail is sent with a link to the OpenERP server showing a Signup form.
  In this form, if the username already exists, and ugly traceback is raised, instead of a friendlier message.

  (Also, the person is able to change the Username in the form, which
  will probably make useless the access rules created to share the
  documents, but I'm just guessing here).

  
  OpenERP WebClient Error

  Client Traceback (most recent call last):
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/web/http.py", line 195, in dispatch
      response["result"] = method(self, **self.params)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/controllers/main.py", line 61, in signup
      self._signup_with_values(req, dbname, token, values)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/controllers/main.py", line 70, in _signup_with_values
      res_users.signup(cr, openerp.SUPERUSER_ID, values, token)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/res_users.py", line 205, in signup
      self._signup_create_user(cr, uid, values, context=context)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/res_users.py", line 229, in _signup_create_user
      return self.copy(cr, uid, template_user_id, values, context=context)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/base/res/res_users.py", line 334, in copy
      return super(res_users, self).copy(cr, uid, id, default, context)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/osv/orm.py", line 5026, in copy
      new_id = self.create(cr, uid, data, context)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/crm/crm_meeting.py", line 76, in create
      user_id = super(res_users, self).create(cr, uid, data, context=context)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/auth_signup/res_users.py", line 274, in create
      user_id = super(res_users, self).create(cr, uid, values, context=context)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/mail/res_users.py", line 77, in create
      user_id = super(res_users, self).create(cr, uid, data, context=context)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/base/res/res_users.py", line 747, in create
      return super(users_view, self).create(cr, uid, values, context)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/addons/base/res/res_users.py", line 582, in create
      user_id = super(users_implied, self).create(cr, uid, values, context)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/osv/orm.py", line 4436, in create
      cr.execute('insert into "'+self._table+'" (id'+upd0+") values ("+str(id_new)+upd1+')', tuple(upd2))
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/sql_db.py", line 162, in wrapper
      return f(self, *args, **kwargs)
    File "/home/erp_user/openerp/build-oe/v7/server/openerp/sql_db.py", line 227, in execute
      res = self._obj.execute(query, params)
  IntegrityError: duplicate key value violates unique constraint "res_users_login_key"
  DETAIL:  Key (login)=(my.name@xxxxxxxxxxxxx) already exists.

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/1103439/+subscriptions


Follow ups

References