Bug 118213 - New mail notification should happen after filters are applied
Summary: New mail notification should happen after filters are applied
Status: CONFIRMED
Alias: None
Product: kmail2
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: NOR wishlist
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
: 134985 140036 188949 248499 288467 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-12-12 22:52 UTC by Erik Hensema
Modified: 2015-11-12 06:52 UTC (History)
11 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Erik Hensema 2005-12-12 22:52:22 UTC
Version:            (using KDE KDE 3.5.0)
Installed from:    SuSE RPMs

When kmail pops mail, the mail is aparently delivered to the inbox, after which filters are applied.

Some of my filters move mail to mailboxes I essentially ignore. They shouldn't count in the number of new messages shown in the kmail systray icon (and they don't).

However, kmail stil rings the 'new mail' sound and briefly displays a number of new messages in the systray icon when mail is retrieved which is subsequently filtered to ignored mailboxes.

So, new mail notification should only happen AFTER all filters are applied to a message. The systray icon shouldn't be updated and the new mail sound shouldn't be played when not necesary.
Comment 1 Axel Braun 2006-12-06 20:00:26 UTC
I strongly support this wish, as these tons of spam keep my system continuously ringing, even if there is no ham in between.
Additionally it should be possible to specify the relevance of each folder for 'new mail' notification. Default might be on, can be changed to off, which would be a good setting for the spam folder.
Comment 2 Axel Braun 2007-03-04 17:44:48 UTC
As I just saw....'unread' mails in the draft folder are not displayed in the system tray...so it should not be too difficult to implement
Comment 3 Thomas McGuire 2007-04-08 20:51:57 UTC
*** Bug 140036 has been marked as a duplicate of this bug. ***
Comment 4 Axel Braun 2007-07-06 13:36:22 UTC
By chance I detected a setting in the folder properties of KMail 3.5.7:

[ ] Action for new/unread mails in this folder

If you untick this e.g. on the spamfolder, Spams arent shown anymore in the taskbar.

Good job guys!
Comment 5 Thomas McGuire 2007-07-09 18:30:15 UTC
See also bug 134985.

Erik, is this bug still an issue at all with the "act on new/unread mails for this folder" setting?
Comment 6 Erik Hensema 2007-07-09 19:41:58 UTC
Yes. The issues IS with that setting.

When a filter moves a message TO a folder with NO notification of new/unread mail, then a 'new mail' sound is played. The systray icon updates very briefly to 1 extra unread mail and then falls back to the previous (and correct) value.

This bug/wish is about moving the logic of when to play a sound a bit backward in the processing chain. Now the sound apparently is played as soon as new mail arrives in the mailbox, before filters are applied.
I'd like to move it to AFTER the filters are applied, when playing the sound possibly shouldn't be nescesary anymore.
The new mail could concievably be moved from a notification "on" folder to a notification "off" folder. Therefore no sound should be played and no systray icon update should occur.
Comment 7 Thomas McGuire 2007-07-09 20:28:19 UTC
Ok then, thanks for the fast clarification.
Comment 8 Thomas Boje 2009-02-05 10:56:59 UTC
I was going to open the same wish about triggering notifications after applying filters. I use KMail 1.11.0 / KDE 4.2 / Gentoo. (Read: not restricted to KDE 3.x; there is still interest)

I defined a filter in KMail that marks mails as read. Yet, as the original reported previously described, I get a "new mail" notification popup, but when I look there are no unread mails. Neither on the KMail icon nor in my inbox. (The mail is there but already marked as read, of course.) So the behaviour is not restricted to folders excluded from triggering new mail notifications.
Comment 9 Jonathan Marten 2009-06-30 15:54:17 UTC
*** Bug 188949 has been marked as a duplicate of this bug. ***
Comment 10 Ilya Hegai 2009-10-13 15:57:21 UTC
*** This bug has been confirmed by popular vote. ***
Comment 11 Björn Ruberg 2010-09-10 23:41:14 UTC
*** Bug 134985 has been marked as a duplicate of this bug. ***
Comment 12 Matěj Laitl 2010-09-11 00:33:58 UTC
Adding CCs from duplicate bug.
Comment 13 Daniel Buus 2010-09-11 11:31:18 UTC
*** Bug 248499 has been marked as a duplicate of this bug. ***
Comment 14 Daniel Buus 2010-09-11 11:33:28 UTC
Great... Going on five years since this was reported, yet to be resolved. And it's simply a matter of sequencing events, it ought to be fixable in five minutes.
Comment 15 Anne-Marie Mahfouf 2011-12-01 11:49:23 UTC
Please check KMail2 and report back on what is still needed.

Meanwhile reassigning to kmail2 product
Comment 16 Jonathan Marten 2012-01-26 15:30:08 UTC
*** Bug 288467 has been marked as a duplicate of this bug. ***
Comment 17 Jonathan Marten 2012-01-26 15:30:50 UTC
Still a problem with KMail2 current master.
Comment 18 Kevin Funk 2012-12-11 14:13:22 UTC
Bump. Still an issue. I'd even consider this a bug instead of a pure wish.
Comment 19 Tom Mittelstädt 2015-11-12 06:52:39 UTC
ten years later - kmail 5.0.2 - still present.
this is a bug, not a wish, because the notification misbehaves (by ignoring the custom folder-based notification settings) if mail filtering takes longer than some seconds (eg if it is processed by spamassassin)