From skip.montanaro at gmail.com Mon Feb 1 16:40:37 2021 From: skip.montanaro at gmail.com (Skip Montanaro) Date: Mon, 1 Feb 2021 15:40:37 -0600 Subject: [spambayes-dev] sb_imapfilter with Hotmail causes loss of emails In-Reply-To: References: Message-ID: I'm passing this along in case there is anyone still listening to spambayes-dev who might have some relevant/recent IMAP experience. In a non-SpamBayes application I just dumped imaplib in favor of IMAPClient in part because I didn't want to mess with IMAP4, so I'm not able to help (willinging, at least). I will poke around a bit though. Thanks, Skip ---------- Forwarded message --------- From: Alexei Potashnik Date: Mon, Feb 1, 2021 at 2:38 PM Subject: Re: [smontanaro/spambayes] sb_imapfilter with Hotmail causes loss of emails (#6) To: smontanaro/spambayes Cc: Skip Montanaro , Comment < comment at noreply.github.com> are you implying that you have used sb_imapfilter with other IMAP servers and not experienced message lossage No, this is my first time trying sb_imapfilter My expectation is that SpamBayes should never delete email I suspect this comment in sb_imapfilter points to what might be happening: """Warnings: o We never delete mail, unless you use the -e/purge option, but we do mark a lot as deleted, and your mail client might remove that for you. We try to only mark as deleted once the moved/altered message is correctly saved, but things might go wrong. We *strongly* recommend that you try this script out on mail that you can recover from somewhere else, at least at first. """ Now if I look at gmail vs hotmail IMAP settings there are these extra options that gmail provides and hotmail doesn't: When I mark a message in IMAP as deleted: Auto-Expunge on - Immediately update the server. (default) Auto-Expunge off - Wait for the client to update the server. When a message is marked as deleted and expunged from the last visible IMAP folder: Archive the message (default) Move the message to the Trash Immediately delete the message forever I have a feeling hotmail behaves like gmail with "Auto-Expunge on" and "Immediately delete the message forever". I'm wondering if someone with IMAP expertise can comment on the above theory or maybe propose a workaround for hotmail. Can you attach your config file with your Hotmail credentials xxxxxx-d out [imap] server:outlook.office365.com use_ssl:True username: filter_folders:Inbox spam_folder:Inbox/spam.90 unsure_folder:Inbox/spam ham_train_folders:Inbox/train.ham spam_train_folders:Inbox/train.spam ? You are receiving this because you commented. Reply to this email directly, view it on GitHub , or unsubscribe . -------------- next part -------------- An HTML attachment was scrubbed... URL: