-
- Downloads
[FIX] stock: add an automated way to fix unreserve issue
It happens that the `stock.quant.reserved_quantity` and `stock.move.line.product_qty`
for the same parameters are not equals (due to some bugs in the past)
It could implies that it doesn't exist enough reserved quantity on the
quant when a user try to unreserve a stock.move.line resulting in the
UserError 'It is not possible to unreserve more products of %s than you
have in stock'
However on current stable version (13.0 and 14.0) a lot of PR already
fixed a lot of issue as:
odoo/odoo#69377
odoo/odoo#66347
odoo/odoo#61758
odoo/odoo#54355
odoo/odoo#43180
odoo/odoo#70975
for example (there is more than that)
So the idea is to provide a way to unlock the database manually for
stable but not in the new version to be able to analyse them and find
possible bugs responssible for the desynchronization.
The server action check all the quants and their relative move line
to check if match correctly. If not it will remove the reservation
from both. It could remove the reservation from some `pickings` and
`stock.move`
related to odoo/odoo#62139
closes odoo/odoo#79180
Signed-off-by:
William Henrotin (whe) <whe@odoo.com>
Showing
- addons/stock/data/stock_data.xml 117 additions, 1 deletionaddons/stock/data/stock_data.xml
- addons/stock/i18n/stock.pot 10 additions, 2 deletionsaddons/stock/i18n/stock.pot
- addons/stock/models/stock_quant.py 11 additions, 2 deletionsaddons/stock/models/stock_quant.py
- addons/stock/tests/test_quant.py 3 additions, 3 deletionsaddons/stock/tests/test_quant.py
- addons/stock/tests/test_robustness.py 57 additions, 1 deletionaddons/stock/tests/test_robustness.py
Loading
Please register or sign in to comment