Daily updates from Odoo
Friday, April 24, 2026
19 changes · 17.0
Enhancements to existing features
This update prepares Odoo to handle the upcoming transition to alphanumeric CNPJs for Brazilian businesses. The Brazilian government is expanding the CNPJ number system, and this change ensures Odoo can continue to accurately process and validate these new formats. A new validation method has been implemented to avoid dependency issues with older Odoo versions.
Original PR description
Purpose: The Brazilian Federal Government, through the Brazilian Federal Revenue Service (Receita Federal do Brasil), is implementing the alphanumeric CNPJ to address the imminent depletion of its…
Purpose: The Brazilian Federal Government, through the Brazilian Federal Revenue Service (Receita Federal do Brasil), is implementing the alphanumeric CNPJ to address the imminent depletion of its capacity to generate new CNPJ numbers. The current, exclusively numeric model is approaching its limit. The transition to a format that includes letters and numbers expands the number of possible combinations, ensuring the future availability of registrations for new companies. With the government expanding the CNPJ numbers, we need to implement a solution to support the alphanumeric CNPJ that will be issued starting July 2026. Current Behavior: The method, `is_valid,` from stdnum is currently used to determine whether the CNPJ is valid or not. This is now considered an outdated method to determine the validation. Changed Behavior: The new validation logic by stdnum, found here https://github.com/arthurdejong/python-stdnum/commit/d3ec3bd7fefe0d0a708b6594a66de28777eb9b8d, is patched into `check_vat_br.` The reasoning for patching this rather than calling stdnum is because using stdnum will cause library dependency issues for older versions of Odoo. task-5234869 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Resolved issues and error corrections
This update resolves an issue that previously caused errors when deleting empty Kanban columns within the To-Do app. The fix ensures the correct arguments are passed during column deletion, preventing a technical error and improving the stability of the application.
Original PR description
Currently, an error occurs when deleting a kanban column that is empty in the To-do app ### **Steps to reproduce:** 1) Open To-do app. 2) In Kanban, create or locate an empty column (no tasks). 3) Click the column gear icon and choose Delete. ### **Error:** TypeError: Cannot read properties of undefined (reading 'map') ### **Root Cause** The `ProjectTaskKanbanDynamicGroupList` override of `_unlinkGroups` did not forward the `groups` argument to `super._unlinkGroups()` at [1], so the superclass received undefined and attempted to call groups.map(), causing the Error. [1]- https://github.com/odoo/odoo/blob/9468ff7a47d78447b66a4cdf1d33f8c21f51c309/addons/project/static/src/views/project_task_kanban/project_task_kanban_model.js#L24 ### **Fix:** This commit prevents error by ensuring the `groups` argument is passed to super method. **opw-6129664**
This update fixes a labeling issue within the Odoo Enterprise payroll module for Belgium. Specifically, the label for 'insured dependents' on the employee form was incorrect. The change updates the string option to ensure accurate and consistent reporting for payroll calculations and compliance.
Original PR description
Step to reproduce: install l10_be_hr_payroll and go on employee form, payroll tab Cause: wrong string for string option Solution: update the string option Task: 6094807
This update corrects a bug where confirming one upsell option within a subscription automatically cancelled all other alternative upsell options. Now, confirming a single upsell will only cancel the other alternatives, ensuring accurate subscription management. This improves the reliability of the subscription process.
Original PR description
When multiple upsells are created as alternatives for the same subscription, confirming one currently cancels all the upsells for the same subscription. This fix ensures that once an upsell is confirmed, only all other alternative upsells are automatically cancelled. task-5270139
This update fixes a formatting issue in the e-waybill document date field. Previously, the date displayed included the time, which wasn't the standard requirement. Now, only the date is shown, ensuring consistency and accuracy in e-waybill documentation.
Original PR description
The `document_date` field in e-waybill form view previously included both date and time, which is not as per the expected format. This fix ensures that only the date is shown, hiding the time component.
This update resolves a duplication issue in the French Profit & Loss report by removing a redundant account (6492) that was previously included alongside account 649. This ensures accurate financial reporting for French businesses using Odoo Enterprise.
Original PR description
This commit is an addon to this commit[[1]] where we tried to avoid duplicate accounts in the Profit And Loss report. The problem is that we don't exclude the separated account 6492 from the original one (649). This commit adds the removal of this account in the report formula. task-6053784 Here is the coverage: [Profit and loss account (FR) - Accounts Coverage Report (2).xlsx](https://github.com/user-attachments/files/27011824/Profit.and.loss.account.FR.-.Accounts.Coverage.Report.2.xlsx) The correct separation: <img width="837" height="485" alt="image" src="https://github.com/user-attachments/assets/ebe98976-f689-4389-866a-c9a0c8b50534" /> [1]: https://github.com/odoo/enterprise/commit/4587c49c4b220305652150d2f21a95fb7cfa188d
This update fixes an error that occurred when importing SAF-T files into the accounting module. The issue stemmed from a missing element in the SAF-T XML, which caused a system error. This change ensures the import process completes successfully, allowing users to accurately import their financial data.
Original PR description
Currently, an error occurs when importing the SAF-T file into accounting. Steps to Reproduce: - Install the `account_saft_import` and `accountant` modules. - Create a `new company` with the country…
Currently, an error occurs when importing the SAF-T file into accounting. Steps to Reproduce: - Install the `account_saft_import` and `accountant` modules. - Create a `new company` with the country set to `Denmark`, and `switch` to this company. - Go to `Settings` > `Accounting`, and click `Import` under Accounting Import. - Click `Import SAF-T`, enable Import account opening balances, and upload [this file](https://drive.google.com/file/d/177zf_w3B8m3g2VlJkbDB-Zp61TbZuV5r/view) `AttributeError: 'NoneType' object has no attribute 'update'` This error occurs when importing the SAF-T file in accounting. The SAF-T XML does not include any <saft:Account> entries, so map_accounts is empty [1]. As a result, based on map_accounts here [2], it got None in data['account.move'], which causes the error in [3]. [1] https://github.com/odoo/enterprise/blob/2f59dc2443833b0308fcd774a8008b8ebdce48fd/account_saft_import/wizard/import_wizard.py#L436 [2] https://github.com/odoo/enterprise/blob/2f59dc2443833b0308fcd774a8008b8ebdce48fd/account_saft_import/wizard/import_wizard.py#L447 [3] https://github.com/odoo/enterprise/blob/2f59dc2443833b0308fcd774a8008b8ebdce48fd/account_saft_import/wizard/import_wizard.py#L467 This commit ensures that it uses an empty object if it gets None. sentry-6714182871
This update resolves an error that occurred when an invoice was deleted after being sent via post. The system now checks if the invoice exists before attempting to attach the snailmail letter, preventing a 'Record does not exist' error. This ensures the Snailmail process continues to function smoothly.
Original PR description
Currently, an error occurs when the `Snailmail: process letters queue` scheduled action is triggered. Steps to reproduce: - Install the `website` and `account` modules. - Create a `Invoice` >…
Currently, an error occurs when the `Snailmail: process letters queue` scheduled action is triggered. Steps to reproduce: - Install the `website` and `account` modules. - Create a `Invoice` > `Confirm` > `Send` > check the `By Post` checkbox. - `Reset to Draft` newly created invoice and delete it. - Run the `Snailmail: process letters queue` scheduled action. `MissingError: Record does not exist or has been deleted. (Record: account.move(27,), User: 1)` This error occurs when the user sends the invoice by post, which creates a Snailmail letter record related to the invoice. If the invoice is subsequently deleted, the Snailmail: Process Letters Queue scheduled action run and attempt to fetch the attachment of related snailmail letter and invoice[1] but the invoice is not exists [2] and raise a MissingError. [1] https://github.com/odoo/odoo/blob/cc368d553cd94bee8b09d4981cb8f1dbc27a34b3/addons/snailmail/models/snailmail_letter.py#L149 [2] https://github.com/odoo/odoo/blob/420765c787b33f79ee8814f799de721508858319/addons/account/models/account_move.py#L3605 This commit ensures that the system evaluates the attachment only if the invoice also exists. sentry-6635629791 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update fixes a technical issue where the OAuth sign-in process would display a generic error message when required information was missing. Now, a more standard error is raised, making it easier to identify and resolve issues during the sign-in flow. This improves the overall user experience and stability of the authentication process.
Original PR description
When required parameters are missing from the OAuth sign-in request to the /auth_oauth/signin route, a generic Exception with the message "invalid_request" is raised. This behavior does not align with standard error handling practices. `Exception: invalid_request` This commit ensures that a ValidationError is raised instead of a generic Exception when the request is invalid. Sentry-6400398175 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves an issue where the OAuth sign-in process would fail if the 'state' parameter was missing. The change ensures the system safely retrieves this parameter, and raises an error if it's missing or empty, preventing disruptions to user authentication.
Original PR description
The OAuth sign-in route `/auth_oauth/signin` raises a `KeyError` when the `state` parameter is missing from the request.
KeyError: 'state'
This commit ensures the sign-in method uses `kw.get('state', '{}')` to safely retrieve the state parameter. It raises a BadRequest if the state is not present or is empty after parsing.
Sentry-6521782565
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prThis update simplifies the process for creating Unsplash attachments within Odoo. Previously, overly broad access rights were required, but this fix now restricts sudo permissions to only setting the attachment URL, reducing complexity and potential security risks. This change ensures employees can upload Unsplash images efficiently.
Original PR description
Only grant `sudo` to set the attachment `url` rather than applying sudo on the whole `.create` dict The purpose of the previous `_can_bypass_rights_on_media_dialog` was to allow employees uploading unsplash images to be able to create an attachment with an `url` while being a `type='binary'`, for the images to be able to be served with the URL `/unsplash/...`. Just applying `sudo` at the right needed spot rather than on the whole `create` requires less code to achieve the same goal.
This update fixes a discrepancy in the sale details report by accurately reflecting cash rounding adjustments. Now, the report displays the total cash rounding applied during a session, aligning with how payments are recorded and providing a clearer picture of the transaction total. This ensures greater accuracy and transparency in sales reporting.
Original PR description
The sale details report total_paid was computed from sum(order.amount_total), which does not include the cash rounding adjustment. This caused a discrepancy between the displayed total and the sum of individual payment lines when cash rounding is enabled. Use the sum of actual payment amounts instead, which naturally includes cash rounding since payments are recorded with their rounded values. opw-5253018
This update resolves an issue where the quick create feature for product variants within Bills of Materials was incorrectly creating unrelated product templates. To ensure correct variant creation, the system now requires users to create the variant directly on the product template, providing a more reliable process.
Original PR description
Steps to produce: --- - Install `mrp`. - Go to Manufacturing > Products > Bills of Materials. - Click Create, select a product. - In the Product Variant field, type any value and click "Create".…
Steps to produce: --- - Install `mrp`. - Go to Manufacturing > Products > Bills of Materials. - Click Create, select a product. - In the Product Variant field, type any value and click "Create". Issue: --- Using quick create on the Product Variant field does not create a variant of the selected product template. Instead, it creates a completely new, unrelated `product.template`. This is because the `create()` method on `product.product` is overridden to call super() with context `create_product_product=False`, which suppresses direct variant creation and forces creation through `product.template` instead, see [1]. **Why passing `default_product_tmpl_id` does not help:** One might expect that passing `default_product_tmpl_id` in the field context would cause the newly quick-created `product.product` to be linked to the already-selected `product.template`. However, because of the `create()` override above (introduced in [commit]), the variant creation is always redirected to `product.template`, ignoring any `default_product_tmpl_id` passed in context. It is therefore not possible in any case to quick-create a `product.product` that is correctly and directly linked to the currently selected `product.template`. Fix: --- Disable the "Create" and "Create and Edit" options. Since there is no way to quick-create a `product.product` that is correctly linked to the currently selected `product.template`, the user must create the variant directly on the product template first. [1]https://github.com/odoo/odoo/blob/f04d79d44873d0f1c35303a1a892f3a3a394ea17/addons/product/models/product_product.py#L364-L368 [commit]: https://github.com/odoo/odoo/commit/7389345696720255a9d3c72ca1d9c2f4e4ecd7b8 opw-6127738 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update adjusts the sales subscription module to align with recent changes in the Odoo community. Specifically, it removes a reference to a removed signature tab in the Sales Order view, ensuring the template continues to function correctly after the community update. This ensures consistent PDF generation for sales subscriptions.
Original PR description
In a https://github.com/odoo/odoo/pull/261288, we removed the customer's signature of all generated Quotation/SO's PDF except from the one they actually signed. We also removed the "Customer Signature" tab from the Sales order view. This tab was referenced to extend the template in the `sale_subscription` module. In this commit, we remove this reference and replace it for a reference to the tab before the removed one. task-5421716 opw-6159170 Back port of https://github.com/odoo/enterprise/pull/107529
This update adds a new unit test to identify and correct a rounding error in the calculation of Arabic withholding taxes. The test specifically checks a scenario where a base amount of 391683 with a 4.5% tax rate should result in a withholding amount of 17625.74. Fixing this issue will ensure accurate tax calculations.
Original PR description
Add test test_07_invoice_and_payment_with_3_decimals_withholding_amount, the base amount is 391683, the percentage applied is 4.5%, the withholding amount must be 17625.74 . Check that this test fails on 18 on this pr https://github.com/odoo/odoo/pull/232893 and will be successful if the bug reported on https://www.odoo.com/es_ES/my/tasks/5154585 (#230641) is fixed. Task Adhoc side: 59222 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update resolves an issue where the minimum IS (Insurance Savings) amount was incorrectly calculated in the Swiss payroll module. The change ensures accurate reporting of IS contributions for Swiss employees, aligning with local tax regulations. This update improves the reliability of payroll data for our Swiss clients.
Original PR description
opw 6133391
This update ensures that when reserving stock for packaged products, the system correctly considers the available quantity of full packages. Previously, a large stock level would override the 'reserve only full packages' setting. This change now accurately reflects the available stock, preventing over-reservation and ensuring accurate order fulfillment.
Original PR description
Issue ----- Forced full packaging reservation setting is ignored when there is a big quant in stock. Steps to reproduce ----- - Enable packagings - Create a product category "Super Category" -…
Issue
-----
Forced full packaging reservation setting is ignored when there is a big quant in stock.
Steps to reproduce
-----
- Enable packagings
- Create a product category "Super Category"
- Reserve Packagings: Reserve Only Full Packagings
- Create a stored product "AAA"
- Product Category: Super Category
- 50 units on hand
- Packaging: 6-Pack (6 units)
- Create a delivery for 15 units of AAA
> Reservation is made for 15 units
Cause
-----
The rounding to a multiple of the packaging quantity takes the stock quant into account. For our example case, we have 8 full 6-Packs on hand, so the `available_quantity` gets set to 48 when doing
https://github.com/odoo/odoo/blob/5e458236ca2ff2ab92c4893495e7a721be902c40/addons/stock/models/stock_quant.py#L923-L925
This leads to the reservation quantity being min(15, 48) = 15
https://github.com/odoo/odoo/blob/5e458236ca2ff2ab92c4893495e7a721be902c40/addons/stock/models/stock_quant.py#L927
-----
Ticket:
opw-5974333This update fixes a previous issue where the General Ledger report displayed journal items out of order, primarily grouped by company instead of date. Now, transactions are correctly sorted by date across all companies, providing a much clearer and more accurate chronological view of financial activity. This improves reporting accuracy and simplifies financial analysis.
Original PR description
### Issue before this commit: Before this commit, the General Ledger report did not correctly order journal items when a company and his branch were involved. Even when entries had different dates,…
### Issue before this commit: Before this commit, the General Ledger report did not correctly order journal items when a company and his branch were involved. Even when entries had different dates, the lines were grouped and displayed primarily by company, resulting in a non-chronological view. ### Steps to reproduce the issue: 1. Download Accounting 2. Create a company branch for your actual company 3. Create 4 invoices (2 for the company with different dates and 2 for the branch with same dates as the company's invoices) 4. Open General Ledger and see that under the account's group the order is per company and not per date ### Cause of the issue: The issue was caused by the SQL query used to retrieve account move lines in the General Ledger (PR that introduce the bug: https://github.com/odoo/enterprise/pull/107638) Specifically, the ORDER BY clause prioritized company-related fields before the transaction date. As a result, the sorting logic first grouped entries by company and only then applied date ordering within each company group, instead of performing a global chronological sort. ### Reason to introduce the fix: The fix ensures that journal items are primarily ordered by date across all companies, providing a correct chronological view of transactions. ### Fix details: It's not possible to reorder the attributes in the ORDER BY clause without braking the test test_general_ledger_export_csv_multi_comp so it has been decided to create this trick to solve only the bug in the visualization of the General Ledger report leaving the bug in the export of csv. opw-6000740
This update fixes an issue where styled headings in the table of content weren't correctly translated when switching languages. The fix ensures that changes to the table of content are also saved, allowing for consistent translation across all languages. This improves the user experience and ensures accurate content display.
Original PR description
Scenario: - drop table of content snippet in a page - in a title (present in the table of content) add some styling such as bold / color - in a secondary language, change the translation of that header - save Result: the heading in the table of content is not translatable. Cause: the table of content entry is translated by translating the corresponding heading. When the heading is changed, it is synced to the table of content entry with the inline style removed. But when we save, we only save the dirty node so we are only saving the original heading. But since the heading translation doesn't match the table of content entry (because the style tag removal), only the heading translation is updated. Fix: when the table of content entry is updated, set it as o_dirty so it is also saved. opw-5413915 opw-5926501