Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F117382491
D823.1774822141.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
D823.1774822141.diff
View Options
diff --git a/pykolab/imap/__init__.py b/pykolab/imap/__init__.py
--- a/pykolab/imap/__init__.py
+++ b/pykolab/imap/__init__.py
@@ -43,14 +43,13 @@
self.imap = None
def cleanup_acls(self, aci_subject):
- lm_suffix = ""
-
log.info(
_("Cleaning up ACL entries for %s across all folders") % (
aci_subject
)
)
+ lm_suffix = ""
if len(aci_subject.split('@')) > 1:
lm_suffix = "@%s" % (aci_subject.split('@')[1])
@@ -58,13 +57,6 @@
user_folders = self.imap.lm("user/*%s" % (lm_suffix))
- log.debug(
- _("Cleaning up ACL entries referring to identifier %s") % (
- aci_subject
- ),
- level=5
- )
-
# For all folders (shared and user), ...
folders = user_folders + shared_folders
@@ -72,8 +64,8 @@
# ... loop through them and ...
for folder in folders:
- # ... list the ACL entries -- but only if the folder still exists
- if self.imap.has_folder(folder):
+ try:
+ # ... list the ACL entries
acls = self.imap.lam(folder)
# For each ACL entry, see if we think it is a current, valid
@@ -96,13 +88,13 @@
)
self.set_acl(folder, acl_entry, '')
- else:
- log.debug(
- _("Folder %r disappeared (ACL cleanup for %r") % (
+
+ except Exception, errmsg:
+ log.error(
+ _("Failed to read/set ACL on folder %s: %r") % (
folder,
- aci_subject
- ),
- level=8
+ errmsg
+ )
)
def connect(self, uri=None, server=None, domain=None, login=True):
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Mar 29, 10:09 PM (1 w, 23 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
18777105
Default Alt Text
D823.1774822141.diff (1 KB)
Attached To
Mode
D823: Fix AttributeError: Cyrus instance has no attribute 'has_folder' in cleanup_acls()
Attached
Detach File
Event Timeline