Daily updates from Odoo
Tuesday, May 5, 2026
14 changes · 18.0
Resolved issues and error corrections
This update resolves an issue where strict XML validators (like those for German XRechnung) were rejecting invoices due to extra whitespace in the generated XML attachments. The fix removes unnecessary whitespace during XML generation, ensuring compatibility with these validators and enabling successful electronic invoicing. This prevents invoice rejection and ensures compliance with German regulations.
Original PR description
### Issue: Some strict validators, such as the German XRechnung validator, reject generated documents because the `EmbeddedDocumentBinaryObject` contains leading and trailing whitespace ### Cause:…
### Issue: Some strict validators, such as the German XRechnung validator, reject generated documents because the `EmbeddedDocumentBinaryObject` contains leading and trailing whitespace ### Cause: Before 18.4, `_postprocess_invoice_ubl_xml()` used f-strings to generate the XML content With this formatting, the result of: `base64.b64encode(attachment_values['raw']).decode()` was indented together with the XML block, introducing unwanted whitespace and line breaks inside `EmbeddedDocumentBinaryObject` ### Steps to reproduce: - Install `l10n_de` and switch to the DE Company - In Settings, enable Peppol and Activate Electronic Invoicing - Create and confirm an Invoice (Customer: DE Company, any product line with tax) - Send the invoice via Peppol - Check the generated XML attachment ### Before the fix: The XML contains formatted content such as: ```xml <cbc:EmbeddedDocumentBinaryObject mimeCode="application/pdf" filename="INV_2026_00005.pdf"> content </cbc:EmbeddedDocumentBinaryObject> ``` This formatting introduces leading/trailing whitespace and may be rejected by strict validators. ### After the fix: The XML is generated without extra whitespace: ```xml <cbc:EmbeddedDocumentBinaryObject mimeCode="application/pdf" filename="INV_2026_00005.pdf">content</cbc:EmbeddedDocumentBinaryObject> ``` opw-6121616
This update fixes an error in how VAT carryover reimbursements are calculated when generating VAT returns. Previously, incorrect ratios were used, leading to inaccurate reimbursement move amounts. The fix ensures the correct calculation of these amounts, improving financial reporting accuracy.
Original PR description
When generating a VAT return with an unclaimed tax amount carried to the next month, the carryover reimbursement move amounts are computed with an incorrect ratio. Steps to reproduce: - Create and…
When generating a VAT return with an unclaimed tax amount carried to the next month, the carryover reimbursement move amounts are computed with an incorrect ratio. Steps to reproduce: - Create and post a bill in May containing a VAT amount. - Create and post a bill in June containing a VAT amount. - Create a VAT return for May to carry over the VAT amount to the next month. - Create a VAT return for June, requesting the full VAT amount to be reimbursed. - Validate and send the June VAT return. - Check the generated reimbursement move Issue: Line values does not correspond to anything real/tangible. It occurs because when computing the ratio for the move we check the last tax report entry, where we find the amount of tax from the past months and a line balancing the last month that should not be taken into account. The "Balance tax current account (receivable)" line from the tax closing entry is mistakenly picked up as a tax carried forward line, throwing off the amounts. opw-5961836
This update resolves a crash in the website event editor that occurred when the event was set as the homepage. The fix adds a default return value to ensure correct event ID retrieval, preventing the editor from failing to load. This ensures a stable and functional experience for users managing their events.
Original PR description
**Description of the issue/feature this PR addresses:** The `WebsiteEvent._getEventObjectId` method lacks a specific match case for the root directory, causing event ID retrieval to fail on the…
**Description of the issue/feature this PR addresses:** The `WebsiteEvent._getEventObjectId` method lacks a specific match case for the root directory, causing event ID retrieval to fail on the homepage. In order to resolve this, I've implemented a default return of 0 when the URL pattern matching fails [following the pattern established by later revisions of this code](https://github.com/odoo/odoo/blob/2199f71070ce3e9a4717eb6b750c14485406f7aa/addons/website_event/static/src/website_builder/event_page_option_plugin.js#L67). **Steps to reproduce bug:** 1. Create an event website 2. Create an event and visit it 3. On the page click Site > Properties 4. Enable `Is Homepage` 5. Return to the homepage of the application and open the editor https://drive.google.com/file/d/1OpCUAp4LJKqkoStciWeJEGVVlR3qpw1R/view?usp=drive_link **Current behavior before PR:** https://drive.google.com/file/d/1c7ACqaQx03mePzJSV_RoPn8mlLWSMa1I/view?usp=drive_link **Desired behavior after PR is merged:** https://drive.google.com/file/d/1L3Ne9h6-yB3v7VbXipjly9OrDSkZvDOu/view?usp=drive_link opw-6101680
This update fixes an issue where changing the delivery date for Hungarian invoices caused incorrect journal entries due to outdated exchange rates. The fix ensures that the most recent exchange rate is consistently applied, preventing financial imbalances and improving accuracy in financial reporting. This impacts how taxes are calculated on invoices.
Original PR description
### Issue: When changing the delivery date (used as the Hungarian exchange rate date), some journal lines could be recomputed incorrectly, leading to unbalanced entries ### Cause:…
### Issue: When changing the delivery date (used as the Hungarian exchange rate date), some journal lines could be recomputed incorrectly, leading to unbalanced entries ### Cause: `expected_currency_rate` was recomputed when `delivery_date` changed, but the new value was never automatically applied In addition, after https://github.com/odoo/odoo/pull/225407, `_sync_tax_lines` partially updated the lines: https://github.com/odoo/odoo/blob/f5501e5c8dcf60444077912db4c87e7a3f2654a6/addons/account/models/account_move.py#L3029-L3031 https://github.com/odoo/odoo/blob/f5501e5c8dcf60444077912db4c87e7a3f2654a6/addons/account/models/account_move.py#L1633-L1637 These methods reapply the previous tax rate, causing base and tax lines to be updated inconsistently As a result, when the base amount increases, the tax amount decreases, and vice versa ### Steps to reproduce: - Install `l10n_hu_edi` and `accountant` with demo data, then switch to the `HU company` - Go to Currencies → USD and add two rates: April 5: HUF per Unit = 100 April 6: HUF per Unit = 150 - Create an Invoice: (Any customer, Currency: USD, Line: Price = 1000, Tax = 27%) - Open the Journal Items and duplicate the browser tab for comparison - In the duplicated tab, change the Delivery Date to April 5 and save - Change the Delivery Date back to today and compare both tabs ### Before the fix: The values differ between both tabs because the tax lines keeps the old exchange rate opw-5801126
This update enhances the speed and efficiency of our appointment scheduling system by adding crucial database indexes. These indexes help prevent issues during automatic database cleanup (garbage collection), ensuring smoother operation and faster response times. This primarily impacts the appointment module and related workflows.
Original PR description
appointment.invite model has a GC. We should therefore check FK linking that model has a 'btree_not_null' index to avoid issues when running the garbage collect. TAsk-
This update fixes a bug that prevented purchase order matching when invoice lines included UoM information but lacked a corresponding product. The fix avoids unnecessary UoM conversions, resolving the 'UoM categories differ' error and ensuring accurate purchase order processing. This improves the reliability of our invoicing and purchasing workflows.
Original PR description
Steps
---------
1. Install Purchase and Accounting
2. Create a Bill
a. Add a line with no product and an UoM
3. Hit the Purchase matching button in the header
-> Error: the UoM categories differ
Problem
---------
PO matching fails if there is an invoice line with an UoM but no product
because it will try to convert the UoM and Quantity on the line to the
one UoM of the product. Since there is no product, the categories differ
which makes the conversion fail.
Solution
---------
Don't convert when there is no product.
opw-6109513
opw-6085388
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prThis update corrects a bug where users were incorrectly denied access to manufacturing orders due to analytic account restrictions. The fix ensures access is only blocked when the analytic line is associated with a valid timesheet entry, preventing unnecessary errors and improving user workflow. This resolves a conflict between modules.
Original PR description
Steps to reproduce the bug: - Log in as Mitchel Admin - Create a storable product “P1” - Create a bill of materials: - Component: 2 units - Miscellaneous > Project: - Select any project - Create a…
Steps to reproduce the bug:
- Log in as Mitchel Admin
- Create a storable product “P1”
- Create a bill of materials: - Component: 2 units - Miscellaneous > Project: - Select any project
- Create a manufacturing order:
- Select the BoM
- Confirm the MO
- Set Qty to Produce to 1 unit → an analytic account is created
- Set the following access rights for Marc Demo:
- Accounting: Administrator - Timesheets: User (Own timesheets only) - MRP: User
- Log in as Marc Demo
- Open the MO created by Mitchel Admin
- Try to update the Qty to Produce to 2
Problem:
A user error is raised:
"You cannot access timesheets that are not yours."
→ The restriction is applied even if the analytic line is not a timesheet entry.
Solution:
Restrict access only if the analytic line corresponds to a timesheet entry.
We cannot use the `is_timesheet`` field because it is implemented in the
`timesheet_grid`` module, and the `hr_timesheet` module does not depend
on it.
opw-4724262This update resolves a bug that allowed users to incorrectly return more items than were picked up in rental orders. By making the 'delivered' and 'returned' quantity fields read-only when the rental transfer feature is active, the system now prevents these data inconsistencies, ensuring accurate rental tracking and order management.
Original PR description
Steps to reproduce: - Enable the “Rental Transfers” option in settings - Create a rental product “P1” and update its quantity on hand to 10 units - Create a rental order with 10 units of P1 - Confirm the order → The delivery is created and marked as done, and the return picking is also created with 10 units reserved - Manually update the delivered and returned quantities on the sale order line - Create another delivery order Issue: A user error is raised: "The operation cannot be completed: You cannot return more than what has been picked up." Cause: The fields `qty_delivered` and `qty_returned` were editable even when the “Rental Transfers” feature was enabled, allowing inconsistent data entry. Solution: Make both fields readonly when the “Rental Transfers” option is enabled. opw-5126656
This update fixes a potential issue where multiple maintenance requests could block the same work center simultaneously, leading to scheduling conflicts. The change adds a validation step to ensure no overlapping maintenance blocks are created, improving the reliability of maintenance scheduling and preventing disruptions to operations.
Original PR description
Steps to reproduce: - Create a work center "WC1" - Create a maintenance request with: - For: Work Center - Work Center: WC1 - Block Work Center: True - Scheduled Date: Dec 30, 4:00 PM - Scheduled End: Dec 30, 5:00 PM - Save the record - Create another maintenance request with the same parameters Problem: It is currently possible to create multiple maintenance requests that block the same work center over the same time period. No validation is performed to check whether the work center is already blocked for the selected dates. Solution: - Add an explicit overlap check on maintenance requests that block a work center - Prevent creation or update when another non-done maintenance request already blocks the same work center during the same time slot - Perform the validation before generating calendar leaves to enforce the business rule at the data level opw-5065874
A recent update caused manufacturing orders with complex Bill of Materials (BoMs) – those with more than 40 components – to incorrectly process only the initial 40. This update fixes this issue, ensuring that all BoM components are accurately reflected in the manufacturing order moves. This prevents errors and ensures accurate tracking of materials.
Original PR description
Bug introduced in: https://github.com/odoo/odoo/commit/14d3893c763f6413581e7f36099cee0adb2caa83 Steps to reproduce the bug: - Create a BoM with more than 40 components - Create a manufacturing order with this BoM Problem: Only the first 40 components are taken into account and their moves are created; the remaining ones are not created. opw-6186544 Forward-Port-Of: odoo/odoo#262692
This update fixes an issue where users were incorrectly directed to the standard document form when opening linked documents through Studio. Now, when a document is linked via a Many2One field, the user will automatically open the relevant Kanban or List view, allowing them to directly preview and navigate the document.
Original PR description
Problem: When opening a linked `documents.document` record from a Many2One field added via Studio, the user is redirected to the standard form view. This is problematic because the form view does not allow the user to preview the actual document or navigate into it if the record is a folder. Solution: override `get_formview_action` to open the Kanban/List/Activity views. task-6068437
This update fixes an issue where subscription delivery dates were incorrectly displayed as the previous day due to timezone differences. The fix ensures delivery dates are accurately calculated based on the company's timezone, resolving a scheduling discrepancy for subscription products. This improves the reliability of delivery planning.
Original PR description
Steps to reproduce 1. Set the company's partner timezone to a negative UTC offset (e.g. America/Argentina/Buenos_Aires, UTC-3). 2. Create a sale order for a storable subscription product and confirm…
Steps to reproduce 1. Set the company's partner timezone to a negative UTC offset (e.g. America/Argentina/Buenos_Aires, UTC-3). 2. Create a sale order for a storable subscription product and confirm it. 3. Open the generated delivery order and check its Scheduled Date. Issue The scheduled date on the first delivery renders as the previous day. `_prepare_procurement_values` writes `date_planned` as `current_period_start`, which is a plain `fields.Date` value (https://github.com/odoo/enterprise/blob/ba41d7de3c0474286e3e9319710fdacfb95d3e2c/sale_subscription_stock/models/sale_order_line.py#L156). When a `date` is stored in the `Datetime` column `stock.move.date`, Odoo anchors it at midnight UTC; in any negative-offset timezone this renders as the previous day (e.g. `2022-03-02 00:00 UTC` shows as `2022-03-01 21:00` in UTC-3). The non-subscription path does not hit this because it resolves `date_planned` through `_expected_date()`, which returns `order_id.date_order` — a full `Datetime` set to `fields.Datetime.now()` at confirmation (https://github.com/odoo/odoo/blob/996702b0d5c518db2ac6f0b144e7835b27c29736/addons/sale/models/sale_order_line.py#L1398). The same midnight-UTC drift also affects later recurrences, where `current_period_start` falls back to `last_invoice_date` — another `Date`. Solution Split the two cases explicitly: - First delivery (`last_invoice_date` unset): set `date_planned` to `order_id.date_order`, matching the non-subscription flow. - Subsequent deliveries: localize `last_invoice_date` at `00:00` in the company timezone before converting back to UTC, reusing the pattern already applied to reordering rules (https://github.com/odoo/odoo/blob/20a0eee2d03293564320c268252a0353781d99ea/addons/stock/models/stock_orderpoint.py#L722). opw-6133831
This update fixes an issue where payment reminders weren't being sent to newly created duplicate subscriptions. The root cause was a shared 'last_reminder_date' field preventing new reminders from being triggered. The fix sets this field to 'false' for duplicate subscriptions, ensuring reminders are sent as expected.
Original PR description
Payment reminders are not sent to the duplicate of a subscription when a reminder has already been sent for the original subscription Steps to reproduce: 1. Install Subscriptions 2. Create a new…
Payment reminders are not sent to the duplicate of a subscription when a reminder has already been sent for the original subscription Steps to reproduce: 1. Install Subscriptions 2. Create a new subscription for customer Acme Corporation with product Office Cleaning Service (SUB), a Monthly recurring plan and in the Other Info tab, set the subscription Start Date to one week ago 3. Confirm the subscription 4. Go to Scheduled Actions and run the action "Sale Subscription: send reminder for subscriptions with no token" 5. Go back to the previously created subscription (see that a reminder email has been added in the chatter) 6. Duplicate the subscription and confirm the duplicate 7. Run the action "Sale Subscription: send reminder for subscriptions with no token" again 8. There are no reminder for the duplicate subscription Issue: The copy of a subscription uses the same `last_reminder_date`, preventing payment reminders to be sent here https://github.com/odoo/enterprise/blob/5a2ab62254cd5f684a3b1a0d7c0001b888c70d08/sale_subscription/models/sale_order.py#L2114-L2120 Solution: Set `copy=False` on the field `last_reminder_date` opw-6167356
This update fixes an issue where the CO State Income Tax on payslips was incorrectly showing a positive value, which is not a standard payroll withholding. The fix aligns with established payroll tax principles, ensuring accurate withholding calculations and preventing potential refund scenarios. This ensures correct tax reporting for Colorado-based employees.
Original PR description
## Issue When generating a payslip for an employee of a company located in Colorado, the *CO State Income Tax* could end up positive. ## Steps to reproduce 1. Install *United States - Payroll*…
## Issue
When generating a payslip for an employee of a company located in Colorado, the *CO State Income Tax* could end up positive.
## Steps to reproduce
1. Install *United States - Payroll* (`l10n_us_hr_payroll`)
2. Set the current company's State to Colorado
3. Create an employee and a contract
- Wage: $0
- (Set the contract's status to *Running*)
- (In the payroll tab) State Withholding Allowance: $1000
4. Create a Payslip for the employee
- Structure: *"United States: Regular Pay"*
5. Compute Sheet
6. **In the _Salary Computation_ tab, the _CO State Income Tax_ line has a positive value**
## Justification
This fix is similar to the one applied for the AL(abama) state income tax by https://github.com/odoo/enterprise/commit/f0eeb55f1e3cf965c6a409675813d4a699e5fca6. That modification was justified by CAS (PO of US localizations for Payroll) in opw-5137280:
> *"Payroll taxes are always funds withheld from employee's paychecks, if there is a positive value it means the tax is a refund, not a withholding. Refunds happen when individuals file their income."*
## Note to reviewer
The test [`test_069_al_state_tax_0_income`](https://github.com/odoo/enterprise/blob/219d2a797ee2099c9d77c2defc9c9c5e1d504ffe/test_l10n_us_hr_payroll_account/tests/test_salary_rules.py#L957-L989) (added by the aforementioned commit https://github.com/odoo/enterprise/commit/f0eeb55f1e3cf965c6a409675813d4a699e5fca6) is wrongly indented and thus never executed. The test passes with the dedicated fix, and fails without it, as expected. Let me know if you want me to indent it correctly (in this commit or in an additional one).
opw-5999856