Thursday, July 16, 2020
3 changes · master
Resolved issues and error corrections
The inventory action label is adjusted so it stays accurate across different menus, not just when updating quantities from a product page. This reduces confusion for users viewing inventory reports while preserving the specific update wording where it makes sense. Test-only imports were also corrected so they do not affect normal module use.
Original PR description
At bee938e (following task-id 2042303), the label of the action was changed globaly. The action is however shared with multiple menus like Inventory Report. The Update Quantity label only makes sense when coming from the product where the quantity will be updated. Closes odoo/odoo#50523
This corrects a recent internal database query update that could fail in uncommon system operations. The fix helps keep administrative and core database tasks working reliably without changing everyday user workflows.
Original PR description
odoo/odoo#53938 improved the SQL linter and used psycopg2.sql to silence the linter where that still made sense. However I forgot to mark table names (pretty much exclusively) as `sql.Identifier` in a few somewhat rare callsites, which consequently break when invoked as a simple string is not a Composable and psycopg2 therefore rejects it when composing the query.
This fix ensures several Enterprise modules only load their test code when tests are actually being run. It prevents unnecessary test-related requirements from affecting normal module startup, reducing the risk of runtime issues for users.
Original PR description
The tests must be only imported in a test context, not in a running context. Since odoo/odoo@92a7f8c a new test requirement was added but it should not be necessary to run a module, only to execute the tests. Enterprise part of odoo/odoo#53628 (two fixes) Making a master version of odoo/odoo#54554 as there are more of them in master.