diff --git a/bot/kodiak/entrypoints/ingest.py b/bot/kodiak/entrypoints/ingest.py index 5ec687fea..493f05f23 100644 --- a/bot/kodiak/entrypoints/ingest.py +++ b/bot/kodiak/entrypoints/ingest.py @@ -41,9 +41,7 @@ async def get_redis() -> asyncio_redis.Pool: _redis = await asyncio_redis.Pool.create( host=conf.REDIS_URL.hostname or "localhost", port=conf.REDIS_URL.port or 6379, - password=( - conf.REDIS_URL.password.encode() if conf.REDIS_URL.password else None - ), + password=conf.REDIS_URL.password, # XXX: which var? poolsize=conf.USAGE_REPORTING_POOL_SIZE, ssl=conf.REDIS_URL.scheme == "rediss", diff --git a/bot/kodiak/queue.py b/bot/kodiak/queue.py index fadf09007..0117af239 100644 --- a/bot/kodiak/queue.py +++ b/bot/kodiak/queue.py @@ -238,9 +238,7 @@ async def get_redis() -> asyncio_redis.Pool: _redis = await asyncio_redis.Pool.create( host=conf.REDIS_URL.hostname or "localhost", port=conf.REDIS_URL.port or 6379, - password=( - conf.REDIS_URL.password.encode() if conf.REDIS_URL.password else None - ), + password=conf.REDIS_URL.password, poolsize=conf.USAGE_REPORTING_POOL_SIZE, encoder=asyncio_redis.encoders.BytesEncoder(), ssl=conf.REDIS_URL.scheme == "rediss", diff --git a/bot/kodiak/redis_client.py b/bot/kodiak/redis_client.py index 27a7b82b9..40cd7a190 100644 --- a/bot/kodiak/redis_client.py +++ b/bot/kodiak/redis_client.py @@ -13,9 +13,7 @@ async def create_connection() -> asyncio_redis.Connection: return await asyncio_redis.Connection.create( host=conf.REDIS_URL.hostname or "localhost", port=conf.REDIS_URL.port or 6379, - password=( - conf.REDIS_URL.password.encode() if conf.REDIS_URL.password else None - ), + password=conf.REDIS_URL.password, ssl=conf.REDIS_URL.scheme == "rediss", db=redis_db, ) diff --git a/bot/kodiak/test_queries.py b/bot/kodiak/test_queries.py index ef46d3295..5539b8908 100644 --- a/bot/kodiak/test_queries.py +++ b/bot/kodiak/test_queries.py @@ -266,9 +266,7 @@ async def setup_redis(github_installation_id: str) -> None: r = await asyncio_redis.Connection.create( host=host, port=port, - password=( - conf.REDIS_URL.password.encode() if conf.REDIS_URL.password else None - ), + password=conf.REDIS_URL.password, ) key = f"kodiak:subscription:{github_installation_id}" await r.hset(key, "account_id", "D1606A79-A1A1-4550-BA7B-C9ED0D792B1E")