diff options
| author | Raphael Collet <rco@odoo.com> | 2020-05-08 08:36:08 +0000 |
|---|---|---|
| committer | Raphael Collet <rco@odoo.com> | 2020-05-08 11:33:38 +0000 |
| commit | 5fc9b8c44acc424f4e365b4d492dda93c03ddfcf (patch) | |
| tree | 7d32dba84b838bf460661d6dad4b0b786dd61172 /addons/web/static/src | |
| parent | 12c6eba84463a7758bc79f05fb5a6a2508ae5ddc (diff) | |
[FIX] core: partial unlink in recordset
The following loop crashes on the second iteration:
for record in records:
record.display_name # access non-stored computed field
record.unlink() # delete record
The cache has been invalidated by `unlink` on the first iteration, so
the field is computed. The computation is done on the whole recordset,
which fails with a `MissingError` because of the first record. The fix
is to retry the recomputation on the single record in this case.
closes odoo/odoo#50910
X-original-commit: 7f33ebf528b1415452ce549e3329c3fe89be0ad8
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
Diffstat (limited to 'addons/web/static/src')
0 files changed, 0 insertions, 0 deletions
