id,summary,reporter,owner,description,type,status,priority,component,severity,resolution,keywords,cc,release 10713,DirectoryAuthPlugin: can't set dir_scope parameter in trac.ini,sima.baymani@…,branson,"For my setup of the plugin, I had to change the scope to 2 (Subtree) in order for the authentication to work. I did this in the source code and verified that it worked. However, when I tried to set the dir_scope parameter in trac.ini, I get the following error: {{{ Trac detected an internal error: TypeError: an integer is required }}} {{{ Python Traceback Most recent call last: Traceback (most recent call last): File ""/usr/local/lib/python2.6/dist-packages/Trac-1.0-py2.6.egg/trac/web/main.py"", line 497, in _dispatch_request dispatcher.dispatch(req) File ""/usr/local/lib/python2.6/dist-packages/Trac-1.0-py2.6.egg/trac/web/main.py"", line 214, in dispatch resp = chosen_handler.process_request(req) File ""/usr/local/lib/python2.6/dist-packages/Trac-1.0-py2.6.egg/trac/wiki/web_ui.py"", line 125, in process_request req.perm(page.resource).require('WIKI_VIEW') File ""/usr/local/lib/python2.6/dist-packages/Trac-1.0-py2.6.egg/trac/perm.py"", line 578, in require if not self._has_permission(action, resource): File ""/usr/local/lib/python2.6/dist-packages/Trac-1.0-py2.6.egg/trac/perm.py"", line 570, in _has_permission check_permission(action, perm.username, resource, perm) File ""/usr/local/lib/python2.6/dist-packages/Trac-1.0-py2.6.egg/trac/perm.py"", line 462, in check_permission perm) File ""/usr/local/lib/python2.6/dist-packages/Trac-1.0-py2.6.egg/trac/perm.py"", line 296, in check_permission get_user_permissions(username) File ""/usr/local/lib/python2.6/dist-packages/Trac-1.0-py2.6.egg/trac/perm.py"", line 398, in get_user_permissions for perm in self.store.get_user_permissions(username) or []: File ""/usr/local/lib/python2.6/dist-packages/TracDirectoryAuth-0.5-py2.6.egg/tracext/adauth/api.py"", line 43, in get_user_permissions subjects.update(provider.get_permission_groups(username)) File ""/usr/local/lib/python2.6/dist-packages/TracDirectoryAuth-0.5-py2.6.egg/tracext/adauth/auth.py"", line 215, in get_permission_groups dn = self._get_user_dn(username) File ""/usr/local/lib/python2.6/dist-packages/TracDirectoryAuth-0.5-py2.6.egg/tracext/adauth/auth.py"", line 299, in _get_user_dn [self.user_attr], cache) File ""/usr/local/lib/python2.6/dist-packages/TracDirectoryAuth-0.5-py2.6.egg/tracext/adauth/auth.py"", line 503, in _dir_search res = dir.search_s(basedn.encode(self.dir_charset), scope, filter, attrs) File ""/usr/lib/python2.6/dist-packages/ldap/ldapobject.py"", line 516, in search_s return self.search_ext_s(base,scope,filterstr,attrlist,attrsonly,None,None,timeout=self.timeout) File ""/usr/lib/python2.6/dist-packages/ldap/ldapobject.py"", line 828, in search_ext_s return self._apply_method_s(SimpleLDAPObject.search_ext_s,*args,**kwargs) File ""/usr/lib/python2.6/dist-packages/ldap/ldapobject.py"", line 780, in _apply_method_s return func(self,*args,**kwargs) File ""/usr/lib/python2.6/dist-packages/ldap/ldapobject.py"", line 509, in search_ext_s msgid = self.search_ext(base,scope,filterstr,attrlist,attrsonly,serverctrls,clientctrls,timeout,sizelimit) File ""/usr/lib/python2.6/dist-packages/ldap/ldapobject.py"", line 505, in search_ext timeout,sizelimit, File ""/usr/lib/python2.6/dist-packages/ldap/ldapobject.py"", line 96, in _ldap_call result = func(*args,**kwargs) TypeError: an integer is required }}} {{{ System: |Trac |1.0 | |Genshi |0.6 (without speedups) | |pysqlite |2.5.5| |Python |2.6.5 (r265:79063, Oct 1 2012, 22:04:36) [GCC 4.4.3]| |setuptools |0.6 | |SQLite |3.6.22 | |Subversion |1.6.6 (r40053) | |DirectoryAuthPlugin|0.5| |AccountMangerPlugin|0.4| }}} Maybe the parameter is not ready for use yet, in that case this isn't really a bug then. ",defect,closed,normal,DirectoryAuthPlugin,normal,duplicate,,,1.0