Download & Extend

Comments remain unpublished

Project:Listhandler
Version:master
Component:Code
Category:bug report
Priority:major
Assigned:philipnet
Status:reviewed & tested by the community

Issue Summary

Hi,
I upgraded from mailhandler 6.1.8 to 6.1.10 and run update.php.
I use this module in conjunction with listhandler.
Now, all works well except for comments that are always unpublished.
For example, a person open a new thread in the mailing list, mailhandler receive the mail and public the post to the forum.
another person gives an answer to the post, mailhandler/listhandler receive the email, put the message as a comment but is always unpublished and "superuser" must approve it.
This happens with 6.1.10, 6.1.8 was ok.
Are there some new commands that I must put in the mailbox configuration, a part of status: 1?
thank you.

Comments

#1

@drein does the user who is posting have privileges to post comments without approval? In 6.1.8 the node/comment was not properly initialized, whereas it should be properly initialized in the latest version, which means permissions should actually work as expected. Can you please check whether that user's role is allowed to post comments without approval?

#2

Hi Ian,
yes, both anonymous and autenticated roles has privileges to post comments without approve.
I rebuilded all permissions of my web site but nothing changed.
Now I'm going to disable the antispam module, only to be sure that there aren't problem with other modules, but for now, I can confirm that all comments posted are unpublished.

#3

@drein, are you using any commands currently? If you're using any command to set the comment status, can you remove that and try? Also, are you using any other modules that interact/work with mailhandler?

#4

Hi,
I used 2 commands:
tid: xxx
status: 1

I removed status 1 but nothing happened, the comment still go to the approval cueue.
About the modules... well I have dozens of modules installed and it's quite hard to say if there are something that can break mailhandler, anyway I disabled antispam and nothing changed, I have the acl and the content access module, but content access helps with nodes, not comments.
For comments I have comment notify, comment subject and flatcomments but nobody of these can stop comments for being published.
The last one is listhandler, that works in conjunction with mailhandler, but if I'm not in wrong, listhandler simply takes message from a forum and post them to the mailing list, I don't think it can block comments.
I use mailhandler with cron.
That's all for now...

#5

hum... some news.
I look at my logs and I see that all operation about comments is made by listhandler.
Well, there are no mailhandler entry in the log... so, is it possible that, changing mailhandler, listhandler doesn't work properly?
I didn't know that listhandler inserted comment from the ml to the forum, I assumed that was a mailhandler issue.
So... do you think I should open an issue to the listhandler project?

#6

Project:Mailhandler» Listhandler
Version:6.x-1.9» 6.x-1.x-dev

@drein - I'm switching this issue to listhandler based on your feedback. In the latest mailhandler release mailhandler should now be properly setting the comment status based on the permission system. When I test with mailhandler alone the status gets properly set. For example, if I use the following commands:

type: comment
nid: 156

the status for the comment will be set based on whether the user who is sending the comment has permissions to post comments w/o approval. In listhandler I see a part where listhandler tries to do this on line 650 " $node->status = user_access('post comments without approval') ? 0 : 1; " ... I am not sure whether this is the issue, but, as a start you could try commenting it out to see if it changes anything.

#7

Version:6.x-1.x-dev» 6.x-1.0
Category:support request» bug report
Status:active» fixed

yes! Thank you!
Commenting out line 650 solved the problem.
I'll make other tests but now all seems working properly.

#8

Status:fixed» active

Hi,

If this needs to be fixed, then leave this item active until such time as the Listhandler package has caught up.

Otherwise you will be patching Listhandler for ever release from now on.

#9

I can confirm this problem and solution.

With nodes, a status of 1 means published and a status of 0 means not published.

With comments, it's reversed.

listhandler code sets the status using the "comment method". mailhandler, when detecting that the node is a comment, assumes that the status is using the "node method" and will reverse the status flag.

I'm not really sure who is at fault - but am attaching a patch to listhandler to correct the problem.

jamie

AttachmentSize
listhandler.module.set_.status.diff 651 bytes

#12

Hi, I ran into this issue also. I even opened a bug on it in mailhandler because I didn't understand the problem was in listhandler (http://drupal.org/node/980266). This patch fixed my issue too. I am curious when the next stable release of listhandler will include this patch. Either way thanks for the patch!!

#13

Priority:normal» major
Status:active» needs review

#14

Title:comments remains unpublished» Comments remain unpublished
Priority:major» critical

Changed priority even higher since I realized it is after-all the main purpose of this module, to get these maillist emails show up correctly.

#15

Bumped, no news since a long time :(

#16

Version:6.x-1.0» master
Status:needs review» needs work

The code need to be changed as described in this issue.

#17

Assigned to:Anonymous» philipnet
Status:needs work» needs review

Committed to -dev release.
Please review/install it and feedback here.

Thanks.

#18

Thanks! I tested the latest -dev version , got the data from the IMAP server via Mailhandler, made sure all my permission settings where right and, Voila! posts got autopublished. So issue resolved.

#19

Priority:critical» major
Status:needs review» reviewed & tested by the community

#21

So, if this is already fixed in the repository, perhaps the issue can be marked as fixed?

#22

Also, when will the dev be respun into stable? After many things are tested?