From 1eb4c6a8b6f64f33a201fb50f6b320bef4d3adaa Mon Sep 17 00:00:00 2001 From: Jakub Kadlčík Date: Jan 11 2019 10:24:33 +0000 Subject: [frontend] when deleting an outdated chroot, NULL the remove_after field We will lose the timestamp of when the chroot should have been deleted (which doesn't equal the timestamp when the chroot actually was deleted, but can have some aproximate value for statistics), in order to not create delete_chroot action for already deleted chroots. --- diff --git a/frontend/coprs_frontend/commands/delete_outdated_chroots.py b/frontend/coprs_frontend/commands/delete_outdated_chroots.py index 5b84de2..a599402 100644 --- a/frontend/coprs_frontend/commands/delete_outdated_chroots.py +++ b/frontend/coprs_frontend/commands/delete_outdated_chroots.py @@ -31,3 +31,4 @@ class DeleteOutdatedChrootsCommand(Command): print("Add delete_chroot action for {} in {}".format(chroot.name, chroot.copr.full_name)) else: actions_logic.ActionsLogic.send_delete_chroot(chroot) + chroot.delete_after = None