Roundcube Community Forum

Third Party Contributions => API Based Plugins => Topic started by: tam on January 26, 2012, 03:39:48 AM

Title: markasjunk2 error: Call to undefined method stdClass::set_flag()
Post by: tam on January 26, 2012, 03:39:48 AM
Hi,

I just installed markasjunk2, configured it for dspam, but when I try to mark as spam within roundcube, roundcube says "server error" and my Apache error.log says:

[error] [client xxx.xx.xx.xx] PHP Fatal error:  Call to undefined method stdClass::set_flag()
in /var/www/roundcube/plugins/markasjunk2/markasjunk2.php on line 102


PHP version is PHP 5.3.2-1ubuntu4.11
Title: markasjunk2 error: Call to undefined method stdClass::set_flag()
Post by: JohnDoh on January 26, 2012, 12:11:06 PM
i cant recreate this but i'd guess that you are running the repo version of markasjunk2 against something other than the latest svn trunk version of roundcube. that wont work. you need to download the right version of markasjunk2 for your version of roundcube.
Title: markasjunk2 error: Call to undefined method stdClass::set_flag()
Post by: tam on January 26, 2012, 12:54:01 PM
Hi,

I'm running roundcube 0.7.1 and I have downloaded markasjunk2 from here: https://github.com/JohnDoh/Roundcube-Plugin-Mark-as-Junk-2/downloads

I have installed form here now: http://www.tehinterweb.co.uk/roundcube/#pimarkasjunk2
Seems to work. Thanks.
Title: markasjunk2 error: Call to undefined method stdClass::set_flag()
Post by: tam on January 26, 2012, 01:23:05 PM
Ok, error msg has gone away, but dspam isn't called at all.

This is part of my config:
$rcmail_config['markasjunk2_spam_cmd'] = '/usr/bin/dspamc --user dspam --class=spam --source=error --signature=%xds';
If I call  su www-data -c "/usr/bin/dspamc --source=error --class=spam --user dspam --signature=bla" dspam runs nice, except the signature not found, of course.

Also, even if I set debug to true, I can't find any log containing something of interest.

Can you pls help once more?
Title: markasjunk2 error: Call to undefined method stdClass::set_flag()
Post by: JohnDoh on January 28, 2012, 04:42:12 AM
the logs are in [rc root]/logs/markasjunk2 by default. did you set the driver in the config to be cmd_learn?
Title: markasjunk2 error: Call to undefined method stdClass::set_flag()
Post by: tam on January 28, 2012, 06:37:45 AM
No. :( Sorry, my fault. Now it works perkect. Thanks again for your help.