7.0: stock_picking.action_cancel can cause RuntimeError: maximum recursion depth exceeded

Bug #1264950 reported by Alexandre Fayolle - camptocamp
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
New
Undecided
Unassigned
OpenERP Community Backports (Addons)
Status tracked in 7.0
7.0
New
Undecided
Unassigned

Bug Description

During the testing of an addon for a customer, in which I call cancel_assign on stock pickings I came across the exception for which a stack trace is attached to this bug report.

It looks like writing to the state attribute of the picking generates call to trg_write, even if the value written is the same as the existing value. So a possible fix would be to check for the state of the picking and only issue a call to write if the value is to be modified.

Related branches

Revision history for this message
Alexandre Fayolle - camptocamp (alexandre-fayolle-c2c) wrote :
Revision history for this message
Alexandre Fayolle - camptocamp (alexandre-fayolle-c2c) wrote :

I checked that the attached patch does fix the issue (had to patch action_cancel and action_assign_wkfl which both would cause an issue in the addon for my customer).

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

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