redis/redis-py · error · NotImplementedError

HELLO is intentionally not implemented in the client.

Error message

HELLO is intentionally not implemented in the client.

What it means

Raised by hello() (redis/commands/core.py:2292) which is a stub that unconditionally raises NotImplementedError. HELLO performs RESP protocol negotiation, which the client manages internally during connection setup (driven by the 'protocol' connection kwarg / --protocol test flag), so exposing it on the command surface would conflict with the connection's own state machine. No arguments are accepted.

Solutions

  1. Set the protocol at connection time: redis.Redis(host=..., protocol=3) (or protocol=2)
  2. For AUTH/SETNAME during handshake, use the connection kwargs username/password/client_name
  3. If you must issue HELLO manually: r.execute_command("HELLO", 3) on a fresh connection, understanding it can desync the client

Example fix

# before
r.hello()
# after
import redis
r = redis.Redis(host="localhost", protocol=3)
Defensive patterns

Strategy: validation

Validate before calling

# hello() is intentionally unimplemented; set protocol at connect time
import redis
r = redis.Redis(host=host, port=port, protocol=3)  # or protocol=2

Try / catch

try:
    r.hello()
except NotImplementedError:
    # protocol is chosen at connection time, not via a runtime call
    pass

Prevention

When it happens

Trigger: Calling r.hello(). Any call raises immediately.

Common situations: Trying to switch RESP2/RESP3 at runtime; or assuming the CLI HELLO command maps to a client method.

Related errors


AI-assisted analysis of redis/redis-py@6a6b581b48 (2026-08-10). Data as JSON: /api/errors/f71f65d12e0f57e4. Report an issue: GitHub.

Appendix: source

Thrown at redis/commands/core.py:2292

    ) -> list[int] | Awaitable[list[int]]:
        """
        This command blocks the current client until all previous write
        commands by that client are acknowledged as having been fsynced
        to the AOF of the local Redis and/or at least the specified number
        of replicas.

        For more information, see https://redis.io/commands/waitaof
        """
        return self.execute_command(
            "WAITAOF", num_local, num_replicas, timeout, **kwargs
        )

    def hello(self):
        """
        This function throws a NotImplementedError since it is intentionally
        not supported.
        """
        raise NotImplementedError(
            "HELLO is intentionally not implemented in the client."
        )

    def failover(self):
        """
        This function throws a NotImplementedError since it is intentionally
        not supported.
        """
        raise NotImplementedError(
            "FAILOVER is intentionally not implemented in the client."
        )

    @overload
    def hotkeys_start(
        self: SyncClientProtocol,
        metrics: List[HotkeysMetricsTypes],
        count: int | None = None,
        duration: int | None = None,

View on GitHub (pinned to 6a6b581b48)