Before that, when trying setting to None the tag_name of a tax report line whose tags were referenced by some move lines, a exception was raised, telling that some account.move.line objects still referenced an account.tag we were trying to delete. Removing the tags from db was legit (since we're removing the tag_name, we need to remove the tags that it generated), but first needed to remove all these tags from the account move lines linked to them.
closesodoo/odoo#40375
X-original-commit: 3eb5a3e947bb371f90c9f2357ff410816419bbb0
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>