[FIX] runbot: fix leader pull_info_failures

The initial pull_info_failures feature was introduced before the separate
process for the leader. Since this is here for a rare case, this
wasn't tested since then.

Testing the new infrastructure without token, there was many
pull_info_failure, leading to an error on cleanup.
This commit is contained in:
Xavier-Do 2022-06-09 08:35:00 +02:00
parent 33ab9cdce6
commit a6fa7b8023

View File

@ -262,7 +262,7 @@ class Runbot(models.AbstractModel):
for pr_number, t in pull_info_failures.items():
if t + 15*60 < time.time():
_logger.warning('Removing %s from pull_info_failures', pr_number)
del self.pull_info_failures[pr_number]
del pull_info_failures[pr_number]
return manager.get('sleep', default_sleep)