Bug->Req #19378 [Opn->WFx]: Cannot preload items: limit

From: Date: Sat, 03 Nov 2012 19:58:52 +0000
Subject: Bug->Req #19378 [Opn->WFx]: Cannot preload items: limit
References: 1  Groups: php.pear.bugs 
Request: Send a blank email to pear-bugs+get-9285@lists.php.net to get a copy of this message
Edit report at https://pear.php.net/bugs/bug.php?id=19378&edit=1 ID: 19378 Updated by: till@php.net Reported By: pear at crewtax dot net Summary: Cannot preload items: limit -Status: Open +Status: Wont fix -Type: Bug +Type: Feature/Change Request Package: Mail_Queue Operating System: Linux Package Version: 1.2.7 PHP Version: 5.3.3 Roadmap Versions: New Comment: -Status: Open +Status: Wont fix -Type: Bug +Type: Feature/Change Request I can't reproduce this bug with the new codebase. If you guys want to have a look — this is almost done: https://github.com/pear2/Mail_Queue Otherwise, please re-open with a test case. Previous Comments: ------------------------------------------------------------------------ [2012-07-05 15:46:13] panamajo I ran into the same problem and solved it: This (bogus) error message always occurs when Mail_Queue::$limit % Mail_Queue_Container::$buffer_size == 0 The "Cannot initialize container" message is wrong. It is generated in Mail_Queue_Container->get() and apparently when it is executed we have a valid initialized container instance. I guess the 2 uses of MAILQUEUE_ERROR_CANNOT_INITIALIZE are a C&P error. Just replace the content in the 2nd condition: if ($err !== true) { // limit met return FALSE; } instead of returning a Mail_Queue_Error instance with a misleading message. ------------------------------------------------------------------------ [2012-04-09 03:15:13] truenorf Description: ------------ Still getting "Mail Queue Error: Cannot initialize container" and "Cannot preload items: limit" in ver 1.2.7 when trying to send 50 emails in a batch. Test script: --------------- //snip - - - $container_options and $mail_options init - - - /* How many mails could we send each time the script is called */ $max_amount_mails = 50; $mail_queue =& new Mail_Queue($container_options, $mail_options); $result = $mail_queue->sendMailsInQueue($max_amount_mails); Expected result: ---------------- 50 emails sent from queue Actual result: -------------- Some emails sent from queue (how many, I don't know?!) and the error messages: "Mail Queue Error: Cannot initialize container" and "Cannot preload items: limit" ------------------------------------------------------------------------ -- Edit this bug report at https://pear.php.net/bugs/bug.php?id=19378&edit=1

« previous php.pear.bugs (#9285) next »