[FIX] core: keep links in addons_path

resolving the links may block reading static files if real path
doesn't belong to addons_path.

The problem is introduced on refactoring of the `load_manifest` function
https://github.com/odoo/odoo/commit/2e29a9350306fd94fff19bc02821d7e7ab9c6f8b

closes odoo/odoo#82081

Signed-off-by: Raphael Collet <rco@odoo.com>
This commit is contained in:
Ivan Yelizariev
2022-01-24 12:02:39 +00:00
parent 749c57c397
commit bd534c1861
+2 -2
View File
@@ -12,7 +12,7 @@ import pkg_resources
import re
import sys
import warnings
from os.path import join as opj, realpath
from os.path import join as opj, normpath
import odoo
import odoo.tools as tools
@@ -386,7 +386,7 @@ def load_manifest(module, mod_path=None):
manifest['auto_install'] = set(manifest['depends'])
manifest['version'] = adapt_version(manifest['version'])
manifest['addons_path'] = realpath(opj(mod_path, os.pardir))
manifest['addons_path'] = normpath(opj(mod_path, os.pardir))
return manifest