From 9d2b18f047d1108cb9ab08ef18e6643666773370 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Bidoul?= Date: Thu, 14 Mar 2024 09:57:49 +0100 Subject: [PATCH] [FIX] core: don't fail on bad version for uninstallable addons When an addon has an invalid version but is not installable, there is no need to error out. This situation typically happens when unmigrated modules are present in the addons path. closes odoo/odoo#157657 Signed-off-by: Christophe Simonis (chs) --- odoo/modules/module.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/odoo/modules/module.py b/odoo/modules/module.py index f3b074fe6f7..2a1130b7313 100644 --- a/odoo/modules/module.py +++ b/odoo/modules/module.py @@ -348,7 +348,8 @@ def load_manifest(module, mod_path=None): try: manifest['version'] = adapt_version(manifest['version']) except ValueError as e: - raise ValueError(f"Module {module}: invalid manifest") from e + if manifest.get("installable", True): + raise ValueError(f"Module {module}: invalid manifest") from e manifest['addons_path'] = normpath(opj(mod_path, os.pardir)) return manifest