entities/lib.py
changeset 9442 fbf2287fb2ce
parent 9211 d45d66d94baa
child 10603 65ad6980976e
--- a/entities/lib.py	Mon Jan 13 16:08:38 2014 +0100
+++ b/entities/lib.py	Tue Jan 21 17:01:33 2014 +0100
@@ -18,6 +18,7 @@
 """entity classes for optional library entities"""
 
 __docformat__ = "restructuredtext en"
+from warnings import warn
 
 from urlparse import urlsplit, urlunsplit
 from datetime import datetime
@@ -130,6 +131,13 @@
     __regid__ = 'CWCache'
     fetch_attrs, cw_fetch_order = fetch_config(['name'])
 
+    def __init__(self, *args, **kwargs):
+        warn('[3.19] CWCache entity type is going away soon. '
+             'Other caching mechanisms can be used more reliably '
+             'to the same effect.',
+             DeprecationWarning)
+        super(CWCache, self).__init__(*args, **kwargs)
+
     def touch(self):
         self._cw.execute('SET X timestamp %(t)s WHERE X eid %(x)s',
                          {'t': datetime.now(), 'x': self.eid})