Error Installing Conector Magento - KeyError: 'exportable'

Bug #579649 reported by Juan Pablo
30
This bug affects 5 people
Affects Status Importance Assigned to Milestone
Magento OpenERP Connector
Invalid
Undecided
Unassigned

Bug Description

I am installing Magento connector. I migrated my database from version 5.0.4 to 5.0.10. When I go to install the magento connector gives me the following error (I also gave it above):

Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/openerp-server/netsvc.py", line 245, in dispatch
    result = LocalService(service_name)(method, *params)
  File "/usr/lib/python2.5/site-packages/openerp-server/netsvc.py", line 74, in __call__
    return getattr(self, method)(*params)
  File "/usr/lib/python2.5/site-packages/openerp-server/service/web_services.py", line 632, in execute
    return self._execute(db, uid, wiz_id, datas, action, context)
  File "/usr/lib/python2.5/site-packages/openerp-server/service/web_services.py", line 612, in _execute
    return wiz.execute(db, uid, self.wiz_datas[wiz_id], action, context)
  File "/usr/lib/python2.5/site-packages/openerp-server/wizard/__init__.py", line 178, in execute
    res = self.execute_cr(cr, uid, data, state, context)
  File "/usr/lib/python2.5/site-packages/openerp-server/wizard/__init__.py", line 73, in execute_cr
    action_res = action(self, cr, uid, data, context)
  File "/usr/lib/python2.5/site-packages/openerp-server/addons/base/module/wizard/wizard_module_upgrade.py", line 92, in _upgrade_module
    db, pool = pooler.restart_pool(cr.dbname, update_module=True)
  File "/usr/lib/python2.5/site-packages/openerp-server/pooler.py", line 62, in restart_pool
    return get_db_and_pool(db_name, force_demo, status, update_module=update_module)
  File "/usr/lib/python2.5/site-packages/openerp-server/pooler.py", line 40, in get_db_and_pool
    addons.load_modules(db, force_demo, status, update_module)
  File "/usr/lib/python2.5/site-packages/openerp-server/addons/__init__.py", line 740, in load_modules
    r = load_module_graph(cr, graph, status, report=report)
  File "/usr/lib/python2.5/site-packages/openerp-server/addons/__init__.py", line 631, in load_module_graph
    tools.convert_xml_import(cr, m, fp, idref, mode=mode, **kwargs)
  File "/usr/lib/python2.5/site-packages/openerp-server/tools/convert.py", line 874, in convert_xml_import
    obj.parse(doc.getroot())
  File "/usr/lib/python2.5/site-packages/openerp-server/tools/convert.py", line 771, in parse
    self._tags[rec.tag](self.cr, rec, n)
  File "/usr/lib/python2.5/site-packages/openerp-server/tools/convert.py", line 743, in _tag_record
    id = self.pool.get('ir.model.data')._update(cr, self.uid, rec_model, self.module, res, rec_id or False, not self.isnoupdate(data_node), noupdate=self.isnoupdate(data_node), mode=self.mode )
  File "/usr/lib/python2.5/site-packages/openerp-server/addons/base/ir/ir_model.py", line 488, in _update
    model_obj.write(cr, uid, [res_id], values, context=context)
  File "/usr/lib/python2.5/site-packages/openerp-server/addons/magentoerpconnect/product.py", line 642, in write
    stat = super(product_product, self).write(cr, uid, ids, vals, context)
  File "/usr/lib/python2.5/site-packages/openerp-server/osv/orm.py", line 2513, in write
    fobj = self._inherit_fields[field][2]
KeyError: 'exportable'

What could it be?
Thanks!

Revision history for this message
Kyle Waid (midwest) wrote :

I have nearly the same error. It only occured when I tried to update the module. Cant reinstall or anything, have to use a new database because I cant reinstall or update the module.

Revision history for this message
Kyle Waid (midwest) wrote :

I only experienced this issue when I made a modification to the files but when I updated the module it was missing the view entries which caused this error. I would also state that OpenERP is not very good at uninstalling modules, for instance it leaves the database tables and references intact. Check to see you have the exact same module you started with as missing entries that are referenced could cause this issue. I was not able to reproduce this error on a clean install.

Changed in magentoerpconnect:
status: New → Invalid
Revision history for this message
Kyle Waid (midwest) wrote :

