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

WordPress 4.6 issues #646

Closed
swalkinshaw opened this issue Aug 31, 2016 · 4 comments
Closed

WordPress 4.6 issues #646

swalkinshaw opened this issue Aug 31, 2016 · 4 comments

Comments

@swalkinshaw
Copy link
Member

This is the new main tracking issue for 4.6 issues.

Related issues:

And Discourse threads:

There are 2 distinct issues here:

  • Emails are failing causing WP install to be shown as failed in development. WP actually gets installed and the site does work. The error message looks like this:
TASK [wordpress-install : Install WP] ******************************************
System info:
  Ansible 2.0.2.0; Vagrant 1.8.5; Darwin
  Trellis at "Create WordPress php-fpm conf after web_root exists"
---------------------------------------------------
PHP Fatal error:  Uncaught phpmailerException: Invalid address:
wordpress@${http_host} in /srv/www/example.com/current/web/wp/wp-includes
/class-phpmailer.php:946
Stack trace:
#0 /srv/www/example.com/current/web/wp/wp-includes/pluggable.php(352):
PHPMailer->setFrom('wordpress@${htt...', 'WordPress')
#1 /srv/www/example.com/current/web/wp/wp-admin/includes/upgrade.php(392):
wp_mail('admin@example.d...', 'New WordPress S...', 'Your new WordPr...')
#2 /srv/www/example.com/current/web/wp/wp-admin/includes/upgrade.php(95):
wp_new_blog_notification('example.com', 'http://${HTTP_H...', 1, 'The
password yo...')
#3 phar:///usr/bin/wp/php/commands/core.php(763): wp_install('example.com',
'admin', 'admin@example.d...', true, '', 'admin')
#4 phar:///usr/bin/wp/php/commands/core.php(573):
Core_Command->_install(Array)
#5 [internal function]: Core_Command->install(Array, Array)
#6 phar:///usr/bin/wp/php/WP_CLI/Dispatcher/CommandFactory.php(67):
call_user_func(Array, Array, Array)
#7 [internal function]: WP_CLI\Dispatcher\CommandFactory::WP_C in
/srv/www/example.com/current/web/wp/wp-includes/class-phpmailer.php on line
946
failed: [default] (item=example.com) => {"changed": true, "cmd": ["wp", "core", "install", "--allow-root", "--url=http://${HTTP_HOST}", "--title=example.com", "--admin_user=admin", "--admin_password=admin", "--admin_email=admin@example.dev"], "delta": "0:00:01.239875", "end": "2016-08-31 02:19:27.143563", "failed": true, "item": "example.com", "rc": 255, "start": "2016-08-31 02:19:25.903688", "stderr": "PHP Fatal error:  Uncaught phpmailerException: Invalid address: wordpress@${http_host} in /srv/www/example.com/current/web/wp/wp-includes/class-phpmailer.php:946\nStack trace:\n#0 /srv/www/example.com/current/web/wp/wp-includes/pluggable.php(352): PHPMailer->setFrom('wordpress@${htt...', 'WordPress')\n#1 /srv/www/example.com/current/web/wp/wp-admin/includes/upgrade.php(392): wp_mail('admin@example.d...', 'New WordPress S...', 'Your new WordPr...')\n#2 /srv/www/example.com/current/web/wp/wp-admin/includes/upgrade.php(95): wp_new_blog_notification('example.com', 'http://${HTTP_H...', 1, 'The password yo...')\n#3 phar:///usr/bin/wp/php/commands/core.php(763): wp_install('example.com', 'admin', 'admin@example.d...', true, '', 'admin')\n#4 phar:///usr/bin/wp/php/commands/core.php(573): Core_Command->_install(Array)\n#5 [internal function]: Core_Command->install(Array, Array)\n#6 phar:///usr/bin/wp/php/WP_CLI/Dispatcher/CommandFactory.php(67): call_user_func(Array, Array, Array)\n#7 [internal function]: WP_CLI\\Dispatcher\\CommandFactory::WP_C in /srv/www/example.com/current/web/wp/wp-includes/class-phpmailer.php on line 946", "stdout": "", "stdout_lines": [], "warnings": []}

WordPress/WordPress@905f4ec is the cause of this problem.

  • Deploys were erroring due to a WP-CLI incompatibility with WP 4.6. WP-CLI 0.24.0 fixed this.
@runofthemill
Copy link
Contributor

Re: the first issue - I haven't done any testing beyond my system, but this works:

  • update geerlingguy.composer in requirements.yml to 1.4.2
  • in helpers.yml set wp_home to "{{ item.value.ssl.enabled | default(false) | ternary('https', 'http') }}://{{ ansible_fqdn }}"

Running the following:

Ansible 2.0.2.0

OSX 10.11.6

Vagrant 1.8.5

Since deploy.yml also sets wp_home, that probably needs to be changed too, but I haven't provisioned/deployed to a remote server yet.

@solace
Copy link

solace commented Aug 31, 2016

I was going to amend my comment in #639, but just wanted to add, even if you have updated WP-CLI, the error appears to be intermittent. Rerunning vagrant reload --provision occasionally succeeds. So if you're still seeing this error, try another couple of times and it might come good.

@swalkinshaw
Copy link
Member Author

@runofthemill interesting solution. Check out #647 where I did something similar. I hadn't though of using ansible_fqdn.

@swalkinshaw
Copy link
Member Author

Closing since both issues have been addressed and fixed.

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

3 participants