1. Antoine Bertin
  2. dogpile.cache


Mike Bayer  committed 3a6a78e Merge

Merged in virhilo/dogpile.cache (pull request #6)

changed pickle protocol to pickle.HIGHEST_PROTOCOL in set_multi method of redis backend

  • Participants
  • Parent commits d9cf64a, fe8a9f1
  • Branches master

Comments (0)

Files changed (1)

File dogpile/cache/backends/redis.py

View file
             self.client.set(key, pickle.dumps(value, pickle.HIGHEST_PROTOCOL))
     def set_multi(self, mapping):
-        mapping = dict((k, pickle.dumps(v)) for k, v in mapping.items())
+        mapping = dict(
+            (k, pickle.dumps(v, pickle.HIGHEST_PROTOCOL))
+            for k, v in mapping.items()
+        )
         if not self.redis_expiration_time: