{"action":"created","issue":{"url":"https://api.github.com/repos/OpenUpgrade/OpenUpgrade/issues/285","labels_url":"https://api.github.com/repos/OpenUpgrade/OpenUpgrade/issues/285/labels{/name}","comments_url":"https://api.github.com/repos/OpenUpgrade/OpenUpgrade/issues/285/comments","events_url":"https://api.github.com/repos/OpenUpgrade/OpenUpgrade/issues/285/events","html_url":"https://github.com/OpenUpgrade/OpenUpgrade/issues/285","id":72938914,"number":285,"title":"7 -> 8 error: constraint ir_ui_view_inherit_id_fkey","user":{"login":"welshjf","id":7895696,"avatar_url":"https://avatars.githubusercontent.com/u/7895696?v=3","gravatar_id":"","url":"https://api.github.com/users/welshjf","html_url":"https://github.com/welshjf","followers_url":"https://api.github.com/users/welshjf/followers","following_url":"https://api.github.com/users/welshjf/following{/other_user}","gists_url":"https://api.github.com/users/welshjf/gists{/gist_id}","starred_url":"https://api.github.com/users/welshjf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/welshjf/subscriptions","organizations_url":"https://api.github.com/users/welshjf/orgs","repos_url":"https://api.github.com/users/welshjf/repos","events_url":"https://api.github.com/users/welshjf/events{/privacy}","received_events_url":"https://api.github.com/users/welshjf/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-05-04T06:58:18Z","updated_at":"2015-05-04T09:07:44Z","closed_at":"2015-05-04T08:14:03Z","body":"Migrating a pretty simple installation: I'd just done basic company and user setup, installed the accounting module, and added a few test entries.\r\n\r\n```\r\nopenerp.sql_db: bad query: delete from ir_ui_view where id IN (257)\r\nTraceback (most recent call last):\r\n  File \"/home/jwelsh/.local/lib/python2.7/site-packages/openerp/sql_db.py\", line 234, in execute\r\n    res = self._obj.execute(query, params)\r\nIntegrityError: update or delete on table \"ir_ui_view\" violates foreign key constraint \"ir_ui_view_inherit_id_fkey\" on table \"ir_ui_view\"\r\nDETAIL:  Key (id)=(257) is still referenced from table \"ir_ui_view\".\r\n```\r\n\r\nThe constraint in question:\r\n```sql\r\nALTER TABLE ir_ui_view\r\n  ADD CONSTRAINT ir_ui_view_inherit_id_fkey FOREIGN KEY (inherit_id)\r\n      REFERENCES ir_ui_view (id) MATCH SIMPLE\r\n      ON UPDATE NO ACTION ON DELETE RESTRICT;\r\n```\r\n\r\nHere is the indicated record and the one that references it (hope this is vaguely legible; aligned mode output was worse):\r\n```\r\nid|model|type|arch|field_parent|priority|create_uid|create_date|write_date|write_uid|inherit_id|name|mode|active|model_data_id\r\n257|account.invoice.report|tree|<?xml version=\"1.0\"?>\r\n<tree colors=\"blue:state == 'draft';gray:state in ('cancel','paid');black:state in ('proforma','proforma2')\" create=\"false\" string=\"Invoices Analysis\">\r\n                <field name=\"date\" invisible=\"1\"/>\r\n                <field name=\"user_id\" invisible=\"1\"/>\r\n                <field name=\"year\" invisible=\"1\"/>\r\n                <field name=\"day\" invisible=\"1\"/>\r\n                <field name=\"month\" invisible=\"1\"/>\r\n                <field name=\"type\" invisible=\"1\"/>\r\n                <field name=\"company_id\" invisible=\"1\"/>\r\n                <field name=\"partner_id\" invisible=\"1\"/>\r\n                <field name=\"product_id\" invisible=\"1\"/>\r\n                <field name=\"uom_name\" invisible=\"not context.get('set_visible',False)\"/>\r\n                <field name=\"categ_id\" invisible=\"1\"/>\r\n                <field name=\"state\" invisible=\"1\"/>\r\n                <field name=\"period_id\" invisible=\"1\"/>\r\n                <field name=\"currency_id\" invisible=\"1\"/>\r\n                <field name=\"journal_id\" invisible=\"1\"/>\r\n                <field name=\"partner_bank_id\" invisible=\"1\"/>\r\n                <field name=\"date_due\" invisible=\"1\"/>\r\n                <field name=\"account_id\" invisible=\"1\"/>\r\n                <field name=\"account_line_id\" invisible=\"1\"/>\r\n                <field name=\"nbr\" sum=\"# of Lines\"/>\r\n                <field name=\"product_qty\" sum=\"Qty\"/>\r\n                <!-- <field name=\"reconciled\"  sum=\"# Reconciled\"/> -->\r\n                <field name=\"price_total\" sum=\"Total Without Tax\"/>\r\n            </tree>\r\n        ||16|1|2015-05-03 06:23:17.719048|2015-05-03 06:23:17.719048|1||account.invoice.report.tree|primary|t|\r\n458|account.invoice.report|tree|<?xml version=\"1.0\"?>\r\n<field name=\"partner_id\" position=\"after\">\r\n                    <field name=\"commercial_partner_id\" invisible=\"1\"/>\r\n                </field>\r\n            ||16|1|2015-05-03 06:23:33.778936|2015-05-03 06:23:33.778936|1|257|account.invoice.report tree|primary|t|\r\n(2 rows)\r\n```\r\n\r\nNot sure if this is a problem other than the error message. (Is there a way to tell in general if the upgrade was successful?)\r\n\r\nAnd by the way, thanks for all the work on this project! It makes me feel a lot better about choosing Odoo."},"comment":{"url":"https://api.github.com/repos/OpenUpgrade/OpenUpgrade/issues/comments/98643518","html_url":"https://github.com/OpenUpgrade/OpenUpgrade/issues/285#issuecomment-98643518","issue_url":"https://api.github.com/repos/OpenUpgrade/OpenUpgrade/issues/285","id":98643518,"user":{"login":"hbrunn","id":2563186,"avatar_url":"https://avatars.githubusercontent.com/u/2563186?v=3","gravatar_id":"","url":"https://api.github.com/users/hbrunn","html_url":"https://github.com/hbrunn","followers_url":"https://api.github.com/users/hbrunn/followers","following_url":"https://api.github.com/users/hbrunn/following{/other_user}","gists_url":"https://api.github.com/users/hbrunn/gists{/gist_id}","starred_url":"https://api.github.com/users/hbrunn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hbrunn/subscriptions","organizations_url":"https://api.github.com/users/hbrunn/orgs","repos_url":"https://api.github.com/users/hbrunn/repos","events_url":"https://api.github.com/users/hbrunn/events{/privacy}","received_events_url":"https://api.github.com/users/hbrunn/received_events","type":"User","site_admin":false},"created_at":"2015-05-04T09:07:44Z","updated_at":"2015-05-04T09:07:44Z","body":"those are issues with database_cleanup, please post them at https://github.com/OCA/server-tools/issues"}}