Open fischhase opened 1 year ago
I can confirm that the AnalyzeBounceMail Task failed to execute successfully. Error: Class "Fetch\Server" not found.
Environment: TYPO3 12.4.22 PHP 8.2 direct_mail 12.x https://github.com/kartolo/direct_mail/commit/500a858bd15c1c97300a35f1fa3c793db6c6c902 composer mode
warning-log:
Tue, 05 Nov 2024 00:30:01 +0100 [ERROR] request="4a13791b92622" component="TYPO3.CMS.Scheduler.Scheduler": Task failed to execute successfully. Class: DirectMailTeam\DirectMail\Scheduler\AnalyzeBounceMail, UID: 19, Code: 0, "Class "Fetch\Server" not found" in /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-core/Classes/Utility/GeneralUtility.php at line 2985- Error: Class "Fetch\Server" not found, in file /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-core/Classes/Utility/GeneralUtility.php:2985 - {"taskClass":"DirectMailTeam\\DirectMail\\Scheduler\\AnalyzeBounceMail","taskId":19,"exception":"Error: Class \"Fetch\\Server\" not found in /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-core/Classes/Utility/GeneralUtility.php:2985\nStack trace:\n#0 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/directmailteam/direct-mail/Classes/Scheduler/AnalyzeBounceMail.php(279): TYPO3\\CMS\\Core\\Utility\\GeneralUtility::makeInstance()\n#1 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/directmailteam/direct-mail/Classes/Scheduler/AnalyzeBounceMail.php(178): DirectMailTeam\\DirectMail\\Scheduler\\AnalyzeBounceMail->connectMailServer()\n#2 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-scheduler/Classes/Scheduler.php(175): DirectMailTeam\\DirectMail\\Scheduler\\AnalyzeBounceMail->execute()\n#3 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-scheduler/Classes/Command/SchedulerCommand.php(241): TYPO3\\CMS\\Scheduler\\Scheduler->executeTask()\n#4 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-scheduler/Classes/Command/SchedulerCommand.php(182): TYPO3\\CMS\\Scheduler\\Command\\SchedulerCommand->executeOrStopTask()\n#5 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-scheduler/Classes/Command/SchedulerCommand.php(116): TYPO3\\CMS\\Scheduler\\Command\\SchedulerCommand->loopTasks()\n#6 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/symfony/console/Command/Command.php(279): TYPO3\\CMS\\Scheduler\\Command\\SchedulerCommand->execute()\n#7 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/symfony/console/Application.php(1047): Symfony\\Component\\Console\\Command\\Command->run()\n#8 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/symfony/console/Application.php(316): Symfony\\Component\\Console\\Application->doRunCommand()\n#9 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/symfony/console/Application.php(167): Symfony\\Component\\Console\\Application->doRun()\n#10 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-core/Classes/Console/CommandApplication.php(112): Symfony\\Component\\Console\\Application->run()\n#11 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-cli/typo3(23): TYPO3\\CMS\\Core\\Console\\CommandApplication->run()\n#12 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-cli/typo3(24): {closure}()\n#13 /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/bin/typo3(119): include('...')\n#14 {main}","exceptionFile":"/var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-core/Classes/Utility/GeneralUtility.php","exceptionLine":2985,"code":0,"message":"Class \"Fetch\\Server\" not found"}
Tue, 05 Nov 2024 00:30:01 +0100 [CRITICAL] request="4a13791b92622" component="TYPO3.CMS.Core.Error.ProductionExceptionHandler": Core: Exception handler (CLI: BE): Error, code #0, file /var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-core/Classes/Utility/GeneralUtility.php, line 2985: Class "Fetch\Server" not found - {"mode":"CLI","application_mode":"BE","exception_class":"Error","exception_code":0,"file":"/var/www/vhosts/REMOVED/typo3_12.4_prod/vendor/typo3/cms-core/Classes/Utility/GeneralUtility.php","line":2985,"message":"Class \"Fetch\\Server\" not found","request_url":"http:///typo3_12.4_prod/vendor/bin/typo3","exception":null}
Fetch seems to be removed with https://github.com/kartolo/direct_mail/commit/99f46037a9aee83f3a1e0b79d59f65e4771207a3 but is used in deprecated AnalyzeBounceMail and AnalyzeBounceMailCommand. Workaround: require tedivm/fetch in your distribution/sitepackage.
Dear direct mail team,
thank you for the new version 9.4.0. I was longing for a solution of the Fetch/Server-Error, that appears, if you add the Task "Analyse Bounce Mail". Unfortunately the error still is there.
Ich use TYPO3 11.5.25 with your fresh Direct Mail 9.4.0. The server is a managed server from hetzner. With a different instance on anouther account of the server the Bounce-Task works fine. But I really do not get the differences between the two instances. The error-message is
`in /usr/www/users/XXX/typo3/typo3_src-11.5.25/typo3/sysext/core/Classes/Utility/GeneralUtility.php line 3217 return self::$container->get($className); }
at TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('Fetch\Server', '', 0, 'imap') in /usr/www/users/XXX/webseite/XXX.com/typo3conf/ext/direct_mail/Classes/Scheduler/AnalyzeBounceMailAdditionalFields.php line 120 $mailServer = GeneralUtility::makeInstance( \Fetch\Server::class, $submittedData['bounceServer'], (int)$submittedData['bouncePort'], $submittedData['bounceService'] );
at DirectMailTeam\DirectMail\Scheduler\AnalyzeBounceMailAdditionalFields->validateAdditionalFields(array('uid' => 0, 'disable' => '0', 'class' => 'DirectMailTeam\DirectMail\Scheduler\AnalyzeBounceMail', 'type' => '2', 'task_group' => '0', 'start' => 1687771871, 'end' => '', 'frequency' => '', 'multiple' => '0', 'description' => '', 'bounceServer' => '', 'bouncePort' => '', 'bounceUser' => '', 'bouncePassword' => '', 'bounceService' => 'imap', 'bounceProcessed' => '', 'interval' => 0, 'croncmd' => ''), object(TYPO3\CMS\Scheduler\Controller\SchedulerModuleController)) in /usr/www/users/XXX/typo3/typo3_src-11.5.25/typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php line 1253 $providerObject = GeneralUtility::makeInstance($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['scheduler']['tasks'][$this->submittedData['class']]['additionalFields']); if ($providerObject instanceof AdditionalFieldProviderInterface) { // The validate method will return true if all went well, but that must not // override previous false values => AND the returned value with the existing one $result &= $providerObject->validateAdditionalFields($this->submittedData, $this); } } return (bool)$result; }`
Thanks for have a look. Martin