4

I used Dynamic Redis to add additional functionality to redis. I'm able to use the commands from the redis-cli. Is it possible to use redis-py to use those new commands in a python script ?

1 Answer 1

20

Found the answer. Just extend one of the client classes(StrictRedis or Redis) and use their execute_command method.

redis_client = redis.StrictRedis(host, port, db)
data = redis_client.execute_command('custom redis command')

https://github.com/andymccurdy/redis-py/issues/632

Sign up to request clarification or add additional context in comments.

1 Comment

Now StrictRedis and Redis are same.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.