From 7f158de664179d5d6e21a9e0d17f6ae0b8d1879c Mon Sep 17 00:00:00 2001 From: Adamantios Date: Tue, 21 Nov 2023 13:24:25 +0200 Subject: [PATCH] fix: db update Fixes commit bed1244c28519ce9f444d0d26deaa9e982ca0a8b in #152. --- packages/valory/skills/decision_maker_abci/states/redeem.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/valory/skills/decision_maker_abci/states/redeem.py b/packages/valory/skills/decision_maker_abci/states/redeem.py index 017eb78ba..dbcc2f670 100644 --- a/packages/valory/skills/decision_maker_abci/states/redeem.py +++ b/packages/valory/skills/decision_maker_abci/states/redeem.py @@ -60,7 +60,7 @@ def end_block(self) -> Optional[Tuple[BaseSynchronizedData, Enum]]: if synced_data.period_count == 0: # necessary for persisted keys to function properly and not raise an exception when the first period ends update = { - db_key: getattr(synced_data.db, db_key, None) + db_key: synced_data.db.get(db_key, None) for db_key in RedeemRound.selection_key } synced_data.db.update(**update)