thaond / magento-openerp-smile-synchro

Automatically exported from code.google.com/p/magento-openerp-smile-synchro
0 stars 0 forks source link

Error with customer no registered #50

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago

When you do a buy with a magento user twice, that is not registered, and
you import the order in the openerp , it displays this:
Traceback (most recent call last):
  File "/usr/lib/openerp-server/netsvc.py", line 231, in dispatch
    result = LocalService(service_name)(method, *params)
  File "/usr/lib/openerp-server/netsvc.py", line 74, in __call__
    return getattr(self, method)(*params)
  File "/usr/lib/openerp-server/service/web_services.py", line 552, in execute
    return self._execute(db, uid, wiz_id, datas, action, context)
  File "/usr/lib/openerp-server/service/web_services.py", line 532, in _execute
    return wiz.execute(db, uid, self.wiz_datas[wiz_id], action, context)
  File "/usr/lib/openerp-server/wizard/__init__.py", line 178, in execute
    res = self.execute_cr(cr, uid, data, state, context)
  File "/usr/lib/openerp-server/wizard/__init__.py", line 74, in execute_cr
    action_res = action(self, cr, uid, data, context)
  File
"/usr/lib/openerp-server/addons/magento_openerp_synchro.zip/magento_openerp_sync
hro/wizard/magento_so_import.py",
line 129, in _do_import
    'magento_id': so['customer']['customer_id'],
  File "/usr/lib/openerp-server/osv/orm.py", line 2446, in create
    cr.execute('insert into "'+self._table+'" (id'+upd0+") values
("+str(id_new)+upd1+')', tuple(upd2))
  File "/usr/lib/openerp-server/sql_db.py", line 76, in wrapper
    return f(self, *args, **kwargs)
  File "/usr/lib/openerp-server/sql_db.py", line 118, in execute
    res = self._obj.execute(query, params)
IntegrityError: duplicate key value violates unique constraint
"res_partner_name_uniq"

This  error is because the program identify with the same costumer id the
second invite magento user!!
Anybody Knows how can I solve it?
I don't know!

Original issue reported on code.google.com by freeride...@gmail.com on 2 Sep 2009 at 4:41