Steps to reproduce: Archive an employee who has allowances in the approved state. Issue: The error is triggered and that says we can't archive an allocation. Solution: Use the context to avoid triggering the error if the archiving is part of another archiving process. Introduced with the commit 1839bf83a14a12eb83a8f721f82ece7238319e43 opw-3211372 closes odoo/odoo#114385 X-original-commit: 19cbf1d68052f002bff4f1fd12f9f94d60c17df2 Signed-off-by: Kevin Baptiste <kba@odoo.com>