Skip to content

current hset, hdel, hlen, hkeys and hexists prefix the wrong key #794

@mk-ship-it

Description

@mk-ship-it

According to Redis' docs

https://redis.io/docs/latest/commands/hset/
https://redis.io/docs/latest/commands/hkeys/

What django_redis.client.DefaultClient currently calls name is actually the redis key being used, so logically, the client should call make_key on that, referring to the cache index, rather than on the field name in the default client.

https://github.com/jazzband/django-redis/blob/master/django_redis/client/default.py#L1145

Calling make_key on the field name will give you nasty surprises and end up combining hash tables with different prefixes with their "field names" prefixed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions