summaryrefslogtreecommitdiff
path: root/addons
diff options
context:
space:
mode:
authorXavier-Do <xdo@odoo.com>2020-02-18 17:08:46 +0000
committerXavier-Do <xdo@odoo.com>2020-02-19 11:15:09 +0000
commit7e9918dbe3e42caddbdf4ad8fe41a5124714ba13 (patch)
tree1c93c8afb6c553e2c962f3f18097c3840e851222 /addons
parent047e222373918c7b7ff1630c62bca6ec6a425132 (diff)
[FIX] core: improve get_files performances
On a standard odoo install, `MigrationManager._get_files` represent more than 4% of an install. This is because the legacy odoo/base/maintenance/migration path was added to upgrade.__path__ once by module, making the get_filed check 574^2 os.path.exists. This commit adds a check on initialize_sys_path to call it only once, and merge legacy path with upgrade-path management in order to benefit of the `up not in upgrade.__path__` check. This second part of the fix will also remove the local dir from the upgrades paths. A further improvement would be to fix MigrationManager in order to skip _get_file work on a fresh install, (wip by rco-odoo) closes odoo/odoo#45699 X-original-commit: 497330a695ed52a33f9c9b9c27b149446de0db29 Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
Diffstat (limited to 'addons')
0 files changed, 0 insertions, 0 deletions