Context not passed to _constraints functions

Bug #891592 reported by Stefan Rijnhart (Opener)
24
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Odoo Server (MOVED TO GITHUB)
Invalid
Wishlist
Unassigned

Bug Description

Hi,

the context parameter is not passed to functions listed in the _constraints on the model.

Note that a number of constraints functions (maybe all) in the base module do take the context argument.

A common use case is where users are to be held to certain guidelines, while dirty data needs to be imported as is.

Cheers,
Stefan.

Related branches

Revision history for this message
Vo Minh Thu (thu) wrote :

Constraints should only depends on the actual data. If you call the constraints multiple times on the same data it must always give the same result and therefore cannot be influenced by context.

Changed in openobject-server:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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