I keep getting this error randomly when trying to reinstall the module. Completely makes it unworkable to use occasionally.

Changed in magentoerpconnect:
status: Invalid → Confirmed
Revision history for this message
Hillebrand Dalstra (hillebrand-dalstra) wrote :
Download full text (3.8 KiB)

I can confirm this error.

Using the following:

OpenERP Server 6.0.1
lp:openobject-addons/extra-6.0 (revno: 5184)
lp:~openlabs-akretion-consortium/magentoerpconnect/openerp6-module-with-configurable-and-options (revno:391)

Environment Information :
System : Linux-2.6.32-27-generic-x86_64-with-Ubuntu-10.04-lucid
OS Name : posix
Distributor ID: Ubuntu
Description: Ubuntu 10.04.1 LTS
Release: 10.04
Codename: lucid
Operating System Release : 2.6.32-27-generic
Operating System Version : #49-Ubuntu SMP Thu Dec 2 00:51:09 UTC 2010
Operating System Architecture : 64bit
Operating System Locale : en_US.UTF8
Python Version : 2.6.5
OpenERP-Client Version : 6.0.1
Last revision No. & ID :Bazaar Package not Found !Traceback (most recent call last):
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/netsvc.py", line 489, in dispatch
    result = ExportService.getService(service_name).dispatch(method, auth, params)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/service/web_services.py", line 599, in dispatch
    res = fn(db, uid, *params)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/osv/osv.py", line 122, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/osv/osv.py", line 176, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/osv/osv.py", line 167, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/addons/base/module/wizard/base_module_upgrade.py", line 98, in upgrade_module
    _db, pool = pooler.restart_pool(cr.dbname, update_module=True)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/pooler.py", line 60, in restart_pool
    return get_db_and_pool(db_name, force_demo, status, update_module=update_module)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/pooler.py", line 39, in get_db_and_pool
    addons.load_modules(db, force_demo, status, update_module)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/addons/__init__.py", line 883, in load_modules
    processed_modules.extend(load_module_graph(cr, graph, status, report=report, skip_modules=processed_modules))
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/addons/__init__.py", line 748, in load_module_graph
    load_init_update_xml(cr, m, idref, mode, kind)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/addons/__init__.py", line 641, in load_init_update_xml
    tools.convert_xml_import(cr, m, fp, idref, mode=mode, **kwargs)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/tools/convert.py", line 975, in convert_xml_import
    obj.parse(doc.getroot())
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/tools/convert.py", line 865, in parse
    self._tags[rec.tag](self.cr, rec, n)
  File "/home/openerp/openerp-server/magento/openerp-server-6.0.1/bin/tools/convert.py", line 832, in _tag_record
    id = self.pool.get('ir.model.data')._update(...

Read more...

Revision history for this message
philu (philu) wrote :

I got the same error as Hillebrand, with the same lead-up as Kyle in comment #2.

Revision history for this message
Daniel Bruckhaus (promostage) wrote :

Same Error here, install failes with versions:

OpenERP: 6.0.2 (openerp-server-6.0.2-0_all.deb)
magentoerpconnect: 6.0.1.0 (branch: magentoerpconnect/openerp6-module, rev. 405)
extra-6.0: rev 5504

Revision history for this message
Kyle Waid (midwest) wrote :

I was only able to reproduce the error when uninstalling the module and re-installing. It appears that once the module is installed it cannot be removed, which makes sense, but perhaps you should be warned of this? And perhaps disable the uninstall button or display warning upon uninstalling it would break the database. Something to be examined here.

Also I see you are using a .deb so I am assuming you downloaded a packaged file not using the sources. The packaged files usually unfortunately contain bugs or old code as expected so it is possible you are encountering an issue with that. I would recommend using the Launchpad branches and re-attempting to install the module.

Revision history for this message
Daniel Bruckhaus (promostage) wrote :

Kyle: Well, the .deb is the official one from openerp.com... One would think, those should be save to use!?

However, since the reinstall situation applies here to, I will setup another fresh database.

So I understand, that using magentoerpconnect does not require product IMPORT from magento?

What would be the steps to EXPORT the demo data to Magento?

Thx!

Revision history for this message
Kyle Waid (midwest) wrote :

Marking invalid, but note DO NOT uninstall magentoerpconnect after it has data. Perhaps you could disable uninstalling capability or at least warn?

Changed in magentoerpconnect:
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.