Needs "Priority Inbox" option (and a simple code fix)

Bug #631644 reported by Jeffrey Haemer on 2010-09-06
This bug affects 4 people
Affects Status Importance Assigned to Milestone
GMail Notifier
Alexander Hungenberg

Bug Description

Even if my gmail settings say "go to priority inbox," gm-notify always goes to my traditional inbox instead.

Probably an easy fix. If I replace "inbox" with "mbox" in, it fixes the problem for me.

To make sure I'm being clear, the hack is this:

perl -i -pe 's/"inbox"/"mbox"/g'

I.e., change inbox in quotation marks to mbox in quotation marks.

(Needs testing, etc., plus there may be an even better fix, like looking at the settings or making it user-configurable. Still, just inbox->mbox would be an improvement.)

summary: - Needs "Priority Inbox" option
+ Needs "Priority Inbox" option (and a simple code fix)
description: updated

The icon no longer turns green when incoming mail arrives after this hack, so I need some of them to change but not others -- I'd have to actually read the code and play with it to get the correct fix, but don't have time in the near future.

I edited mine by hand, you just have to modify one line (line 46) to make it work :

from :
MAILBOXES_URLS = { "inbox": _("inbox") }
to :
MAILBOXES_URLS = { "inbox": _("mbox") }

Of course that's just a hack, but it works so that's fine with me.

fixed it so it uses the settings defined in gmail

Changed in gm-notify:
assignee: nobody → Alexander Hungenberg (alexander-hungenberg-gmail)
status: New → Fix Committed
Changed in gm-notify:
milestone: none → 0.10.3
status: Fix Committed → Fix Released
Richard Klein (kleinric) wrote :

I might have found another solution for this. Apparently priority email get labeled 'Important' (

So if you just go to config, tell it to "Ignore Inbox" and then add "Important" to the list of boxes to check, then it appears to work.

I'm not sure if this is better than the fixes that have been proposed?

Richard Klein (kleinric) wrote :

This method works fine except for some reason it doesn't play the sound when new mail appears in 'Important'

Richard Klein (kleinric) wrote :

I'm sorry, I don't mean to spam the wall. I find that if I add the following code then it fixes the notification problem. The issue is that "important" doesn't come through in the labels, but rather ^im (I think). So just adding that check in the same way you already add the inbox tag... In settings I then 'Ignore Inbox' so that it only shows important stuff. It still works if inbox is enabled.

Note that it just shows unread, important messages - it doesn't matter if the important message is in the inbox or not.

I hope this is useful and that I haven't wasted your time.


Edit the lines close to the top so that they read:
         MAILBOXES_NAMES = { "inbox" : _("Inbox"), "important" : _("Priority Messages")}
         MAILBOXES_URLS = { "inbox":"inbox" , "important":"mbox"}

By "#Retrieve the mailbox we're gonna check" add the following line above the one that adds the inbox. If you don't want to check priority inbox just skip this line.
So it should read:

in def new_mail(self, mails): change
                if label == u"^i": label = "inbox"
                if label == u"^i": label = "inbox"
                elif label == u"^im": label = "important"

Richard Klein (kleinric) wrote :

I downloaded the new source, the release notes say "Correct Priority Inbox usage" but it didn't seem to work for me even though I have it active and selected in Gmail.

Adds "Priority Messages" to the list of indicators.
Makes sure that new messages are only added to the notification bubble once.
"Ignoring Inbox" does not affect the functionality.

Sandeep Tailor (insysion) wrote :

I'm having this problem despite running 0.10.3

Could it be due to the fact that I'm a Google Apps user?

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers