redis-py icon indicating copy to clipboard operation
redis-py copied to clipboard

Version compatibility between redis-py and redis-server?

Open J-M0 opened this issue 3 years ago • 4 comments

Hello,

Is there anywhere that documents which versions of redis-py are compatible with which versions of redis-server? I can't seem to find any documentation about this.

Thank you.

J-M0 avatar Feb 02 '22 16:02 J-M0

HI @J-M0 you're right, there isn't, and there should be!

Here's what I can confirm:

redis-py 3.5.3 is compatible with redis up until 6.0 (and there are some 6.2 commands) redis-py >4.0 is compatible with redis up until 6.2)

For the most part, we test various commands on various versions of redis - and are expanding that. With very few exceptions, the API has not been broken since redis 5.0, so from 4.1.2 things ought work with redis > 5.0.

I realize that this isn't canonical, and will leave this open as a good first issue for documenting this properly. Does that help?

chayim avatar Feb 02 '22 16:02 chayim

That does help a bit, yes. To be clear, my distro ships redis 5.0.5 and I'm currently using redis-py 3.5.3. I take it then that I can't upgrade to redis-py 4, right?

J-M0 avatar Feb 02 '22 16:02 J-M0

@J-M0 actually you should be fine with 4.1.2 as well! There will be several functions that aren't available to you - due to running redis 5.0.5, but the library won't stop you from trying to call them!

chayim avatar Feb 06 '22 13:02 chayim

@sav-norem Wanna?

chayim avatar Sep 01 '22 12:09 chayim

Can we upgrade redis-server to 7.x if we use redis==4.4.0?

dmitriy-drenkaliuk avatar Dec 28 '22 17:12 dmitriy-drenkaliuk

@dmitriy-drenkalyuk Yes, you can. redis-py 4.4.0 has almost fully support for redis 7.x (supports everything except sharded-pubsub)

dvora-h avatar Jan 08 '23 12:01 dvora-h

It would be very helpful for the community having a compatibility matrix to know which library version matches which server versions.

As an example, we are in an upgrade process of an old codebase, and we are not sure about the compatibility and the required effort to perform the upgrade.

logoff avatar Jan 10 '23 10:01 logoff

@chayim Can you confirm that redis-py is backwards compatible with older server versions? We're using a Redis 3.2.2 server and we'd like to know if redis-py v4.4.0 will work?

+1 on adding a compatibility matrix to the documentation. Thanks!

tstocker-black-cape avatar Mar 06 '23 16:03 tstocker-black-cape

Folks - the supported matrix is on the main page. It may work with an old redis.. but there have been so many command, security, and ecosystem changes - I highly suggest upgrading.

chayim avatar May 24 '23 10:05 chayim

Folks - the supported matrix is on the main page. It may work with an old redis.. but there have been so many command, security, and ecosystem changes - I highly suggest upgrading.

@chayim Thanks for the compatibility matrix, but it's a bit unclear to me:

Library version Supported redis versions
3.5.3 <= 6.2 Family of releases
>= 4.5.0 Version 5.0 to 7.0
>= 5.0.0 Version 5.0 to current

because what I actually see in the first column is:

Library version
redis == 3.5.3
redis >= 4.5.0, < 5.0.0
redis >= 5.0.0

then it seems the matrix is missing two more ranges:

  • redis < 3.5.3
  • redis < 4.5.0, >= 4.0.0

What about these?

eliadl avatar Aug 15 '23 10:08 eliadl