mirror of
https://github.com/reddit-archive/reddit.git
synced 2026-01-26 07:19:25 -05:00
Upgrade to pylibmc 1.1.1.
* Fixes app segfaults when memcache not available. * Remove "time" parameter from r2.lib.cache.CMemcache.delete_multi since it never worked anyway and was removed from pylibmc.
This commit is contained in:
@@ -177,10 +177,9 @@ class CMemcache(CacheUtils):
|
||||
with self.clients.reserve() as mc:
|
||||
return mc.delete(key)
|
||||
|
||||
def delete_multi(self, keys, prefix='', time=0):
|
||||
def delete_multi(self, keys, prefix=''):
|
||||
with self.clients.reserve() as mc:
|
||||
return mc.delete_multi(keys, time = time,
|
||||
key_prefix = prefix)
|
||||
return mc.delete_multi(keys, key_prefix=prefix)
|
||||
|
||||
def __repr__(self):
|
||||
return '<%s(%r)>' % (self.__class__.__name__,
|
||||
|
||||
@@ -85,13 +85,13 @@ except ImportError:
|
||||
|
||||
# we're using a custom build of pylibmc at the moment, so we need to
|
||||
# be sure that we have the right version
|
||||
pylibmc_version = '1.0-reddit-04'
|
||||
pylibmc_version = '1.1.1-reddit-0.1'
|
||||
try:
|
||||
import pylibmc
|
||||
assert pylibmc.__version__ == pylibmc_version
|
||||
except (ImportError, AssertionError):
|
||||
print "Installing pylibmc"
|
||||
easy_install(["http://github.com/downloads/ketralnis/pylibmc/pylibmc-1.0-reddit-04.tar.gz"])
|
||||
easy_install(["https://github.com/downloads/reddit/pylibmc/pylibmc-1.1.1-reddit-0.1.tgz"])
|
||||
|
||||
filtermod = Extension('Cfilters',
|
||||
sources = ['r2/lib/c/filters.c'])
|
||||
|
||||
Reference in New Issue
Block a user