Any ideas as to what's going on here?
Odoo Server Error
Traceback (most recent call last): File "/opt/odoo/odoo-server/openerp/http.py", line 643, in _handle_exception return super(JsonRequest, self)._handle_exception(exception) File "/opt/odoo/odoo-server/openerp/http.py", line 680, in dispatch result = self._call_function(**self.params) File "/opt/odoo/odoo-server/openerp/http.py", line 316, in _call_function return checked_call(self.db, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/service/model.py", line 118, in wrapper return f(dbname, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/http.py", line 309, in checked_call result = self.endpoint(*a, **kw) File "/opt/odoo/odoo-server/openerp/http.py", line 959, in __call__ return self.method(*args, **kw) File "/opt/odoo/odoo-server/openerp/http.py", line 509, in response_wrap response = f(*args, **kw) File "/opt/odoo/odoo-server/addons/web/controllers/main.py", line 896, in call_button action = self._call_kw(model, method, args, {}) File "/opt/odoo/odoo-server/addons/web/controllers/main.py", line 884, in _call_kw return getattr(request.registry.get(model), method)(request.cr, request.uid, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/addons/base/module/module.py", line 459, in button_immediate_install return self._button_immediate_function(cr, uid, ids, self.button_install, context=context) File "/opt/odoo/odoo-server/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/addons/base/module/module.py", line 533, in _button_immediate_function registry = openerp.modules.registry.RegistryManager.new(cr.dbname, update_module=True) File "/opt/odoo/odoo-server/openerp/modules/registry.py", line 386, in new openerp.modules.load_modules(registry._db, force_demo, status, update_module) File "/opt/odoo/odoo-server/openerp/modules/loading.py", line 338, in load_modules loaded_modules, update_module) File "/opt/odoo/odoo-server/openerp/modules/loading.py", line 237, in load_marked_modules loaded, processed = load_module_graph(cr, graph, progressdict, report=report, skip_modules=loaded_modules, perform_checks=perform_checks) File "/opt/odoo/odoo-server/openerp/modules/loading.py", line 156, in load_module_graph _load_data(cr, module_name, idref, mode, kind='data') File "/opt/odoo/odoo-server/openerp/modules/loading.py", line 98, in _load_data tools.convert_file(cr, module_name, filename, idref, mode, noupdate, kind, report) File "/opt/odoo/odoo-server/openerp/tools/convert.py", line 851, in convert_file convert_xml_import(cr, module, fp, idref, mode, noupdate, report) File "/opt/odoo/odoo-server/openerp/tools/convert.py", line 938, in convert_xml_import obj.parse(doc.getroot(), mode=mode) File "/opt/odoo/odoo-server/openerp/tools/convert.py", line 801, in parse self.parse(rec, mode) File "/opt/odoo/odoo-server/openerp/tools/convert.py", line 804, in parse self._tags[rec.tag](self.cr, rec, de, mode=mode) File "/opt/odoo/odoo-server/openerp/tools/convert.py", line 708, in _tag_record id = self.pool['ir.model.data']._update(cr, self.uid, rec_model, self.module, res, rec_id or False, not self.isnoupdate(data_node), noupdate=self.isnoupdate(data_node), mode=self.mode, context=rec_context ) File "/opt/odoo/odoo-server/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_model.py", line 1138, in _update res_id = model_obj.create(cr, uid, values, context=context) File "/opt/odoo/odoo-server/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/api.py", line 354, in old_api result = method(recs, *args, **kwargs) File "/opt/odoo/odoo-server/addons/delivery/models/delivery_carrier.py", line 227, in create res = super(DeliveryCarrier, self).create(vals) File "/opt/odoo/odoo-server/openerp/api.py", line 248, in wrapper return new_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/models.py", line 4134, in create record = self.browse(self._create(old_vals)) File "/opt/odoo/odoo-server/openerp/api.py", line 248, in wrapper return new_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/api.py", line 490, in new_api result = method(self._model, cr, uid, *args, **old_kwargs) File "/opt/odoo/odoo-server/openerp/models.py", line 4190, in _create record_id = self.pool[table].create(cr, user, tocreate[table], context=context) File "/opt/odoo/odoo-server/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/addons/product/product.py", line 1197, in create product_id = super(product_product, self).create(cr, uid, vals, context=ctx) File "/opt/odoo/odoo-server/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/api.py", line 354, in old_api result = method(recs, *args, **kwargs) File "/opt/odoo/odoo-server/addons/mail/models/mail_thread.py", line 232, in create thread = super(MailThread, self).create(values) File "/opt/odoo/odoo-server/openerp/api.py", line 248, in wrapper return new_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/models.py", line 4134, in create record = self.browse(self._create(old_vals)) File "/opt/odoo/odoo-server/openerp/api.py", line 248, in wrapper return new_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/api.py", line 490, in new_api result = method(self._model, cr, uid, *args, **old_kwargs) File "/opt/odoo/odoo-server/openerp/models.py", line 4190, in _create record_id = self.pool[table].create(cr, user, tocreate[table], context=context) File "/opt/odoo/odoo-server/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/addons/stock_account/product.py", line 76, in create return super(product_template, self).create(cr, uid, vals, context=context) File "/opt/odoo/odoo-server/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/addons/product/product.py", line 690, in create product_template_id = super(product_template, self).create(cr, uid, vals, context=context) File "/opt/odoo/odoo-server/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/api.py", line 354, in old_api result = method(recs, *args, **kwargs) File "/opt/odoo/odoo-server/addons/mail/models/mail_thread.py", line 232, in create thread = super(MailThread, self).create(values) File "/opt/odoo/odoo-server/openerp/api.py", line 248, in wrapper return new_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/models.py", line 4134, in create record = self.browse(self._create(old_vals)) File "/opt/odoo/odoo-server/openerp/api.py", line 248, in wrapper return new_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/api.py", line 490, in new_api result = method(self._model, cr, uid, *args, **old_kwargs) File "/opt/odoo/odoo-server/openerp/models.py", line 4272, in _create tuple([u[2] for u in updates if len(u) > 2]) File "/opt/odoo/odoo-server/openerp/sql_db.py", line 141, in wrapper return f(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/sql_db.py", line 220, in execute res = self._obj.execute(query, params) ParseError: "null value in column "categ_id" violates not-null constraint DETAIL: Failing row contains (310, null, 1.00, null, 1, 0, 1, 1, null, 2016-09-01 11:35:23.722581, 1, t, null, null, null, 1, null, 1, null, null, null, 2016-09-01 11:35:23.722581, t, f, Free delivery charges, consu, null, 7, none, receive, t, manual, order). " while parsing /opt/odoo/odoo-server/addons/delivery/data/delivery_data.xml:12, near <record id="free_delivery_carrier" model="delivery.carrier"> <field name="name">Free delivery charges</field> <field name="fixed_price">0</field> <field name="free_if_more_than" eval="True"/> <field name="amount">1000</field> <field name="sequence">1</field> <field name="delivery_type">fixed</field> <field name="product_type">service</field> <field name="product_sale_ok" eval="False"/> <field name="partner_id" ref="res_partner_delivery"/> </record>
Ok, I've been able to get the module installed by editing the XML and adding the missing column. I've taken a guess and used 1, but I have no idea what it's referencing. My question now is; how has this happened? Is it another module has added the non-nullable column to the table? If so, it seems to me to be poor practise as you're bound to prevent other modules from being able to install.