-
Notifications
You must be signed in to change notification settings - Fork 80
[IMP] util/orm: recompute_fields add query parameter
#317
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
upgradeci skip |
7fca3a9 to
94ca49a
Compare
|
upgradeci retry with always only base account crm delivery helpdesk_sale_timesheet helpdesk_timesheet hr_attendance hr_expense hr_holidays hr_recruitment_extract l10n_in_sale l10n_it_edi l10n_mx_edi_stock loyalty mrp point_of_sale pos_sale project_enterprise purchase resource sale sale_project_forecast sale_renting sale_stock sale_subscription sale_timesheet_margin stock |
94ca49a to
8e304a7
Compare
In most cases when we pass a list of `ids` to `recompute_fields` we just run a query to get them. The main downside of this approach is when the list is too big: it can cause MemoryErrors. Instead we can let `recompute_fields` use a query to get the ids and take the necessary precautions to not fetch millions of entries all at once. As a nice side effect code becomes easier to review since we don't need to check the fetching of ids is done correctly.
8e304a7 to
a01bb83
Compare
|
upgradeci retry |
KangOl
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@robodoo r+


In most cases when we pass a list of
idstorecompute_fieldswe just run a query to get them. The main downside of this approach is when the list is too big: it can cause MemoryErrors. Instead we can letrecompute_fieldsuse a query to get the ids and take the necessary precautions to not fetch millions of entries all at once. As a nice side effect code becomes easier to review since we don't need to check the fetching of ids is done correctly.