Jump to solution
Details

The Fix

pip install redis==7.1.0

Based on closed redis/redis-py issue #2289 · PR/commit linked

Production note: This usually shows up under retries/timeouts. Treat it as a side-effect risk until you can verify behavior with a canary + real traffic.

Open PR/Commit
@@ -24,6 +24,7 @@ * Remove compatibility code for old versions of Hiredis, drop Packaging dependency * The `deprecated` library is no longer a dependency + * Enable Lock for asyncio cluster mode * 4.1.3 (Feb 8, 2022)
fix.md
Option A — Upgrade to fixed release\npip install redis==7.1.0\nWhen NOT to use: This fix should not be used if pubsub functionality is not required.\n\n

Why This Fix Works in Production

  • Trigger: Duplicate of https://github.com/redis/redis-py/issues/2219
  • Mechanism: The asyncio RedisCluster client lacked pubsub support due to missing lock functionality
  • Why the fix works: Enables AsyncIO cluster mode lock support, addressing the lack of pubsub functionality in the asyncio Redis Cluster client. (first fixed release: 7.1.0).
Production impact:
  • If left unfixed, retries/timeouts can trigger duplicate external side-effects (double charges, duplicate emails, repeated writes).

Why This Breaks in Prod

  • Shows up under Python 3.9 in real deployments (not just unit tests).
  • The asyncio RedisCluster client lacked pubsub support due to missing lock functionality
  • Production symptom (often without a traceback): Duplicate of https://github.com/redis/redis-py/issues/2219

Proof / Evidence

  • GitHub issue: #2289
  • Fix PR: https://github.com/redis/redis-py/pull/2446
  • First fixed release: 7.1.0
  • Reproduced locally: No (not executed)
  • Last verified: 2026-02-07
  • Confidence: 0.85
  • Did this fix it?: Yes (upstream fix exists)
  • Own content ratio: 0.79

Discussion

High-signal excerpts from the issue thread (symptoms, repros, edge-cases).

“Hi @coandco The lock() support was added in https://github.com/redis/redis-py/pull/2446 I've updated your ticket to reflect the current state.”
@uglide · 2023-02-08 · source
“Duplicate of https://github.com/redis/redis-py/issues/2219”
@uglide · 2023-06-15 · source

Failure Signature (Search String)

  • Duplicate of https://github.com/redis/redis-py/issues/2219
Copy-friendly signature
signature.txt
Failure Signature ----------------- Duplicate of https://github.com/redis/redis-py/issues/2219

Error Message

Signature-only (no traceback captured)
error.txt
Error Message ------------- Duplicate of https://github.com/redis/redis-py/issues/2219

Environment

  • Python: 3.9

What Broke

Users experienced limited functionality in asyncio RedisCluster, impacting pubsub operations.

Why It Broke

The asyncio RedisCluster client lacked pubsub support due to missing lock functionality

Fix Options (Details)

Option A — Upgrade to fixed release Safe default (recommended)

pip install redis==7.1.0

When NOT to use: This fix should not be used if pubsub functionality is not required.

Use when you can deploy the upstream fix. It is usually lower-risk than long-lived workarounds.

Fix reference: https://github.com/redis/redis-py/pull/2446

First fixed release: 7.1.0

Last verified: 2026-02-07. Validate in your environment.

Get updates

We publish verified fixes weekly. No spam.

Subscribe

When NOT to Use This Fix

  • This fix should not be used if pubsub functionality is not required.

Did This Fix Work in Your Case?

Quick signal helps us prioritize which fixes to verify and improve.

Prevention

  • Add a stress test that runs high-concurrency workloads and fails on thread dumps / blocked locks.
  • Enable watchdog dumps in prod (faulthandler, thread dump endpoint) to capture deadlocks quickly.

Version Compatibility Table

VersionStatus
7.1.0 Fixed

Related Issues

No related fixes found.

Sources

We don’t republish the full GitHub discussion text. Use the links above for context.