YunoHost-Apps / opensondage_ynh

OpenSondage for YunoHost
https://framadate.org/
GNU Affero General Public License v3.0
16 stars 14 forks source link

phpmailerException 'Invalid address' on poll creation #31

Closed SiM closed 6 years ago

SiM commented 6 years ago

After an app update today (yunohost app upgrade opensondage -u https://github.com/YunoHost-apps/opensondage_ynh, it's impossible to create a new poll, I have a blank page after the submission of my poll.

php5-fpm.log :

[16-Apr-2018 22:14:51] WARNING: [pool opensondage] child 6139 said into stderr: "NOTICE: PHP message: PHP Fatal error:  Uncaught exception 'phpmailerException' with message 'Invalid address:  (punyEncode) tera' in /var/www/opensondage/vendor/phpmailer/phpmailer/class.phpmailer.php:1246"
[16-Apr-2018 22:14:51] WARNING: [pool opensondage] child 6139 said into stderr: "Stack trace:"
[16-Apr-2018 22:14:51] WARNING: [pool opensondage] child 6139 said into stderr: "#0 /var/www/opensondage/vendor/phpmailer/phpmailer/class.phpmailer.php(1200): PHPMailer->preSend()"
[16-Apr-2018 22:14:51] WARNING: [pool opensondage] child 6139 said into stderr: "#1 /var/www/opensondage/app/classes/Framadate/Services/MailService.php(54): PHPMailer->send()"
[16-Apr-2018 22:14:51] WARNING: [pool opensondage] child 6139 said into stderr: "#2 /var/www/opensondage/create_date_poll.php(230): Framadate\Services\MailService->send('xxx@xxx...', '[OpenSondage][R...', 'Ce message ne d...')"
[16-Apr-2018 22:14:51] WARNING: [pool opensondage] child 6139 said into stderr: "#3 {main}"
[16-Apr-2018 22:14:51] WARNING: [pool opensondage] child 6139 said into stderr: "  thrown in /var/www/opensondage/vendor/phpmailer/phpmailer/class.phpmailer.php on line 1246"

Using the same values for creating a poll in the previous opensondage version works.

It seems that the app takes now the 'admin login' instead of the 'admin mail' in the 'from' or 'respond to' field (in my case, the admin login is 'tera', as it appears in the first log line), that's why there is this exception.

# yunohost --version
yunohost: 
  repo: stable
  version: 2.7.10
yunohost-admin: 
  repo: stable
  version: 2.7.7
moulinette: 
  repo: stable
  version: 2.7.7
ssowat: 
  repo: stable
Jibec commented 6 years ago

You should check the value of ADRESSEMAILADMIN in /var/www/opensondage/app/inc/config.php, I Thanks for your report, I assume the value isn't good

maniackcrudelis commented 6 years ago

https://github.com/YunoHost-Apps/opensondage_ynh/blob/master/scripts/upgrade#L157 instead of https://github.com/YunoHost-Apps/opensondage_ynh/blob/master/scripts/install#L129