http://bugs.winehq.org/show_bug.cgi?id=28661
Bug #: 28661 Summary: Receiving emails from AppDB when I shouldn't Product: WineHQ Apps Database Version: unspecified Platform: x86-64 URL: http://appdb.winehq.org OS/Version: Linux Status: NEW Keywords: download, source Severity: minor Priority: P2 Component: appdb-unknown AssignedTo: wine-bugs@winehq.org ReportedBy: kennybobs@o2.co.uk Classification: Unclassified
Created attachment 36833 --> http://bugs.winehq.org/attachment.cgi?id=36833 Email body
The AppDB is sending me emails that have nothing to do with me, despite global emails being disabled. Example attached.
There doesn't appear to be a pattern and it occurs randomly.
http://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #1 from Ken Sharp kennybobs@o2.co.uk 2012-03-08 08:39:02 CST --- This is much worse now. I'm getting spammed every day about notes being added to apps I've never had anything to do with. I doubt I'm the only one.
http://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #2 from Ken Sharp kennybobs@o2.co.uk 2012-09-06 14:33:18 CDT --- Still occurs.
http://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #3 from Ken Sharp imwellcushtymelike@gmail.com --- This still occurs. Cannot see any pattern to it.
https://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #4 from Ken Sharp imwellcushtymelike@gmail.com --- No change in 2015
https://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #5 from Ken Sharp imwellcushtymelike@gmail.com --- No change in 2016
https://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #6 from Rosanne DiMesio dimesio@earthlink.net --- Function get_notify_email_address_list in user.php has the following comment:
// If both appId and versionId are null we are especially // requesting to email admins, so the mail should be sent // regardless of global emails setting
That's the only thing I can find that might be related, though I don't see how it's being triggered, as the random emails I see are linked to valid applications and versions, so the ids shouldn't be null.
https://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #7 from Austin English austinenglish@gmail.com --- (In reply to Rosanne DiMesio from comment #6)
Function get_notify_email_address_list in user.php has the following comment:
// If both appId and versionId are null we are especially // requesting to email admins, so the mail should be sent // regardless of global emails setting
That's the only thing I can find that might be related, though I don't see how it's being triggered, as the random emails I see are linked to valid applications and versions, so the ids shouldn't be null.
Maybe trace tha ids in a log somewhere (and/or in the email) to verify?
https://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #8 from Rosanne DiMesio dimesio@earthlink.net --- I was finally able to reproduce this locally, but only when using the AppDB backup instead of my local test database.
All the errant emails I've received lately were about notes being added or edited, so I took a look at those note entries in the database. All note records have both an appId field and a versionId field. Most (3383) note entries have a valid versionId, but the appId is set to 0. There are 214 entries that are the reverse: a valid appId with the versionId set to 0; those are the ones triggering the emails to admins when they shouldn't. As to why they were stored with an appId and no versionId, my testing shows that happens when a note is originally added from the main app page rather than a version page.
As to why this triggers emails to admins, that does go back to the check that sends emails admins if there is no appId or versionId associated with it. Even though a note can be added from the main app page, it can only be edited from a version page, and only the versionId is checked when that happens.
Removing the check for appId/versionId from get_notify_email_address_list does stop those email notifications from being sent to admins who have disabled global notifications, but I will also need to come up with a better way to make sure admins still are sent the notices they should get (such as the daily cron cleanup report) before I can do that.
https://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #9 from Ken Sharp imwellcushtymelike@gmail.com --- Do we need the cron e-mails? I filter them straight into the bin.
https://bugs.winehq.org/show_bug.cgi?id=28661
--- Comment #10 from Rosanne DiMesio dimesio@earthlink.net --- They're intended specifically for admins, so they shouldn't be filtered out by disabling global emails.
You can still stop them by disabling all AppDB email in Preferences.
https://bugs.winehq.org/show_bug.cgi?id=28661
Rosanne DiMesio dimesio@earthlink.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |a8bf13a7359cd75b355461761b8 | |d45b906cb74fd Status|NEW |RESOLVED Resolution|--- |FIXED
--- Comment #11 from Rosanne DiMesio dimesio@earthlink.net --- I've added a getAdminEmails function to use for admin-only emails and removed the check for appId/versionId from get_notify_email_address_list, so that case should be fixed.
Marking fixed; if any more errant emails turn up after today, file a new bug, as those would have a different cause.
https://bugs.winehq.org/show_bug.cgi?id=28661
Rosanne DiMesio dimesio@earthlink.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #12 from Rosanne DiMesio dimesio@earthlink.net --- Closing fixed AppDB bug.