-
-
Notifications
You must be signed in to change notification settings - Fork 707
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed bugs 2595 2665 are still showing #3888
Comments
do you have openupgrade logs in your full logs ? |
My log is exactly, exactly the same than #2595 |
Hi, when openupgrade, the full log is bigger. I mean, all the logs before the ERROR. |
You mean this kind? 023-05-24 15:04:00,431 3281 DEBUG my-db OpenUpgrade: -1 rows affected after 0:00:00.006821 running ALTER TABLE "account_bank_statement_import_ir_attachment_rel" DROP CONSTRAINT "account_bank_statement_import_account_bank_statement_impor_fkey" |
Ill reply myself, If i use --update all i have another error |
yes, that means that openupgrade is correctly detected. |
Well. I have no idea. I doubt that there is a bug in OpenUpgrade related to that topic, because the CI is green for |
Your DB seems incorrect in the source, having a reconcile model reference which doesn't exist. Not an OpenUpgrade bug. If you want more help, put a topic in the discussion part, but not giving more information won't help you to get people willing to help you. |
Probably, but im not the only with the same problem; information was enought to close the other exactly identical bug reports, but I got mine closed with a completely different answer. I'll find a solution and post it here, greets |
Previous issues (which aren't) were posted before anything was done, so the solution was: wait until done. Now yours seems an inconsistent DB, or maybe you are not running correctly OpenUpgrade. In any case, not something to be handled here, but on discussions. |
truncate account_payment_register cascade; solves the problem during migration, it seems a legacy table from very old openERP versions |
I copy paste from #2595 and #2665
I'm having trouble to upgrade my odoo 13 to 14. I have only few external module, but anyway, seems the core account module upgrade didn't pass. Apparently a foreign key reference try to use non existing table from account module while the module itself has those models. I tried various upgrade combination, but I'm not sure yet how to have those models applied to my existing database.
Impacted versions: 14.0
Steps to reproduce:
Current behavior:
The migration starts and after few dozen of seconds, the following error is displayed.
`
2021-02-25 13:51:58,202 6380 ERROR my-db odoo.sql_db: bad query: ALTER TABLE "account_reconcile_model_analytic_tag_rel" ADD FOREIGN KEY ("account_reconcile_model_line_id") REFERENCES "account_reconcile_model_line"("id") ON DELETE cascade
ERROR: column "account_reconcile_model_line_id" referenced in foreign key constraint does not exist
2021-02-25 13:51:58,209 6380 WARNING my-db odoo.modules.loading: Transient module states were reset
2021-02-25 13:51:58,219 6380 ERROR my-db odoo.modules.registry: Failed to load registry
2021-02-25 13:51:58,219 6380 CRITICAL my-db odoo.service.server: Failed to initialize database
my-db
.Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/odoo/service/server.py", line 1198, in preload_registries
registry = Registry.new(dbname, update_module=update_module)
File "/usr/lib/python3/dist-packages/odoo/modules/registry.py", line 89, in new
odoo.modules.load_modules(registry._db, force_demo, status, update_module)
File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 451, in load_modules
force, status, report, loaded_modules, update_module, models_to_check)
File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 348, in load_marked_modules
perform_checks=perform_checks, models_to_check=models_to_check
File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 198, in load_module_graph
registry.init_models(cr, model_names, {'module': package.name}, new_install)
File "/usr/lib/python3/dist-packages/odoo/modules/registry.py", line 418, in init_models
self.check_foreign_keys(cr)
File "/usr/lib/python3/dist-packages/odoo/modules/registry.py", line 496, in check_foreign_keys
sql.add_foreign_key(cr, table1, column1, table2, column2, ondelete)
File "/usr/lib/python3/dist-packages/odoo/tools/sql.py", line 170, in add_foreign_key
cr.execute(query.format(tablename1, columnname1, tablename2, columnname2, ondelete))
File "", line 2, in execute
File "/usr/lib/python3/dist-packages/odoo/sql_db.py", line 101, in check
return f(self, *args, **kwargs)
File "/usr/lib/python3/dist-packages/odoo/sql_db.py", line 298, in execute
res = self._obj.execute(query, params)
psycopg2.ProgrammingError: column "account_reconcile_model_line_id" referenced in foreign key constraint does not exist`
Expected behavior:
Having the upgrade running until the end of course.
Account migration script is already finished but error still shows
The text was updated successfully, but these errors were encountered: