Closed Quasarman closed 2 months ago
sure, I'm fine with adding cache for it
This data is cached unless you recreate the Cognito
object each time.
https://github.com/NabuCasa/pycognito/blob/fffafc95e320403f51f65c19e4eb2e67832a8baf/pycognito/__init__.py#L218-L232
Would it make sense to cache requests made to
https://cognito-idp.{aws-region}.amazonaws.com/{user-pool-id}/.well-known/jwks.json
since otherwise we would always make an request to get basically static data.I know about the env variable
COGNITO_JWKS
but it does not feel right to hardcode this information inside an env variable. Ofcourse I could implement the caching outside of theCognito
class und set the env variable but why not have it directly inside instead?