You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To clarify, I understand that RedisCache doesn't attempt to provide an identical interface to a dictionary anymore, for example update also doesn't take kwargs or no arguments at all. But this behaviour is clearly observable from the function signature.
In comparison, the empty dict behaviour is not visible from looking at the implementation unless one looks into aioredis. It feels natural to assume that update({}) is safe. Perhaps the update could check for this case and exit early?
Passing an empty dictionary to
RedisCache.update
produces aValueError
from inside the aioredis dependency.This is inconsistent with the behaviour of a Python dictionary:
If this is intended, it should be documented, as the
update
method's docstring can be misleading:The text was updated successfully, but these errors were encountered: