Wednesday, December 13, 2023
2 changes · 17.0
Enhancements to existing features
This update optimizes how the system retrieves and displays project tasks, particularly when viewing projects with many completed tasks. By improving how the database searches for open tasks, the system now performs up to 10 times faster when loading project views with thousands of tasks, resulting in a noticeably snappier user experience.
Original PR description
## Description Indexes on a Selection field are never used in a `NOT IN` where clause, as PostgreSQL doesn't have the complementary values (in DB a Selection field is just a VarChar) to make use of an index on the field. The ORM currently doesn't invert `not in <selection>` -> `in <complement of selection>`. ## Benchmark Positive impact in the project modules all around, specially for long running projects where the proportion of "done" tasks are >90% of the project's task. On a populated project with 10k tasks, 200 of those are open, there were around 10x improvement on the requests linked to rendering the kanban view of the project. More elaborate benchmarks are available in the referenced task. ## Reference task-3576802 ## Related PR: https://github.com/odoo/odoo/pull/146120 Forward-Port-Of: odoo/enterprise#52689
Resolved issues and error corrections
This fix resolves a critical error in the Belgian CodaBox module that occurred when the Account Report module was not installed. The module was using a field from Account Report without properly declaring the dependency, causing the system to crash with a 500 error. The fix ensures the module correctly depends on Account Report so it functions properly in all installations.
Original PR description
The compute function '_compute_l10n_be_codabox_fiduciary_vat', depends on field 'account_representative_id' which is declared in the module account_report. There is no depends or transitive depends to this module, so it raises an 500 error when the module is not installed. This error has been introduced in https://github.com/odoo/enterprise/pull/49968