Odoo Help


Does @api.depends recognize computed fields?

Juan Formoso
on 2/16/16, 3:31 AM 1,927 views

I have a problem in my code, a compute method is not triggered each time a computed field should trigger it.I put an example:


@api.depends('child_ids', 'child_ids.computed_field', 'child_ids.normal_field')

def compute_depending_field(self):


Each time child_ids.computed_field changes, @api.depends should trigger the compute_depending_field method, but this is not happening. However, when the other fields of the decorator change, the method is executed.

I did some tests with @api.depends depending on computed fields of one2many fields (like child_ids) and they are not triggering the methods.


Binary System Limited
On 4/19/18, 11:48 PM

If the "child_ids.computed_field" is non-stored field, it will not trigger compute method depending on it


Jignesh Mehta

--Jignesh Mehta--
| 6 5 8
Surat, India
--Jignesh Mehta--

- I have 3+ years of Industry Experience, specializing Odoo Development, Analysis, Customization, Implementation, Integration.
- I have done many Customization modules in Sale, Purchase, Point of Sale, Inventory, CRM and much more. Also Worked in the Odoo Themes like Business Theme or E-Commerce Theme.
- Develop Jewelery Manufacturing process from Scratch. It have more than 10 Department. Develop PDF and Excel reports for this project around 150 per format.

Jignesh Mehta
On 2/20/16, 1:50 AM

Hello Juan,

In the depends, you want to put those fields which is affected to your compute fields.

For Ex :- I have three fields, like weight, price and total and total is computed field to price and total so now i put weight and price in the depends not the total field.

Hope this will helps you.


About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

1 follower(s)


Asked: 2/16/16, 3:31 AM
Seen: 1927 times
Last updated: 4/19/18, 11:48 PM