IMAPdedup icon indicating copy to clipboard operation
IMAPdedup copied to clipboard

mailbox list with / delimiter gives error on recursive processing

Open x-m-nc opened this issue 4 years ago • 1 comments

I tryed to deduplicate mails on my mailbox (dont know the kind of server)

I got a list of mailboxes just fine INBOX INBOX/subfolder INBOX/subfolder/subfolder and so on

with the option -r it wont process:

"Traceback (most recent call last): File "./imapdedup.py", line 535, in main(sys.argv[1:]) File "./imapdedup.py", line 531, in main process(options, mboxes) File "./imapdedup.py", line 396, in process for mb in get_mailbox_list(server, parent, pattern): File "./imapdedup.py", line 257, in get_mailbox_list bits = parse_list_response(mb) File "./imapdedup.py", line 165, in parse_list_response m = list_response_pattern.match(line) TypeError: expected string or bytes-like object"

-> Probably the delimiter of folders is the problem?! . vs / ?

x-m-nc avatar Jul 30 '20 17:07 x-m-nc

Similar problem here when running against Apple iCloud Mail:

+ python3 imapdedup.py --server imap.mail.me.com --port 993 --ssl --user xxx --password xxx --verbose --show --dry-run --checksum --recursive INBOX
Traceback (most recent call last):
  File "imapdedup.py", line 598, in <module>
    process(options, mboxes)
  File "imapdedup.py", line 445, in process
    delimiter = bits[1].decode()
TypeError: 'NoneType' object is not subscriptable

… but only with the --recursive option specified.

This is at commit 5155f74.

srcshelton avatar May 11 '22 08:05 srcshelton