Ran
|
Jobs
1
|
Files
0
|
Run time
–
|
Badge
Embed ▾
README BADGES
|
travis-ci
[FIX] let add_fields() work for Odoo <= v8 In those versions, [there is a required column called `select_level`][1] whose [default value is `"0"`][2]. I'm adding it to `add_fields()` so it doesn't crash when trying to use it in those versions. The crash looks like this: ``` 2020-03-12 03:48:38,493 1 ERROR prod openerp.sql_db: bad query: INSERT INTO ir_model_fields ( model_id, model, name, field_description, ttype, state ) VALUES ( 117, 'product.template', 'pack', 'OU', 'bool', 'base' ) RETURNING id Traceback (most recent call last): File "/opt/odoo/custom/src/odoo/openerp/sql_db.py", line 247, in execute res = self._obj.execute(query, params) IntegrityError: null value in column "select_level" violates not-null constraint DETAIL: Failing row contains (9885, product.template, 117, pack, null, null, OU, bool, base, null, f, null, f, null, null, null, null, null, null, null, null, null, null, null, null, null). 2020-03-12 03:48:38,493 1 ERROR prod OpenUpgrade: Error after 0:00:00.000372 running INSERT INTO ir_model_fields ( model_id, model, name, field_description, ttype, state ) VALUES ( 117, 'product.template', 'pack', 'OU', 'bool', 'base' ) RETURNING id 2020-03-12 03:48:38,493 1 ERROR prod OpenUpgrade: product_pack: error in migration script product_pack/migrations/8.0.1.0.0/pre-migration.py: IntegrityError('null value in column "select_level" violates not-null constraint\nDETAIL: Failing row contains (9885, product.template, 117, pack, null, null, OU, bool, base, null, f, null, f, null, null, null, null, null, null, null, null, null, null, null, null, null).\n',) 2020-03-12 03:48:38,493 1 ERROR prod OpenUpgrade: null value in column "select_level" violates not-null constraint ``` [1]: https://github.com/odoo/odoo/blob/9e8f70e48/openerp/addons/base/ir/ir_model.py#L261 [2]: ... (continued)
ID | Job ID | Ran | Files | Coverage | |
---|---|---|---|---|---|
1 | 707.1 | 0 | Travis Job 707.1 |
Coverage | ∆ | File | Lines | Relevant | Covered | Missed | Hits/Line |
---|