Skip to content
This repository was archived by the owner on Jul 7, 2026. It is now read-only.

fix: forward kwargs to aioredis in Redis backends#1107

Open
dimitryLMEX wants to merge 1 commit into
bmoscon:masterfrom
LMEXofficial:fix/redis-kwargs
Open

fix: forward kwargs to aioredis in Redis backends#1107
dimitryLMEX wants to merge 1 commit into
bmoscon:masterfrom
LMEXofficial:fix/redis-kwargs

Conversation

@dimitryLMEX

Copy link
Copy Markdown

Summary

RedisCallback.__init__ accepted **kwargs but never stored or forwarded them to aioredis.from_url(). Any keyword argument passed at construction time (e.g. password, ssl, decode_responses) was silently discarded, making password-protected Redis instances unusable.

Fix

Store the extra kwargs in self.conn_kwargs and unpack them into every aioredis.from_url() call across the three writer classes.

# RedisCallback.__init__  (new line)
self.conn_kwargs = kwargs

# Each writer()  (before → after)
conn = aioredis.from_url(self.redis)
conn = aioredis.from_url(self.redis, **self.conn_kwargs)

Fixes #1032

RedisCallback.__init__ accepted **kwargs but never stored or
forwarded them. Password-protected Redis instances were
unusable because the auth credential was silently discarded.

Store extra kwargs in self.conn_kwargs and pass them to
aioredis.from_url() in all three writer() methods
(RedisZSetCallback, RedisStreamCallback, RedisKeyCallback).

Fixes bmoscon#1032
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Backend Redis - kwargs are not forwarded to the instantiation (e.g. redis auth)

1 participant