[ldapuser] Deprecated the source
We have ldapfeed for some time. maintaining both is cumbersome. This old style
source will be dropped in 3.18.
closes #2567712
--- a/doc/3.17.rst Fri Apr 19 15:44:42 2013 +0200
+++ b/doc/3.17.rst Tue Apr 23 12:01:14 2013 +0200
@@ -29,6 +29,11 @@
moved to the `massmailing` cube.
+Deprecation
+---------------------
+
+* ``ldapuser`` have been deprecated. It'll be fully dropped in the next
+ version. If you are still using ldapuser switch to ``ldapfeed`` **NOW**!
Deprecated Code Drops
----------------------
--- a/server/sources/ldapuser.py Fri Apr 19 15:44:42 2013 +0200
+++ b/server/sources/ldapuser.py Tue Apr 23 12:01:14 2013 +0200
@@ -27,6 +27,7 @@
from rql.nodes import Relation, VariableRef, Constant, Function
+import warnings
from cubicweb import UnknownEid, RepositoryError
from cubicweb.server import ldaputils
from cubicweb.server.utils import cartesian_product
@@ -45,6 +46,11 @@
}
+# module is lazily imported
+warnings.warn('Imminent drop of ldapuser. Switch to ldapfeed now!',
+ DeprecationWarning)
+
+
class LDAPUserSource(ldaputils.LDAPSourceMixIn, AbstractSource):
"""LDAP read-only CWUser source"""
support_entities = {'CWUser': False}