API refactor
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2025-10-07 16:25:52 +09:00
parent 76d0d86211
commit 91c7e04474
1171 changed files with 81940 additions and 44117 deletions

View File

@@ -79,18 +79,24 @@ class ModuleError(ResponseError):
class LockError(RedisError, ValueError):
"Errors acquiring or releasing a lock"
# NOTE: For backwards compatibility, this class derives from ValueError.
# This was originally chosen to behave like threading.Lock.
pass
def __init__(self, message=None, lock_name=None):
self.message = message
self.lock_name = lock_name
class LockNotOwnedError(LockError):
"Error trying to extend or release a lock that is (no longer) owned"
"Error trying to extend or release a lock that is not owned (anymore)"
pass
class ChildDeadlockedError(Exception):
"Error indicating that a child process is deadlocked after a fork()"
pass
@@ -215,4 +221,27 @@ class SlotNotCoveredError(RedisClusterException):
class MaxConnectionsError(ConnectionError):
...
"""
Raised when a connection pool has reached its max_connections limit.
This indicates pool exhaustion rather than an actual connection failure.
"""
pass
class CrossSlotTransactionError(RedisClusterException):
"""
Raised when a transaction or watch is triggered in a pipeline
and not all keys or all commands belong to the same slot.
"""
pass
class InvalidPipelineStack(RedisClusterException):
"""
Raised on unexpected response length on pipelines. This is
most likely a handling error on the stack.
"""
pass