summaryrefslogtreecommitdiffstats
path: root/pykolab
diff options
context:
space:
mode:
authorJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2013-10-15 11:15:23 +0200
committerJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2013-10-15 11:15:23 +0200
commit52fff7eda260080a9feacdcde80bc5243f922393 (patch)
tree39d17ffbeda33d2170f68ed457a4bd37b9f8116f /pykolab
parente446ff782b3b815b35578eb91b692e6247e74e3f (diff)
downloadpykolab-52fff7eda260080a9feacdcde80bc5243f922393.tar.gz
Add additional debugging that might help track down #2350
Diffstat (limited to 'pykolab')
-rw-r--r--pykolab/auth/ldap/__init__.py16
-rw-r--r--pykolab/imap/cyrus.py15
2 files changed, 30 insertions, 1 deletions
diff --git a/pykolab/auth/ldap/__init__.py b/pykolab/auth/ldap/__init__.py
index 06fb00d..6670d17 100644
--- a/pykolab/auth/ldap/__init__.py
+++ b/pykolab/auth/ldap/__init__.py
@@ -1311,6 +1311,22 @@ class LDAP(pykolab.base.Base):
server = self.imap.user_mailbox_server(folder)
+ log.debug(
+ _("Entry %s attribute value: %r") % (
+ mailserver_attribute,
+ entry[mailserver_attribute]
+ ),
+ level=8
+ )
+
+ log.debug(
+ _("imap.user_mailbox_server(%r) result: %r") % (
+ folder,
+ server
+ ),
+ level=8
+ )
+
if not entry[mailserver_attribute] == server:
self.set_entry_attribute(entry, mailserver_attribute, server)
diff --git a/pykolab/imap/cyrus.py b/pykolab/imap/cyrus.py
index 6881740..9fa6feb 100644
--- a/pykolab/imap/cyrus.py
+++ b/pykolab/imap/cyrus.py
@@ -166,7 +166,20 @@ class Cyrus(cyruslib.CYRUS):
log.debug(_("Checking actual backend server for folder %s through annotations") % (mailfolder), level=8)
if self.mbox.has_key(mailfolder):
- return self.mbox[mailfolder]
+ log.debug(
+ _(
+ "Possibly reproducing the find " + \
+ "mailfolder server answer from " + \
+ "previously detected and stored " + \
+ "annotation value: %r"
+ ) % (
+ self.mbox[mailfolder]
+ ),
+ level=8
+ )
+
+ if not self.mbox[mailfolder] == self.server:
+ return self.mbox[mailfolder]
max_tries = 20
num_try = 0