Dear all,

I have recently set up Review Board for my organization, and in the
process found what looks like a bug in group enumeration in the AD
authentication backend. I would like to submit a fix for the project's
configuration. When I try to create a new review request, an error
message "global name 'logging' is not defined" appears next to "diff"
on the new review request page when I click "create review request".
This is the patch that I attached:

diff --git a/reviewboard/accounts/ b/reviewboard/accounts/
index 59da9cc..c3a1ea4 100644
--- a/reviewboard/accounts/
+++ b/reviewboard/accounts/
@@ -231,7 +231,8 @@ class ActiveDirectoryBackend(object):
                 for group in new_groups:
                     if group in old_seen:
-                    group_data = self.search_ad(con, '(&
(objectClass=group)(saMAccountName=%s))' % group)
+                    # Search for groups with the specified DN. Use
the DN rather than sAMAccountName so that behavior is correct when the
values differ (e.g. if a "pre-Windows 2000" group name is set in AD).
+                    group_data = self.search_ad(con, '(&
(objectClass=group)(dn=%s))' % group)
                     seen.update(self.get_member_of(con, group_data,
seen=seen, depth=depth))
                 logging.warning('ActiveDirectory recursive group
check reached maximum recursion depth.')

Although the text "logging" is present in the diff, I don't believe
that this is relevant - removing "logging" from the diff does not
alter the error message.

I created the diff by running "git diff" in my local repository - am I
doing something wrong?

You received this message because you are subscribed to the Google Groups 
"reviewboard" group.
To post to this group, send email to
To unsubscribe from this group, send email to
For more options, visit this group at

Reply via email to