projects
/
jinja2.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fde3ff2
)
[svn] applied patch from #272, cmemcached is now used if available
author
Armin Ronacher
<armin.ronacher@active-4.com>
Tue, 24 Jul 2007 07:15:00 +0000
(09:15 +0200)
committer
Armin Ronacher
<armin.ronacher@active-4.com>
Tue, 24 Jul 2007 07:15:00 +0000
(09:15 +0200)
--HG--
branch : trunk
jinja/loaders.py
patch
|
blob
|
history
diff --git
a/jinja/loaders.py
b/jinja/loaders.py
index aadaad7b86f7b76c1837b04d81f53e4fd244cb31..95d9d8d2428ec03f93c37fde8cb3687fdf6d24ad 100644
(file)
--- a/
jinja/loaders.py
+++ b/
jinja/loaders.py
@@
-273,7
+273,10
@@
class MemcachedLoaderMixin(object):
def __init__(self, use_memcache, memcache_time=60 * 60 * 24 * 7,
memcache_host=None, item_prefix='template/'):
try:
- from memcache import Client
+ try:
+ from cmemcache import Client
+ except ImportError:
+ from memcache import Client
except ImportError:
raise RuntimeError('the %r loader requires an installed '
'memcache module' % self.__class__.__name__)