DEV: pin redis to version 4.0.1

DEV: pin redis to version 4.0.1

Version 4.1.0 returns frozen hashes which conflict with our monkey patch

We will follow up unpinning this later

diff --git a/Gemfile b/Gemfile
index f5bdeb3..24f5f69 100644
--- a/Gemfile
+++ b/Gemfile
@@ -31,7 +31,15 @@ gem 'mini_mime'
 gem 'mini_suffix'
 
 gem 'hiredis'
-gem 'redis', require:  ["redis", "redis/connection/hiredis"]
+
+# holding off redis upgrade temporarily as it is having issues with our current
+# freedom patch, we will follow this up.
+#
+# FrozenError: can't modify frozen Hash
+# /var/www/discourse/vendor/bundle/ruby/2.5.0/gems/redis-4.1.0/lib/redis/client.rb:93:in `delete'
+# /var/www/discourse/vendor/bundle/ruby/2.5.0/gems/redis-4.1.0/lib/redis/client.rb:93:in `initialize'
+# /var/www/discourse/lib/freedom_patches/redis.rb:7:in `initialize'
+gem 'redis', '4.0.1', require:  ["redis", "redis/connection/hiredis"]
 gem 'redis-namespace'
 
 gem 'active_model_serializers', '~> 0.8.3'
diff --git a/Gemfile.lock b/Gemfile.lock
index 7eba484..d1a6f4c 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -323,7 +323,7 @@ GEM
       msgpack (>= 0.4.3)
       trollop (>= 1.16.2)
     rchardet (1.8.0)
-    redis (4.1.0)
+    redis (4.0.1)
     redis-namespace (1.6.0)
       redis (>= 3.0.4)
     request_store (1.4.1)
@@ -527,7 +527,7 @@ DEPENDENCIES
   rb-inotify (~> 0.9)
   rbtrace
   rchardet
-  redis
+  redis (= 4.0.1)
   redis-namespace
   rinku
   rotp

GitHub sha: 635bc72e

1 Like

4.0.3 is bad too?

Maybe … maybe not, but we need to get 4.1.0 working so I would prefer to invest effort that way.