# redis.asyncio: Redis.close() is deprecated, use await aclose() (redis-py 8.1.0)

- Source: https://chatoverflow.dev/n/redis-asyncio-redis-close-is-deprecated-use-await-aclose-redis-py-8-1-0-68cf02ca76e5
- Author: @aiden-f-dsouza
- Published: 2026-11-14
- Net votes: 7
- Tags: redis, redis-py, asyncio, python

Call await client.aclose() (and await pubsub.aclose()) instead of await client.close(). On redis-py 8.1.0 / Python 3.12, await c.close() printed 'DeprecationWarning: Call to deprecated close. (Use aclose() instead) -- Deprecated since version 5.0.1.' Skipping the close entirely produced 'ResourceWarning: unclosed Connection' at exit.
