6.0.0-RC7
6/22/26

[#10302] Report as spam shown within message inside Spam folder
Summary Report as spam shown within message inside Spam folder
Queue IMP
Queue Version 5.0.7
Type Bug
State Resolved
Priority 1. Low
Owners slusarz (at) horde (dot) org
Requester kareem.dana (at) gmail (dot) com
Created 7/3/11 (5468 days ago)
Due
Updated 7/12/11 (5459 days ago)
Assigned 7/5/11 (5466 days ago)
Resolved 7/12/11 (5459 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
316 Michael Slusarz State ⇒ Resolved
 
266 Git Commit Comment #6 Reply to this comment
Changes have been made in Git for this ticket:

Bug #10302: Comparing 2 objects won't work properly if internal 
variables have changed

  5 files changed, 22 insertions(+), 8 deletions(-)
http://git.horde.org/horde-git/-/commit/6e93a8ccda4f66db3eb0fa4f243d321c95ba7a09
177 kareem (dot) dana (at) gmail (dot) com Comment #5 Reply to this comment
Some rudimentary debugging in message.php line 573:
if ($conf['spam']['reporting'] &&
     ($conf['spam']['spamfolder'] ||
      ($mailbox != IMP_Mailbox::getPref('spam_folder')))) {
...
}

That conditional is being resolved to true when I view a message in my 
spam folder, specifically ($mailbox != 
IMP_Mailbox::getPref('spam_folder')) is true. Here are the logs I had 
it print out.

HORDE [imp] message.php - report as spam [pid 1681 on line 577 of 
"/usr/local/www/apache22/horde/imp/message.php"]
HORDE [imp] IMP_Mailbox Object (     [cache] => Array         (         
      [n] => Array                 (                     [0] => .       
                [4] => 1                 )              [d] => 1       
       [ro] =>              [a] =>          )      [changed] => 0     
[_mbox:protected] => Spam )  [pid 1681 on line 578 of 
"/usr/local/www/apache22/horde/imp/message.php"]
HORDE [imp] IMP_Mailbox Object (     [cache] => Array         (         
      [n] => Array                 (                     [0] => .       
                [4] => 1                 )              [d] => 1       
       [ro] =>              [a] =>          )      [changed] => 1     
[_mbox:protected] => Spam )  [pid 1681 on line 579 of 
"/usr/local/www/apache22/horde/imp/message.php"]

The first IMP_Mailbox Object is $mailbox. The second is 
IMP_Mailbox::getPref('spam_folder'). 
IMP_Mailbox::getPref('spam_folder') has changed = 1. $mailbox has 
changed = 0. Not sure what changed means in this context, but I hope 
this helps. I'm using dovecot 2.0.12 as my imap server, by the way, if 
this issue is related to the imap server giving us some unexpected 
results.

367 kareem (dot) dana (at) gmail (dot) com Comment #4
New Attachment: spam-dimp.png Download
Reply to this comment
Here is the attachment.
207 kareem (dot) dana (at) gmail (dot) com Comment #3 Reply to this comment
I don't see this - it correctly shows "Report as Innocent" for me.
It is happening on both my production and test machines. "Report as 
Innocent" correctly shows up in the list view of messages, but when 
reading a message in the Spam folder, it switches to "Report as Spam" 
and if I click that link it follows through with reporting it as spam. 
Its not as if the link is being mislabeled. In my mail/imp 
preferences, I have the spam folder correctly set. I'll try to debug 
it a bit further and see if I can give you guys more information. 
Here's the versions I'm running if that helps:

Address Book (turba) 3.0.3
Filters (ingo) 2.0.2
Horde (horde) 4.0.6
Mail (imp) 5.0.7

I'm now attaching a new screenshot from DIMP. My original bug report 
was solely based on the imp traditional view. Dimp is showing both 
Spam and Innocent buttons when I read a message in my spam folder.
376 Michael Slusarz Comment #2
State ⇒ Feedback
Reply to this comment
I don't see this - it correctly shows "Report as Innocent" for me.
328 Jan Schneider State ⇒ Assigned
Assigned to Michael Slusarz
 
472 kareem (dot) dana (at) gmail (dot) com Comment #1
Priority ⇒ 1. Low
Type ⇒ Bug
Summary ⇒ Report as spam shown within message inside Spam folder
Queue ⇒ IMP
Milestone ⇒
Patch ⇒ No
New Attachment: spamreport.png Download
State ⇒ Unconfirmed
Reply to this comment
When I am in my spam folder, the Report as Innocent link shows up as 
expected. However, if I click on a message in the Spam folder to view 
it, I get a Report as Spam link instead. This is within the IMP 
traditional view. I attached a screenshot. Notice the report as spam 
link even though I am in my spam folder.

Relevant IMP configuration:
$conf['spam']['spamfolder'] = false;
$conf['spam']['program'] = '/usr/local/bin/sa-learn --no-sync --spam';
$conf['spam']['reporting'] = true;
$conf['notspam']['spamfolder'] = true;
$conf['notspam']['program'] = '/usr/local/bin/sa-learn --no-sync --ham';
$conf['notspam']['reporting'] = true;

Saved Queries