Searching for allowed carriers incorrectly uses magento_picking_id instead of magento_order_id

Bug #1238951 reported by Brendan Clune (Logic Supply)
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenERP Connector - Magento
Fix Released
Guewen Baconnier @ Camptocamp

Bug Description

Lines 83-92 in

magento_picking_id = picking.magento_id
if magento_picking_id is None:
    raise NoExternalId("No value found for the picking ID on "
                       "Magento side, the job will be retried later.")

self._check_allowed_carrier(picking, magento_picking_id)
tracking_args = self._get_tracking_args(picking)

The call to _check_allowed_carrier hits the getCarriers API endpoint in Magento, which expects the increment id of the magento sale, rather than the delivery object. The add_tracking_number call seems correct in this case.

Related branches

Revision history for this message
Brendan Clune (Logic Supply) (brendan-clune) wrote :

For clarification, here is the Magento API call:

 public function getCarriers($orderIncrementId)
        $order = Mage::getModel('sales/order')->loadByIncrementId($orderIncrementId);

description: updated
description: updated
description: updated
Changed in openerp-connector:
status: New → Confirmed
importance: Undecided → High
Revision history for this message
Guewen Baconnier @ Camptocamp (gbaconnier-c2c) wrote :

Thanks for the report, you are right.
I linked a proposal.

Changed in openerp-connector:
assignee: nobody → Guewen Baconnier @ Camptocamp (gbaconnier-c2c)
information type: Embargoed → Public
affects: openerp-connector → openerp-connector-magento
Changed in openerp-connector-magento:
status: Confirmed → Fix Committed
Revision history for this message
Guewen Baconnier @ Camptocamp (gbaconnier-c2c) wrote :

Fix released en 2.2.1

Changed in openerp-connector-magento:
status: Fix Committed → Fix Released
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.