summaryrefslogtreecommitdiff
path: root/doc/reference/javascript_reference.rst
diff options
context:
space:
mode:
authorAdrian Torres <adt@odoo.com>2020-05-12 09:33:54 +0000
committerRaphael Collet <rco@odoo.com>2020-05-12 12:24:46 +0000
commitbdd87051f6c793243040f5ec1e03ecbebe3ff5b6 (patch)
tree174faa6442d2f93d69ec1851a393431cc37b6c21 /doc/reference/javascript_reference.rst
parent17c89c0709169de2d51b0719a063a6d50539ebd3 (diff)
[FIX] base: allow removal of selection fields during dev
Let field F of model M be a Selection field. Before this commit, creating a database with field F, removing/renaming field F by changing its definition within the code then upgrading the database to reflect the changes would result in a registry crash because the field would still exist in the database but not in the ORM (memory), thus trying to fetch the field in DB from the memory would result in a KeyError. This is due to the fact that field renames / removals are not stable operations and should be handled with a migration script when upgrading an existing database, nevertheless this can be quite an annoying behavior while developing which is why this commit simply skips the processing of the field if it does not exist in memory. The ORM already foresees these cases and logs a warning to the developer saying that the field was deleted anyway but that it was only a partial delete and that it should be handled in a migration script in order for the change to be production ready. closes odoo/odoo#51099 X-original-commit: a54fecc35386f8e00018ff3d858b383d43f1dded Signed-off-by: Raphael Collet (rco) <rco@openerp.com> Signed-off-by: Adrian Torres (adt) <adt@odoo.com>
Diffstat (limited to 'doc/reference/javascript_reference.rst')
0 files changed, 0 insertions, 0 deletions