From b9f4675a2522f873b28c1bd7a23c1ad6929caab4 Mon Sep 17 00:00:00 2001 From: Pablo Galindo Date: Sat, 22 Jul 2023 16:51:23 +0200 Subject: [PATCH] Ensure we clean the repo before attempting to cherry-pick --- miss_islington/tasks.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/miss_islington/tasks.py b/miss_islington/tasks.py index d1884a84..d42dc6ef 100644 --- a/miss_islington/tasks.py +++ b/miss_islington/tasks.py @@ -99,6 +99,11 @@ async def backport_task_asyncio( """, ) await util.assign_pr_to_core_dev(gh, issue_number, merged_by) + + # Ensure that we don't have any changes lying around + subprocess.check_output(['git', 'reset', '--hard']) + subprocess.check_output(['git', 'clean', '-fxd']) + cp = cherry_picker.CherryPicker( "origin", commit_hash,