Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If error occurs on sending email for double optin, "Oops an error occurred" is displayed (instead of flash message) #1115

Open
sypets opened this issue Aug 29, 2024 · 0 comments

Comments

@sypets
Copy link
Contributor

sypets commented Aug 29, 2024

I tested this with a wrong not existing email and also a wrongly configured email configuration with same results.

I expect a flash message to appear, not an exception. If the email fails in the next stage (e.g. mail to receiver) it does not throw exception, but shows a flash message theoretically (if not for #1108, #1087 etc - which I did not check now, if still reprodible).

This behaviour is inconsistent.

Also, I think this is new and previously this "seemed" to work and a confirmation messages was displayed (which is also not right).

Reproduce

  1. Create working form with double-optin and an email field

image

image

  1. In the frontend, fill out not existing email and submit form

Expected: Flash message with error message

Actual result:

Oops, an error occurred! Code: 202408291448112ee11570

Versions

  • TYPO3 : latest 12.4 branch (from git)
  • powermail: lastest master branch (shows version 12.4.0)

Additional context

I installed with latest master and without additional extensions to rule out side effects, so it is simple configuration with defaults.

I am on a system where I immediately get error if mail fails (configured via SMTP). This is not always the case, see Avoid sending bounces from your server, so depending on email configuration, a bounce email might be sent instead and the user sees no error at all.

Exception

Thu, 29 Aug 2024 16:30:31 +0200 [ALERT] request="9f13f63495e73" component="TYPO3.CMS.Frontend.ContentObject.Exception.ProductionExceptionHandler":
 Oops, an error occurred! Code: 202408291630305b25c4b1- UnexpectedResponseException: 
Expected response code "250/251/252" but got code "550", with message "550 5.1.1 
<fehlerhafte-email@******>... User unknown"., 
in file /var/www/t3coredev12/vendor/symfony/mailer/Transport/Smtp/SmtpTransport.php:333 - 
{"exception":"Symfony\\Component\\Mailer\\Exception\\UnexpectedResponseException: Expected response code \"250/251/252\" but got code \"550\", with message \"550 5.1.1 <fehlerhafte-email@uol.de>... User unknown\". in /var/www/t3coredev12/vendor/symfony/mailer/Transport/Smtp/SmtpTransport.php:333

Stack trace:

#0 /var/www/t3coredev12x/vendor/symfony/mailer/Transport/Smtp/SmtpTransport.php(201): Symfony\\Component\\Mailer\\Transport\\Smtp\\SmtpTransport->assertResponseCode()
#1 /var/www/t3coredev12x/vendor/symfony/mailer/Transport/Smtp/EsmtpTransport.php(117): Symfony\\Component\\Mailer\\Transport\\Smtp\\SmtpTransport->executeCommand()
#2 /var/www/t3coredev12x/vendor/symfony/mailer/Transport/Smtp/SmtpTransport.php(259): Symfony\\Component\\Mailer\\Transport\\Smtp\\EsmtpTransport->executeCommand()
#3 /var/www/t3coredev12x/vendor/symfony/mailer/Transport/Smtp/SmtpTransport.php(218): Symfony\\Component\\Mailer\\Transport\\Smtp\\SmtpTransport->doMailFromCommand()
#4 /var/www/t3coredev12x/vendor/symfony/mailer/Transport/AbstractTransport.php(90): Symfony\\Component\\Mailer\\Transport\\Smtp\\SmtpTransport->doSend()
#5 /var/www/t3coredev12x/vendor/symfony/mailer/Transport/Smtp/SmtpTransport.php(137): Symfony\\Component\\Mailer\\Transport\\AbstractTransport->send()
#6 /var/www/t3coredev12x/typo3/sysext/core/Classes/Mail/Mailer.php(111): Symfony\\Component\\Mailer\\Transport\\Smtp\\SmtpTransport->send()
#7 /var/www/t3coredev12x/typo3/sysext/core/Classes/Mail/MailMessage.php(54): TYPO3\\CMS\\Core\\Mail\\Mailer->send()
#8 /var/www/t3coredev12x/typo3conf/ext/powermail/Classes/Domain/Service/Mail/SendMailService.php(148): TYPO3\\CMS\\Core\\Mail\\MailMessage->send()
#9 /var/www/t3coredev12x/typo3conf/ext/powermail/Classes/Domain/Service/Mail/SendMailService.php(107): In2code\\Powermail\\Domain\\Service\\Mail\\SendMailService->prepareAndSend()
#10 /var/www/t3coredev12x/typo3conf/ext/powermail/Classes/Domain/Service/Mail/SendOptinConfirmationMailPreflight.php(83): In2code\\Powermail\\Domain\\Service\\Mail\\SendMailService->sendMail()
#11 /var/www/t3coredev12x/typo3conf/ext/powermail/Classes/Controller/FormController.php(337): In2code\\Powermail\\Domain\\Service\\Mail\\SendOptinConfirmationMailPreflight->sendOptinConfirmationMail()
#12 /var/www/t3coredev12x/typo3/sysext/extbase/Classes/Mvc/Controller/ActionController.php(479): In2code\\Powermail\\Controller\\FormController->createAction()
....

stack_trace_powermail_email.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant