queue icon indicating copy to clipboard operation
queue copied to clipboard

Missing openupgradelib dependency

Open HugoCLU opened this issue 6 months ago • 1 comments

We're migrating on Odoo(.sh) 16.0 to 18.0 and this happened (error below). I tried to add openupgradelib in my requirements.txt in my repo and it doesn't solve it. It's from queue_job/migrations/18.0.1.0.0 - 3383dbd Can you add the dependency openupgradelib in the requirements.txt please ?

Failed to initialize database X. Traceback (most recent call last): File "/home/odoo/src/odoo/odoo/modules/migration.py", line 236, in exec_script mod = load_script(pyfile, name) ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/odoo/src/odoo/odoo/modules/migration.py", line 54, in load_script spec.loader.exec_module(module) File "", line 995, in exec_module File "", line 488, in _call_with_frames_removed File "/home/odoo/src/user/OCA/queue/queue_job/migrations/18.0.1.0.0/pre-migrate.py", line 1, in from openupgradelib import openupgrade ModuleNotFoundError: No module named 'openupgradelib'

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/home/odoo/src/odoo/odoo/service/server.py", line 1361, in preload_registries registry = Registry.new(dbname, update_module=update_module) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/decorator.py", line 232, in fun return caller(func, *(extras + args), **kw) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/odoo/src/odoo/odoo/tools/func.py", line 97, in locked return func(inst, *args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/odoo/src/odoo/odoo/modules/registry.py", line 129, in new odoo.modules.load_modules(registry, force_demo, status, update_module) File "/home/odoo/src/odoo/odoo/modules/loading.py", line 480, in load_modules processed_modules += load_marked_modules(env, graph, ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/odoo/src/odoo/odoo/modules/loading.py", line 365, in load_marked_modules loaded, processed = load_module_graph( ^^^^^^^^^^^^^^^^^^ File "/home/odoo/src/odoo/odoo/modules/loading.py", line 182, in load_module_graph migrations.migrate_module(package, 'pre') File "/home/odoo/src/odoo/odoo/modules/migration.py", line 222, in migrate_module exec_script(self.cr, installed_version, pyfile, pkg.name, stage, stageformat[stage] % version) File "/home/odoo/src/odoo/odoo/modules/migration.py", line 238, in exec_script raise ImportError('module %(addon)s: Unable to load %(stage)s-migration file %(file)s' % dict(locals(), file=pyfile)) from e ImportError: module queue_job: Unable to load pre-migration file /home/odoo/src/user/OCA/queue/queue_job/migrations/18.0.1.0.0/pre-migrate.py 2025-08-04 10:14:00,271 74 INFO ? odoo.modules.loading: loading 1 modules...

HugoCLU avatar Aug 04 '25 10:08 HugoCLU

Hi @HugoCLU Were you able to resolve this error?

AnaBarrero avatar Nov 19 '25 19:11 AnaBarrero