Migrating with modules that are new on 7.0 but absent on 6.1

Asked by Pedro Manuel Baeza

Hi, guys!

I have finally started to migrate DBs to 7.0 and I found one problem that I don't know how to fix. There are some modules on the new version (v7) that depend on non existing modules for v6.1 (for example, crm, that depends on base_status), so I can't upgrade this module on the first iteration. But when I try to install it accesing on the web interface of the running OpenUpgrade server, I don't have it on the module list, and I don't have also the possibility to update module list due to any abnormal migration of the user permissions (I had on 6.1 'Technical features' permission). I try to enter to the user to change this permission, but I get an error due to the lack of update of crm module, that modifies res.user view, so I'm in a vicious circle.

Is there any way to force updating the module list from server command line or to force installing the module despite it's not on the module list?

Thank you.

Question information

Language:
English Edit question
Status:
Answered
For:
OpenUpgrade Server Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Stefan Rijnhart (Opener) (stefan-opener) said :
#1

Hi Pedro,

correct me if I'm wrong but doesn't an "--update all" take care of refreshing the module dependencies? There is a way of forcing a dependency in the server config file:

[openupgrade]
forced_deps = {'crm': ['base_status']}

But this is not meant to replace the regular module dependencies. You should check out why OpenERP/OpenUpgrade does not seem to do that.

Revision history for this message
Pedro Manuel Baeza (pedro.baeza) said :
#2

Thank for the quick reply, Stefan,

I'm not getting the automatic dependency by any way. I always get this error, nevertheless the number of passes I try with --update=all:

2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module account_analytic_default: Unmet dependencies: sale_stock
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module sale_journal: Unmet dependencies: sale_stock
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module l10n_es_partner: Unmet dependencies: l10n_es_toponyms
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module nan_account_invoice_sequence: Unmet dependencies: l10n_es_account_invoice_sequence
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module l10n_es_toponyms: Unmet dependencies: base_location
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module project: Unmet dependencies: base_status
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module sale_crm: Unmet dependencies: crm
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module account_analytic_plans: Unmet dependencies: account_analytic_default
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module base_calendar: Unmet dependencies: base_status
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module sale_order_dates: Unmet dependencies: sale_stock
2014-01-08 23:29:32,953 11410 ERROR pmbr openerp.modules.graph: module crm: Unmet dependencies: base_status, base_calendar
2014-01-08 23:29:32,953 11410 WARNING pmbr openerp.modules.graph: Some modules were not loaded.

Revision history for this message
Stefan Rijnhart (Opener) (stefan-opener) said :
#3

Hi Pedro,

this problem is new to us, so it may be something to do with your addons path. Can you post the full logs in DEBUG level, and the full command that you run?

Revision history for this message
Pedro Manuel Baeza (pedro.baeza) said :
#4

Hi, Stefan, this is the output (I have cut recurrent message about deleting account.account.template stuff, because in Spain, we have a lot of accounts in our chart)

http://tny.cz/3a7f7f98

As a summary of your questions, I have in the addons path:

- OpenUpgrade server addons folder (for base module).
- OpenUpgrade addons folder
- Some community modules for v7 (with no migration scripts, only to avoid more warnings).
- Some custom modules (the same of the previous point applies here)
- OCB web addons (for web access).

I started migration launching OpenUpgrade server with parameter --update=all:

openupgrade/server/openerp-server --config=openupgrade.conf --update=all

In openupgrade.conf, I have typical parameters db_user, db_password, admin_passwd and the addons_path mentioned before.

Thanks for your help.

Regards.

Revision history for this message
Holger Brunn (Therp) (hbrunn) said :
#5

Hi Pedro,

I can't see the line
"updating modules list"
in the log file, so this can't work.

Things to try:
Usually, I give the database directly for an upgrade with
--database=pmbr
on the command line in your case. (that's a somewhat wild guess, but worth trying I think)

If that doesn't work, use
--init=base
and see if that improves stuff.

Revision history for this message
Pedro Manuel Baeza (pedro.baeza) said :
#6

Hi, Stefan and Holger,

I think the key is that the module list is not updated, because I could enter to the web client with the semi-migrated DB and make a module list update, and then run again migration, continuing without complaining about unmet dependencies.

I have now another error on CRM module migration (migrate_partners method on post-migration, trying to migrate partner_id in crm.meeting and it doesn't exists), but this is another thing that I'm going to try to handle.

We can consider this question as solved, but the problem is still there (maybe a design flaw?).

Regards.

Revision history for this message
Holger Brunn (Therp) (hbrunn) said :
#7

Yes, the fact the the module list is not updated is indeed the problem. Could you try giving him the database on the commandline as I wrote before?

Revision history for this message
Pedro Manuel Baeza (pedro.baeza) said :
#8

Hi, Holger,

Giving database on the command line (and also --init=base) I don't get even that migration starts, so I'm afraid that doesn't work. I have continued with migration for now with the trick I have commented, so if you want we can close this question.

Regards.

Revision history for this message
Omar OUHARI (omar-ouhari) said :
#9

Hi,
I have the same issue and I got this line in log:

File "~/OpenUpgrade-9.0/openerp/addons/base/migrations/9.0.1.3/post-migration.py", line 117, in migrate
    openupgrade.convert_field_to_html(cr, table_name, openupgrade.get_legacy_name(old), old)
  File "/usr/local/lib/python2.7/dist-packages/openupgradelib/openupgrade.py", line 1101, in convert_field_to_html
    'table': table,
TypeError: not enough arguments for format string

My config file is:
[options]
admin_passwd = xxxxx
db_host = localhost
db_password = odoo
db_port = 5432
db_user = odoo
addons_path = /opt/odoo/OpenUpgrade-9.0/openerp/addons,/opt/odoo/OpenUpgrade-9.0/addons

[openupgrade]
forced_deps = {'crm': ['base_setup']}

And I run this command line:
openupgrade/server/openerp-server --config=upgrade_cfg.conf --database=my_db --update=all --stop-after-init

Any help please:

Can you help with this problem?

Provide an answer of your own, or ask Pedro Manuel Baeza for more information if necessary.

To post a message you must log in.