Ir al contenido
Menú
Se marcó esta pregunta

Context (anonymized):

# removed from code class XChild(models.Model): _name = 'x.child' parent_id = fields.Many2one('res.partner') class ResPartner(models.Model): _inherit = 'res.partner' child_ids = fields.One2many('x.child', 'parent_id')

I removed the model x.child and the field res.partner.child_ids from the code. I don’t need the old data.

Error: On server start or opening Contacts → KeyError: 'child_ids'.

Tried:

  • Deleted metadata: ir.model.fields(name='child_ids')
  • Removed view refs: ir.ui.view (arch_db ilike 'child_ids')
  • Dropped child table x_child
  • Removed actions/filters/rules/templates where domains/contexts/body mention child_ids
  • Removed ir.model.access/ir.rule for x.child


What’s the complete cleanup order to remove all references and fix the KeyError without uninstalling the module in Odoo 11?

Which places are commonly missed besides views—e.g., ir.actions.act_window (domain/context), ir.filters, ir.rule (domain_force), ir.actions.server, base.automation, mail.template, ir.translation, ir.model.data xml_ids for ir.model/ir.model.fields?

Any Odoo 11 gotchas (e.g., ir.cron has no args field) to avoid invalid-field errors while searching?

Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
2
ago 25
349
2
may 25
2190
0
mar 15
3611
0
jul 22
2608
2
jun 22
3573