Thursday, August 27, 2026
8 changes · 19.0
Enhancements to existing features
This update adds dedicated UAE overtime work entry types for weekday, night, and overtime day work. It helps payroll teams calculate overtime pay more easily and consistently by using clearer overtime categories in salary rules.
Original PR description
Add UAE overtime work entry types (OVTWD, OVTWDN, OVTOD) to simplify overtime salary rule calculations using `worked_days['<code>'].amount`. Task: 6469393 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The UAE payroll module now uses the latest overtime calculation rules from a newer release. This helps payroll teams calculate regular, night, and day-off overtime more consistently in version 19.0.
Original PR description
Backport overtime salary rules (OVTWD, OVTWDN, OVTOD) from 19.4 to 19.0, updating the computation logic to directly use `worked_days['<CODE>'].amount`. Task:6469393
This update makes internal mail tests more resilient when running in parallel test environments. It prevents unusual test data from crashing the test suite, helping maintain smoother validation without changing customer-facing behavior.
Original PR description
If the value needs to be serialized for IPC (cough cough pytest-xdist) and a weirdo sets recordsets as message values, the serialization fails and the test suite crashes. Since this is just subtest identification it shouldn't be too much of an issue. Forward-Port-Of: odoo/odoo#284279 Forward-Port-Of: odoo/odoo#284178
The live chat settings now clarify that automatic chat opening only happens on larger screens. This helps teams avoid confusion when testing on phones or small screens, where visitors must tap the chat button manually.
Original PR description
The 'Open automatically' action only triggers the auto popup on larger screens (`ui.isSmall` is checked in `AutopopupService. allowAutoPopup`). On mobile/small viewports, only the chat button is shown and the visitor must tap it manually. The existing help text does not mention this, which could lead to confusion when the auto popup does not trigger during testing on mobile. Update the field's help text to explicitly state that automatic opening is limited to larger screens. opw-6459279 Forward-Port-Of: odoo/odoo#284785
The UAE localization setup now reuses one shared state mapping instead of rebuilding the same information repeatedly. This reduces small initialization overhead and keeps the implementation simpler, with no expected change to user-facing behavior.
Original PR description
This PR optimizes the `l10n_ae` module by eliminating repetitive code and improving performance during module initialization. The UAE state mapping used by `_get_ae_res_company` and…
This PR optimizes the `l10n_ae` module by eliminating repetitive code and improving performance during module initialization. The UAE state mapping used by `_get_ae_res_company` and `_get_ae_account_fiscal_position` was previously defined separately inside each method. As a result, the same dictionary was recreated on every function call, introducing unnecessary code duplication and runtime overhead. This PR extracts the mapping into a reusable module-level `_AE_STATE_MAPPING` constant. The template methods now reference this shared mapping and dynamically construct the corresponding XML IDs, avoiding repeated dictionary allocation and simplifying the implementation. ### Cause In `_get_ae_res_company` and `_get_ae_account_fiscal_position`, the UAE state mapping dictionary was recreated every time the methods were executed. Since these methods can be called repeatedly during chart of accounts template evaluation, this resulted in unnecessary allocations and duplicated code. ### Fix * Extract the UAE state mapping into a module-level `_AE_STATE_MAPPING` constant. * Reuse the shared mapping across template methods. * Dynamically construct the required XML IDs from the mapping. * Remove duplicated dictionary definitions from individual methods. * Reduce unnecessary object allocation during template evaluation. ### Benchmark The state mapping evaluation was benchmarked over 1,000,000 iterations: | Version | Execution Time | | ------- | -------------: | | Before | 0.0841s | | After | 0.0272s | This results in approximately **68% faster execution** for the benchmarked operation.
This change reduces unnecessary data loading when Odoo processes very large sets of records. It can lower memory use and improve reliability for heavy operations such as large reports, while keeping the existing behavior for smaller workloads.
Original PR description
This pr is a prototype proposing to not always fetch all fields if we have a lot of records. The idea is that reading all (prefetch) fields **for a few record** makes sense because it will be less…
This pr is a prototype proposing to not always fetch all fields if we have a lot of records.
The idea is that reading all (prefetch) fields **for a few record** makes sense because it will be less expensive to make a slightly bigger request than needed that having to make multiple request to the database (due to the ping)
In some cases, with **very large recordset**, prefetching all fields can be an issue
- memory consumption
- putting data in cache takes some time
In this case, we can improve performances by prefething only the needed fields, but this is fragile, can vary per module installed, ....
The idea behind this pull request is that it _could_ be less expensive to prefetch the field one by one, but for all records
In a minimal database we have 7000 ir.model.data, lets take 5000 of them
```python
env.invalidate_all()
start = env.cr.sql_log_count
for rec in env['ir.model.data'].search([], limit=5000):
rec.model
rec.name
env.cr.sql_log_count - start
```
Before this change, we would have 6 queries and all fields in cache,
-> 1 for the search
-> 5 to prefetch data, 1 per 1000 id
After this change we would have 7 queries and only the model and name field in cache.
-> 1 for the search
-> 2 to prefetch model and name on the first 1000 records
-> 4 to prefetch data of the 4000 remaining records
Note that this strategy could become slower if we need to prefetch a lot of fields, especially if some of those fields are needed in a place where the prefetch set is broken. If we have 1000 fields and read 10 records, we would go from 2 queries to 11 queries. The only additional query of the previous example is there to show the best possible case for a large recordset needing only a few fields.
If we decide to introduce that, it could be an opt-in behaviour (using the context) on some specific reports generation that tends to have memory error.Deleting accounts is made faster by adding supporting database indexes used during dependency checks. This reduces delays for businesses managing or cleaning up their accounting records, especially in larger databases.
Original PR description
Without these indexes, the foreign key check when deleting an account can take a long time.
Deleting accounts in German reports is now more efficient. The change adds database indexes that help the system confirm whether an account is referenced, reducing delays during account cleanup.
Original PR description
Without these indexes, the foreign key check when deleting an account can take a long time.