Weird problem with Zend_Mail

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Weird problem with Zend_Mail

Ralf Eggert
Hi,

I just updated to ZF 0.8.0 and have problems with some of my local unit
tests which test. The messages I get look just weird to me:

------------------------------------------------------------------------
Fatal error: Exception thrown without a stack frame in Unknown on line 0

Call Stack:
    0.0017   1. {main}() E:\_library\PHPUnit\TextUI\Command.php:0
    0.2168   2. PHPUnit_TextUI_Command::main()
E:\_library\PHPUnit\TextUI\Command.php:401

Warning: Unknown: Failed to write session data (user). Please verify
that the current setting of session.save_path is correct () in Unknown
on line 0

Call Stack:
    0.0017   1. {main}() E:\_library\PHPUnit\TextUI\Command.php:0
    0.2168   2. PHPUnit_TextUI_Command::main()
E:\_library\PHPUnit\TextUI\Command.php:401
------------------------------------------------------------------------

It took me some while to track down the code line which causes this
problem. I finally found it in Zend_Mail_Protocol_Smtp::_startSession().
When I comment out the single line, these message are not shown any more
but an exception is thrown:

------------------------------------------------------------------------
Zend_Mail_Protocol_Exception: A valid session has not been started
E:\_library\Zend\Mail\Transport\Smtp.php:185
E:\_library\Zend\Mail\Transport\Abstract.php:330
E:\_library\Zend\Mail.php:563
E:\www.travello-dev.com\tests\unit\framework\MailTest.php:68
------------------------------------------------------------------------

This exception makes sense to me since there is a check for $this->_sess
in Zend_Mail_Protocol_Smtp::mail() method.

What I do not understand is, why the single line 399 in
Zend_Mail_Protocol_Smtp::_startSession() is causing this problem by just
setting the $this->_sess value to true.

To give some further information. I am working on a Win XP machine and I
am using Fakemail as a local mailer daemon to check in my unit tests if
the mails are sent as expected. With the nightly 20070215-3419 I used
before I upgraded to ZF 0.8.0 this problem did not occur.

Is this worth to open a new issue for it?

Best Regards,

Ralf

Reply | Threaded
Open this post in threaded view
|

Re: Weird problem with Zend_Mail

marcis
Hi Ralf,

It's a long time ago, but did you guess what happened about this issue? I'm having the same problem...

Thanks

Ralf Eggert wrote
Hi,

I just updated to ZF 0.8.0 and have problems with some of my local unit
tests which test. The messages I get look just weird to me:

------------------------------------------------------------------------
Fatal error: Exception thrown without a stack frame in Unknown on line 0

Call Stack:
    0.0017   1. {main}() E:\_library\PHPUnit\TextUI\Command.php:0
    0.2168   2. PHPUnit_TextUI_Command::main()
E:\_library\PHPUnit\TextUI\Command.php:401

Warning: Unknown: Failed to write session data (user). Please verify
that the current setting of session.save_path is correct () in Unknown
on line 0

Call Stack:
    0.0017   1. {main}() E:\_library\PHPUnit\TextUI\Command.php:0
    0.2168   2. PHPUnit_TextUI_Command::main()
E:\_library\PHPUnit\TextUI\Command.php:401
------------------------------------------------------------------------

It took me some while to track down the code line which causes this
problem. I finally found it in Zend_Mail_Protocol_Smtp::_startSession().
When I comment out the single line, these message are not shown any more
but an exception is thrown:

------------------------------------------------------------------------
Zend_Mail_Protocol_Exception: A valid session has not been started
E:\_library\Zend\Mail\Transport\Smtp.php:185
E:\_library\Zend\Mail\Transport\Abstract.php:330
E:\_library\Zend\Mail.php:563
E:\www.travello-dev.com\tests\unit\framework\MailTest.php:68
------------------------------------------------------------------------

This exception makes sense to me since there is a check for $this->_sess
in Zend_Mail_Protocol_Smtp::mail() method.

What I do not understand is, why the single line 399 in
Zend_Mail_Protocol_Smtp::_startSession() is causing this problem by just
setting the $this->_sess value to true.

To give some further information. I am working on a Win XP machine and I
am using Fakemail as a local mailer daemon to check in my unit tests if
the mails are sent as expected. With the nightly 20070215-3419 I used
before I upgraded to ZF 0.8.0 this problem did not occur.

Is this worth to open a new issue for it?

Best Regards,

Ralf