Smoke Tests Partial failure

Swift Mailer is a fantastic library for sending email with php. Discuss this library or ask any questions about it here.

Moderators: Chris Corbyn, General Moderators

Post Reply
Gaucho1
Forum Newbie
Posts: 5
Joined: Tue Feb 19, 2008 4:37 am

Smoke Tests Partial failure

Post by Gaucho1 »

Hi,

I have run two Smoke Tests, one for basic email and one for attachment.

The directory structure is as downloaded.

I receive both emails but the body is empty in both and no attachment in the second, also no error messages.

I have edited sendmail.php as per this thread which stopped one error message.

I also added the tags -oi -t as instructed by 1and1 to access sendmail. I'm not sure what any of the switches do (PHP thicko), so is this anything to do with -bs?

Thanks.
Gaucho1
Forum Newbie
Posts: 5
Joined: Tue Feb 19, 2008 4:37 am

Re: Smoke Tests Partial failure

Post by Gaucho1 »

By the way, this is the error I get if I use the -bs switch instead of -oi -t

Fatal error:
Uncaught Error of type [swift_connectionexception] with message [The sendmail process did not allow the command 'HELO [82.**5.97.**7]' to be sent.
Log Information
++ Log level changed to 4
++ Trying to connect...
++ Trying to start a sendmail process.
++ Trying to stat the executable '/usr/sbin/sendmail'.
<<
>> HELO [82.**5.97.**7]
]
@0 testofbasicsend::go() in /homepages/24/d2*******/htdocs/fake-cron2/backup/tests/smokes/runTestOfBasicSend.php on line 56
@1 swift::swift() in /homepages/24/d2*******/htdocs/fake-cron2/backup/tests/smokes/runTestOfBasicSend.php on line 13
@2 swift::connect() in /homepages/24/d2*******/htdocs/fake-cron2/backup/lib/Swift.php on line 109
@3 swift::handshake() in /homepages/24/d2*******/htdocs/fake-cron2/backup/lib/Swift.php on line 230

in /homepages/24/d2*******/htdocs/fake-cron2/backup/lib/Swift/Errors.php on line 99
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Re: Smoke Tests Partial failure

Post by Chris Corbyn »

It doesn't support -oi and -t (though version 4 will). You need -bs.

I experimented with -t in version 3 but it was just that... experimental ;)

Try with -bs.
Gaucho1
Forum Newbie
Posts: 5
Joined: Tue Feb 19, 2008 4:37 am

Re: Smoke Tests Partial failure

Post by Gaucho1 »

Thanks for the prompt reply.

I tried -bs but got the error in my second post.

Is this what is stopping attachments and message body from working properly?

As I said, I receive the emails using -oi -t but not complete.
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Re: Smoke Tests Partial failure

Post by Chris Corbyn »

Sorry, I misread your post :oops:

Sounds like 1and1 have really tight restrictions on your ability to execute commands via the shell. The NativeMail transport will relay the message through the mail() function (with attachments and such-like handled correctly). This may perhaps be your only option if you do not have a SMTP server to use. I actually seem to recall 1and1 having SMTP servers for their customers to use.

EDIT | The reason -oi -t is sending mail but doing it wrongly is because it's not tested. The code is there to generate the email and pass it to sendmail, but it's not done correctly... hence your problem. I've never supported -t (until v4). More specifically... the problem is going to be down to doubled-up line breaks in the message which have corrupted it.
Gaucho1
Forum Newbie
Posts: 5
Joined: Tue Feb 19, 2008 4:37 am

Re: Smoke Tests Partial failure

Post by Gaucho1 »

Thanks again.

I'll try NativeMail.

Smtp is a no go with 1and1, I think this has been discussed before regarding fsockopen errors, unless you know a way round it.
Gaucho1
Forum Newbie
Posts: 5
Joined: Tue Feb 19, 2008 4:37 am

Re: Smoke Tests Partial failure

Post by Gaucho1 »

Perfect, NativeMail works.

I'm I missing out on something using NativeMail though?
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Re: Smoke Tests Partial failure

Post by Chris Corbyn »

Gaucho1 wrote:I'm I missing out on something using NativeMail though?
Not too much on a linux host. There's a small optimization boost without it, but you still get the same attachments/embedded files etc features.
Post Reply