openlabs / magento_integration

Magento OpenERP Integration
https://openerp-magento-connector.readthedocs.org/en/develop/
80 stars 77 forks source link

Error during Import of Orders #220

Closed rodrigo441 closed 10 years ago

rodrigo441 commented 10 years ago

Hey Folks,

we installed on a vps ubunto 14.04 (new and sexy :) openerp with openlabs connector. We installed all necessary on magento and defined roles etc. we are able to successfully import catalog and update catalog but when it comes to orders we get some problems here:

I try to import "orders" for the first time and it gives me this:

OpenERP Server Error Client Traceback (most recent call last): File "/opt/openerp/server/openerp/addons/web/http.py", line 204, in dispatch response["result"] = method(self, *_self.params) File "/opt/openerp/server/openerp/addons/web/controllers/main.py", line 1132, in call_button action = self._call_kw(req, model, method, args, {}) File "/opt/openerp/server/openerp/addons/web/controllers/main.py", line 1120, in _call_kw return getattr(req.session.model(model), method)(_args, *kwargs) File "/opt/openerp/server/openerp/addons/web/session.py", line 42, in proxy result = self.proxy.execute_kw(self.session._db, self.session._uid, self.session._password, self.model, method, args, kw) File "/opt/openerp/server/openerp/addons/web/session.py", line 30, in proxy_method result = self.session.send(self.service_name, method, args) File "/opt/openerp/server/openerp/addons/web/session.py", line 103, in send raise xmlrpclib.Fault(openerp.tools.ustr(e), formatted_info)

Server Traceback (most recent call last): File "/opt/openerp/server/openerp/addons/web/session.py", line 89, in send return openerp.netsvc.dispatch_rpc(service_name, method, args) File "/opt/openerp/server/openerp/netsvc.py", line 296, in dispatch_rpc result = ExportService.getService(service_name).dispatch(method, params) File "/opt/openerp/server/openerp/service/web_services.py", line 626, in dispatch res = fn(db, uid, _params) File "/opt/openerp/server/openerp/osv/osv.py", line 190, in execute_kw return self.execute(db, uid, obj, method, args, _kw or {}) File "/opt/openerp/server/openerp/osv/osv.py", line 132, in wrapper return f(self, dbname, _args, _kwargs) File "/opt/openerp/server/openerp/osv/osv.py", line 199, in execute res = self.execute_cr(cr, uid, obj, method, _args, _kw) File "/opt/openerp/server/openerp/osv/osv.py", line 187, in execute_cr return getattr(object, method)(cr, uid, _args, *_kw) File "/opt/openerp/server/openerp/addons/magento_integration/wizard/import_orders.py", line 34, in import_orders cursor, user, store_view, context File "/opt/openerp/server/openerp/addons/magentointegration/magento.py", line 607, in import_orders_from_store_view order_api.info(order['increment_id']), new_context File "/opt/openerp/server/openerp/addons/magento_integration/sale.py", line 179, in find_or_create_using_magento_data cursor, user, order_data, context File "/opt/openerp/server/openerp/addons/magento_integration/sale.py", line 367, in create_using_magento_data cursor, user, order_data, context File "/opt/openerp/server/openerp/addons/magento_integration/sale.py", line 435, in get_item_line_data_using_magento_data context=context File "/opt/openerp/server/openerp/addons/magento_integration/product.py", line 255, in find_or_create_using_magento_id product_data = product_api.info(magento_id) File "/usr/local/lib/python2.7/dist-packages/magento-0.4-py2.7.egg/magento/catalog.py", line 265, in info 'catalog_product.info', [product, store_view, attributes] File "/usr/local/lib/python2.7/dist-packages/magento-0.4-py2.7.egg/magento/api.py", line 161, in call return self.client.call(self.session, resource_path, arguments) File "/usr/lib/python2.7/xmlrpclib.py", line 1224, in call return self.send(self.name, args) File "/usr/lib/python2.7/xmlrpclib.py", line 1578, in request verbose=self.verbose File "/usr/lib/python2.7/xmlrpclib.py", line 1264, in request return self.single_request(host, handler, request_body, verbose) File "/usr/lib/python2.7/xmlrpclib.py", line 1297, in single_request return self.parse_response(response) File "/usr/lib/python2.7/xmlrpclib.py", line 1473, in parse_response return u.close() File "/usr/lib/python2.7/xmlrpclib.py", line 793, in close raise Fault(**self._stack[0]) Fault: < Fault 101: 'Product not exists.' >

Anyone of you guys had this issue already and how can this be solved?

Fault: < Fault 101: 'Product not exists. '>

It might occurred to us that it could be that throughout the years the products and its ID´s changed and therefore are not in our current catalog anymore but still in the older orders - could that cause a "conflict"?

Thanks for your help.

rodrigo

sharoonthomas commented 10 years ago

This is more likely to be the case. Magento allows deletion of production, even the ones which have been sold. Not sure how you can get around this one if you import your legacy orders