If the hiredis version is lower than 3 (which mine is) the HIREDIS_AVAILABLE is going to be false, therefore it will keep giving error inside the redis/connection.py file, because the import hiredis will not be executed, but the code still relies on this import.
I believe there should be a better error handling here warning people about this breaking change.
Version: 5.1.0
Platform: Python 3.12 / ubuntu 22.04
Description: I started to get the error
output.append(hiredis.pack_command(args)) NameError: name 'hiredis' is not defined
I Believe the reason for this issue is because of the code inside redis/utils.py
If the hiredis version is lower than 3 (which mine is) the
HIREDIS_AVAILABLE
is going to be false, therefore it will keep giving error inside the redis/connection.py file, because theimport hiredis
will not be executed, but the code still relies on this import.I believe there should be a better error handling here warning people about this breaking change.