Skip to Content
Menu
This question has been flagged


I am getting the following error when upgrading (testing) from V14 to V16 on odoo.sh

I have a couple custom modules and I am willing to try upgrading without them. I tried uninstalling it and removing the code from the github (staging) branch. But I get different errors. Is there any way I can upgrade the database without upgrading the custom modules? And then I install the custom modules later?


​-------------------------------------------------------------------------------
Executed command: odoo-bin --stop-after-init --log-db wateerah-upgrade-4-8100619 -u ag_purchase_vendor_prices,cash_register_automation,customer_search_filter,e_tax_invoice_saudi_aio,eq_backdated_inventory_adjustment,eq_stock_move_cancel,import_stock_inventory_app,reformat_phonenumbers,report_extensions,sale_order_automation,sale_order_line_number,sale_order_line_price_history,smile_audit,smile_base_automation,smile_log,stock_last_purchase_price,stock_request,web_dialog_size,web_responsive --without-demo=all
-------------------------------------------------------------------------------
2023-04-29 04:10:01,319 4 INFO ? odoo: Odoo version 16.0
2023-04-29 04:10:01,319 4 INFO ? odoo: Using configuration file at /home/odoo/.config/odoo/odoo.conf
2023-04-29 04:10:01,319 4 INFO ? odoo: addons paths: ['/home/odoo/src/odoo/odoo/addons', '/home/odoo/data/addons/16.0', '/home/odoo/src/user', '/home/odoo/src/odoo/addons', '/home/odoo/src/enterprise', '/home/odoo/src/themes']
2023-04-29 04:10:01,319 4 INFO ? odoo: database: p_wateerah_upgrade_4_8100619@192.168.1.1:5432
2023-04-29 04:10:01,339 4 INFO ? odoo: Could not determine if database wateerah-upgrade-4-8100619 exists, skipping auto-creation: permission denied for table pg_database
2023-04-29 04:10:01,494 4 INFO ? odoo.addons.base.models.ir_actions_report: Will use the Wkhtmltopdf binary at /usr/local/bin/wkhtmltopdf
2023-04-29 04:10:01,841 4 INFO wateerah-upgrade-4-8100619 odoo\.modules\.loading:\ loading\ 1\ modules\.\.\.
2023\-04\-29\ 04:10:01,848\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ 1\ modules\ loaded\ in\ 0\.01s,\ 0\ queries\ \(\+0\ extra\)
2023\-04\-29\ 04:10:01,868\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ updating\ modules\ list
2023\-04\-29\ 04:10:01,872\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.addons\.base\.models\.ir_module:\ ALLOW\ access\ to\ module\.update_list\ on\ \[\]\ to\ user\ __system__\ \#1\ via\ n/a
2023\-04\-29\ 04:10:03,173\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.addons\.base\.models\.ir_module:\ ALLOW\ access\ to\ module\.button_upgrade\ on\ \['Electronic\ invoice\ KSA\ \-\ Sale,\ Purchase,\ Invoice,\ Credit\ Note\ \|\ Saudi\ Electronic\ Invoice\ with\ Base64\ TLV\ QR\ Code',\ 'Latest\ Vendor\ Price',\ 'Cash\ Register\ Automation',\ 'Report\ Extensions',\ 'Sale\ Order\ Automation',\ 'Cancel\ Stock\ Picking/Inventory\ Adjustment',\ 'Sale\ Order\ Line\ Number',\ 'Customer\ Search\ Filter',\ 'Inventory\ Adjustment\ Backdated',\ 'Reformat\ phone\ numbers\ ',\ 'Sale\ order\ line\ price\ history',\ 'Audit\ Trail',\ 'Costing\ method:\ Last\ Purchase\ Price',\ 'Stock\ Request',\ 'Web\ Responsive'\]\ to\ user\ __system__\ \#1\ via\ n/a
2023\-04\-29\ 04:10:03,174\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.addons\.base\.models\.ir_module:\ ALLOW\ access\ to\ module\.update_list\ on\ \['Electronic\ invoice\ KSA\ \-\ Sale,\ Purchase,\ Invoice,\ Credit\ Note\ \|\ Saudi\ Electronic\ Invoice\ with\ Base64\ TLV\ QR\ Code',\ 'Latest\ Vendor\ Price',\ 'Cash\ Register\ Automation',\ 'Report\ Extensions',\ 'Sale\ Order\ Automation',\ 'Cancel\ Stock\ Picking/Inventory\ Adjustment',\ 'Sale\ Order\ Line\ Number',\ 'Customer\ Search\ Filter',\ 'Inventory\ Adjustment\ Backdated',\ 'Reformat\ phone\ numbers\ ',\ 'Sale\ order\ line\ price\ history',\ 'Audit\ Trail',\ 'Costing\ method:\ Last\ Purchase\ Price',\ 'Stock\ Request',\ 'Web\ Responsive'\]\ to\ user\ __system__\ \#1\ via\ n/a
2023\-04\-29\ 04:10:04,116\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.addons\.base\.models\.ir_module:\ ALLOW\ access\ to\ module\.button_install\ on\ \[\]\ to\ user\ __system__\ \#1\ via\ n/a
2023\-04\-29\ 04:10:04,181\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ loading\ 151\ modules\.\.\.
2023\-04\-29\ 04:10:04,181\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ Loading\ module\ customer_search_filter\ \(2/151\)
2023\-04\-29\ 04:10:04,215\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.registry:\ module\ customer_search_filter:\ creating\ or\ updating\ database\ tables
2023\-04\-29\ 04:10:04,283\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ loading\ customer_search_filter/views/res_partner_views\.xml
2023\-04\-29\ 04:10:04,379\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.addons\.base\.models\.ir_module:\ module\ customer_search_filter:\ no\ translation\ for\ language\ ar_001
2023\-04\-29\ 04:10:04,389\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ Module\ customer_search_filter\ loaded\ in\ 0\.21s,\ 80\ queries\ \(\+80\ other\)
2023\-04\-29\ 04:10:04,389\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ Loading\ module\ smile_audit\ \(3/151\)
2023\-04\-29\ 04:10:04,412\ 4\ WARNING\ wateerah\-upgrade\-4\-8100619\ odoo\.api\.create:\ The\ model\ odoo\.addons\.smile_audit\.models\.audit_rule\ is\ not\ overriding\ the\ create\ method\ in\ batch
2023\-04\-29\ 04:10:04,461\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.registry:\ module\ smile_audit:\ creating\ or\ updating\ database\ tables
2023\-04\-29\ 04:10:04,791\ 4\ WARNING\ wateerah\-upgrade\-4\-8100619\ odoo\.addons\.base\.models\.ir_model:\ Two\ fields\ \(model,\ model_id\)\ of\ audit\.log\(\)\ have\ the\ same\ label:\ Model\.\ \[Modules:\ smile_audit\ and\ smile_audit\]
2023\-04\-29\ 04:10:04,901\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.schema:\ Keep\ unexpected\ index\ ir_model_model_index\ on\ table\ ir_model
2023\-04\-29\ 04:10:04,901\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.schema:\ Keep\ unexpected\ index\ ir_config_parameter_key_index\ on\ table\ ir_config_parameter
2023\-04\-29\ 04:10:04,901\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.schema:\ Keep\ unexpected\ index\ ir_module_module_name_index\ on\ table\ ir_module_module
2023\-04\-29\ 04:10:04,902\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.schema:\ Keep\ unexpected\ index\ decimal_precision_name_index\ on\ table\ decimal_precision
2023\-04\-29\ 04:10:04,939\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ loading\ smile_audit/security/ir\.model\.access\.csv
2023\-04\-29\ 04:10:05,296\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ loading\ smile_audit/views/audit_rule_view\.xml
2023\-04\-29\ 04:10:05,331\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ loading\ smile_audit/views/audit_log_view\.xml
2023\-04\-29\ 04:10:05,370\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.addons\.base\.models\.ir_module:\ module\ smile_audit:\ no\ translation\ for\ language\ ar_001
2023\-04\-29\ 04:10:05,385\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ Module\ smile_audit\ loaded\ in\ 1\.00s,\ 775\ queries\ \(\+779\ other\)
2023\-04\-29\ 04:10:06,140\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ Loading\ module\ web_responsive\ \(50/151\)
2023\-04\-29\ 04:10:06,240\ 4\ WARNING\ wateerah\-upgrade\-4\-8100619\ odoo\.models:\ The\ method\ ResUsers\.__init__\ doesn't\ match\ the\ new\ signature\ in\ module\ odoo\.addons\.web_responsive\.models\.res_users
2023\-04\-29\ 04:10:06,282\ 4\ WARNING\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.loading:\ Transient\ module\ states\ were\ reset
2023\-04\-29\ 04:10:06,286\ 4\ ERROR\ wateerah\-upgrade\-4\-8100619\ odoo\.modules\.registry:\ Failed\ to\ load\ registry
2023\-04\-29\ 04:10:06,288\ 4\ CRITICAL\ wateerah\-upgrade\-4\-8100619\ odoo\.service\.server:\ Failed\ to\ initialize\ database\ `wateerah\-upgrade\-4\-8100619`\.\
Traceback\ \(most\ recent\ call\ last\):
\ \ File\ "/home/odoo/src/odoo/odoo/service/server\.py",\ line\ 1299,\ in\ preload_registries
\ \ \ \ registry\ =\ Registry\.new\(dbname,\ update_module=update_module\)
\ \ File\ "",\ line\ 2,\ in\ new
\ \ File\ "/home/odoo/src/odoo/odoo/tools/func\.py",\ line\ 87,\ in\ locked
\ \ \ \ return\ func\(inst,\ \*args,\ \*\*kwargs\)
\ \ File\ "/home/odoo/src/odoo/odoo/modules/registry\.py",\ line\ 90,\ in\ new
\ \ \ \ odoo\.modules\.load_modules\(registry,\ force_demo,\ status,\ update_module\)
\ \ File\ "/home/odoo/src/odoo/odoo/modules/loading\.py",\ line\ 483,\ in\ load_modules
\ \ \ \ processed_modules\ \+=\ load_marked_modules\(cr,\ graph,
\ \ File\ "/home/odoo/src/odoo/odoo/modules/loading\.py",\ line\ 371,\ in\ load_marked_modules
\ \ \ \ loaded,\ processed\ =\ load_module_graph\(
\ \ File\ "/home/odoo/src/odoo/odoo/modules/loading\.py",\ line\ 206,\ in\ load_module_graph
\ \ \ \ registry\.setup_models\(cr\)
\ \ File\ "/home/odoo/src/odoo/odoo/modules/registry\.py",\ line\ 297,\ in\ setup_models
\ \ \ \ model\._setup_fields\(\)
\ \ File\ "/home/odoo/src/odoo/odoo/models\.py",\ line\ 2803,\ in\ _setup_fields
\ \ \ \ field\.setup\(self\)
\ \ File\ "/home/odoo/src/odoo/odoo/fields\.py",\ line\ 538,\ in\ setup
\ \ \ \ self\.setup_nonrelated\(model\)
\ \ File\ "/home/odoo/src/odoo/odoo/fields\.py",\ line\ 2879,\ in\ setup_nonrelated
\ \ \ \ comodel\ =\ model\.env\[self\.comodel_name\]
\ \ File\ "/home/odoo/src/odoo/odoo/api\.py",\ line\ 537,\ in\ __getitem__
\ \ \ \ return\ self\.registry\[model_name\]\(self,\ \(\),\ \(\)\)
TypeError:\ ResUsers\.__init__\(\)\ takes\ 3\ positional\ arguments\ but\ 4\ were\ given
2023\-04\-29\ 04:10:06,295\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo\.service\.server:\ Initiating\ shutdown
2023\-04\-29\ 04:10:06,295\ 4\ INFO\ wateerah\-upgrade\-4\-8100619\ odoo.service.server: Hit CTRL-C again or send a second signal to force the shutdown.
2023-04-29 04:10:06,295 4 INFO wateerah-upgrade-4-8100619 odoo.sql_db: ConnectionPool(used=0/count=0/max=16): Closed 2 connections
odoo-bin process returned error code 255. Please check upgrade.log

Avatar
Discard
Best Answer

Hi,

The way you want to work will cause data losses.
In general you use the following approach:
1. Create a new branch based on production
2. Migrate all custom code/apps to the new Odoo version
3. Flag the branch on Odoo.sh by clicking on the "Upgrade" tab and testing the upgrade
4. Odoo will try to migrate the whole database and in the end will ask for a new commit (Github code change/push) in orde to do the migration on that branch
5. Push a commit to your staging branch
6. Test the migration script and if all is well, first check the logs to see if there was any issue stopping the migration
7. Repeat until all is good
8. Do the same steps for the production database

Avatar
Discard
Related Posts Replies Views Activity
0
Jan 24
161
3
Mar 24
3375
1
Feb 24
1664
2
May 23
2527
3
Apr 23
2906