From 30ba00a909aac92db582045c16eab33420aeab2d Mon Sep 17 00:00:00 2001 From: Keshav Mishra Date: Sat, 16 Nov 2024 01:05:19 +0530 Subject: [PATCH] fix: bet blacklisting for non bets in list Co-authored-by: Adamantios Zaras --- packages/valory/skills/market_manager_abci/behaviours.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/valory/skills/market_manager_abci/behaviours.py b/packages/valory/skills/market_manager_abci/behaviours.py index 59611a3d..04c26cba 100644 --- a/packages/valory/skills/market_manager_abci/behaviours.py +++ b/packages/valory/skills/market_manager_abci/behaviours.py @@ -152,9 +152,7 @@ def _update_bets( for bet in self.bets: if self.synced_time >= bet.openingTimestamp - self.params.opening_margin: - index = self.get_bet_idx(bet.id) - if index is not None: - self.bets[index].blacklist_forever() + bet.blacklist_forever() # truncate the bets, otherwise logs get too big bets_str = str(self.bets)[:MAX_LOG_SIZE]