From 33bf8f007e6e053cbb5742ea6964af1feadf19ef Mon Sep 17 00:00:00 2001 From: Ali-Akber Saifee Date: Fri, 6 Dec 2024 07:36:42 -0800 Subject: [PATCH] Use an async decorator for ttl cache in iam provider --- coredis/recipes/credentials/iam_provider.py | 3 ++- requirements/recipes.txt | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/coredis/recipes/credentials/iam_provider.py b/coredis/recipes/credentials/iam_provider.py index 52489b62..aa29edf7 100644 --- a/coredis/recipes/credentials/iam_provider.py +++ b/coredis/recipes/credentials/iam_provider.py @@ -7,8 +7,9 @@ # as coredis[recipes] import aiobotocore.session from aiobotocore.signers import AioRequestSigner +from asyncache import cached from botocore.model import ServiceId -from cachetools import TTLCache, cached +from cachetools import TTLCache from coredis.credentials import AbstractCredentialProvider, UserPass diff --git a/requirements/recipes.txt b/requirements/recipes.txt index be2c4e89..2c843204 100644 --- a/requirements/recipes.txt +++ b/requirements/recipes.txt @@ -1,3 +1,3 @@ -aiobotocore -cachetools +aiobotocore>=2.15.2 +asyncache>=0.3.1