Giter VIP home page Giter VIP logo

Comments (5)

guewen avatar guewen commented on July 19, 2024

It tries to import a sales order and in a line it has a product with Magento ID 456.
Normally, products of a sales order line are imported beforehand (in SaleOrderImporter._import_dependencies). Can you check if the product with ID 456 still exist on Magento? If it had been deleted, it could explain why it was not imported.

from connector-magento.

aignermi avatar aignermi commented on July 19, 2024

Thanks for the quick answer. I checked Magento (select * from catalog_product_entity where entity_id = '456'; & select * from sales_flat_order_item where product_id = '456';) and the product exists and I also have orders for it. I also finde the product in Odoo if I search for the SKU.

from connector-magento.

guewen avatar guewen commented on July 19, 2024

Having the product on both sides is really weird.
What if you execute on your DB SELECT * from magento_product_product WHERE magento_id = '456';?
If you have some pdb / python debug knowledge, you should try to put a breakpoint here https://github.com/OCA/connector-magento/blob/8.0/magentoerpconnect/sale.py#L977 and inspect the content of product_id.

from connector-magento.

aignermi avatar aignermi commented on July 19, 2024

Ok I found the issue, it's on our side. Those are really old orders that I try to import now, and they were also migrated into Magento from our old shop, and the order item is configurable product which is not imported into Odoo of course. But that's fine, I can fix that manually during the migration.

But I just stumbled across another error message:

Traceback (most recent call last):
  File "/opt/openerp-custom/addons/connector/connector/queue/worker.py", line 124, in run_job
    job.perform(session)
  File "/opt/openerp-custom/addons/connector/connector/queue/job.py", line 466, in perform
    self.result = self.func(session, *self.args, **self.kwargs)
  File "/opt/openerp-custom/addons/connector-magento/magentoerpconnect/unit/import_synchronizer.py", line 379, in import_record
    importer.run(magento_id, force=force)
  File "/opt/openerp-custom/addons/connector-magento/magentoerpconnect/unit/import_synchronizer.py", line 212, in run
    self._import_dependencies()
  File "/opt/openerp-custom/addons/connector-magento/magentoerpconnect/sale.py", line 931, in _import_dependencies
    'magento.product.product')
  File "/opt/openerp-custom/addons/connector-magento/magentoerpconnect/unit/import_synchronizer.py", line 119, in _import_dependency
    importer.run(magento_id)
  File "/opt/openerp-custom/addons/connector-magento/magentoerpconnect/unit/import_synchronizer.py", line 197, in run
    self.magento_record = self._get_magento_data()
  File "/opt/openerp-custom/addons/connector-magento/magentoerpconnect/unit/import_synchronizer.py", line 61, in _get_magento_data
    return self.backend_adapter.read(self.magento_id)
  File "/opt/openerp-custom/addons/connector-magento/magentoerpconnect/product.py", line 245, in read
    [int(id), storeview_id, attributes, 'id'])
  File "/opt/openerp-custom/addons/connector-magento/magentoerpconnect/product.py", line 210, in _call
    return super(ProductProductAdapter, self)._call(method, arguments)
  File "/opt/openerp-custom/addons/connector-magento/magentoerpconnect/unit/backend_adapter.py", line 168, in _call
    result = api.call(method, arguments)
  File "/usr/local/lib/python2.7/dist-packages/magento/api.py", line 159, 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 0: 'Unknown Error'>

Can you also help me with that one?

from connector-magento.

guewen avatar guewen commented on July 19, 2024

That's an error returned by Magento so it could be anything :-(

from connector-magento.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.