Closed (fixed)
Project:
Simplenews
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
10 Sep 2008 at 21:04 UTC
Updated:
5 Oct 2008 at 12:52 UTC
Jump to comment: Most recent file
Comments
Comment #1
thomas23@drupal.org commentedComment #2
Garrett Albright commentedFound the problem!
I've got a meeting right now and don't have time to explain things thoroughly or roll a patch. Suffice it to say that check_markup() is being called twice because node_prepare() is being called twice and deleting the line
from simplenews_mail() solves the problem.
Comment #3
Garrett Albright commentedOkay, that meeting was shorter than expected. Here's the entirely unexciting patch, rolled against the latest dev release.
Comment #4
sutharsan commentedI think calling node_prepare is fully valid. Plain text email should have this called.
Comment #5
Garrett Albright commentedIt's being called twice, though. First by node_build_content(), and then again directly.
Comment #6
sutharsan commentedAgree, the problem is clear. But it is only called twice when simplenews and mimemail work together. When simplenews is used without mime mail is still needs node_prepare(). The next question is where is the right place to solve this. I am still not sure why mime mail needs to filter the email content.
Comment #7
Garrett Albright commentedI don't see anything which is causing either node_build_content() or node_prepare() to only be called when Mime Mail is installed, though. This bug is totally independent of Mime Mail's presence.
Comment #8
luti commentedIt seems everything works fine if I send HTML. When sending PLAIN, linebreaks are not present, so everything seems to be one big paragraph...
I have Simplenews 6.x-1.x-dev version from 2008-Sep-02 with above patch #3 and simplenews-mimemail.patch (issue Restore Mime Mail support in D6 / #3) applied
Mimemail itself is the mimemail-6.x-0.9.tar_.gz version (issue Upgrade Mime Mail to Drupal 6 / #102), with a mimemail-no-alter.patch (issue Upgrade Mime Mail to Drupal 6 / #125) applied.
I have the impression there is a quite big confusion with versions and patches applied to them - so we have many times more or less different code installed, but discuss about the same... It would be nice to have both Simplenews as well as Mime Mail (at least alpha-x) versions available, to be able to refer to some particular version when describing some issue (as above)...
Comment #9
thomas23@drupal.org commentedI agree with LUTi! In addition, even though I haven't tested (still no time :( ) my guess would be that patch #3 wouldn't solve the paragraph issue on my end. I only have simplenews installed. If I understand everything well from this diskussion
node_prepare()is only called twice with mime mail installed (which I haven't and still acknowledge the paragraph issue).Still trying to get to the source ;) (trying to find some time to digg in). Cheers.
Comment #10
Garrett Albright commentedMy latest patch for Simplenews should fix the problem with line endings being clobbered in plain text versions of messages being sent with Mime Mail. thomas, if this is happening without Mime Mail, sorry, but I'm not going to be the one to fix it.
Comment #11
sutharsan commentedI finally had the time to test this and now I understand the fault. In simplenews_mail() check_markup() is first called by node_build_content() and next by node_prepare(). But that's what Garret said all the time ;)
Patch committed. Thanks!
Comment #12
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.