Skip to content

Commit 87a2757

Browse files
Gorashrco-odoo
authored andcommitted
[IMP] website: Introduce high-level cache for website pages
ormcache invalidation in test_02_homepage_tour_every_theme test. The configurator_apply method and various methods used for theme added on `ir.module.module` from website write directely on `ir.model.data` and update attachments, views, xmlids. They are missing invalidations of template ormcache and others. Adding a high-level cache revealed the problem, but this issue already exists, it impacts all template caches such as `website.page` and `ir.qweb`. see odoo/odoo#224487 see odoo/odoo#88276 closes #1164 X-original-commit: c0d05ff Related: odoo/odoo#229552 Related: odoo/enterprise#96044 Signed-off-by: Christophe Matthieu (chm) <[email protected]>
1 parent 8b04b6d commit 87a2757

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

test_themes/tests/test_crawl.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,11 @@ def test_02_homepage_tour_every_theme(self):
4949
Website = self.env['website']
5050
websites_themes = Website.get_test_themes_websites()
5151
for website in websites_themes:
52+
# TODO: remove this invalidation and invalidation in theme feature.
53+
# They are missing invalidations of template ormcache and others.
54+
# The configurator_apply method and various methods used for theme
55+
# added on `ir.module.module` from website write directly on
56+
# `ir.model.data` and update attachments, views, xmlids.
57+
self.env.registry.clear_cache('templates')
58+
5259
self.start_tour(f"/web?fw={website.id}", 'homepage', login='admin')

0 commit comments

Comments
 (0)