Daily updates from Odoo
Thursday, February 12, 2026
1 change · master
Code cleanup and technical improvements
This update reorganizes how Odoo handles user sessions, moving the session store to its dedicated module for better organization and maintainability. This change improves the underlying architecture and resolves a technical inconsistency, ensuring smoother session handling within the system.
Original PR description
The session store is a global-ish variable that was set as a lazy property on the Application singleton. Now that http.py is split, it really doesn't make sense to have the session store inside Application inside router.py. It should be inside session.py, that's what this PR does. Changing the `@lazy` for a `@functools.lru_cache(1)` makes the decorated function better typing-wise, but makes it impossible to monkey-patch. As it was only monkey-patched inside `test_http`, we just adapted that module to use the real session store.