Updated my composer.json to use WP 4.6. Fails on deploy. Here is the failure stack:
System info:
Ansible 2.0.2.0; Darwin
Trellis at "Fix #569 - Only skip subdomains for non-www domains"
---------------------------------------------------
PHP Fatal error: Uncaught Error: Call to undefined function apply_filters()
in /srv/www/thinlyveiledcontempt.com/releases/20160822152633/web/wp/wp-
includes/load.php:317
Stack trace:
#0 phar:///usr/bin/wp/php/utils-wp.php(22): wp_debug_mode()
#1 phar:///usr/bin/wp/php/wp-settings-cli.php(59):
WP_CLI\Utils\wp_debug_mode()
#2 phar:///usr/bin/wp/php/WP_CLI/Runner.php(807):
require('phar:///usr/bin...')
#3 phar:///usr/bin/wp/php/WP_CLI/Runner.php(755):
WP_CLI\Runner->load_wordpress()
#4 phar:///usr/bin/wp/php/wp-cli.php(21): WP_CLI\Runner->start()
#5 phar:///usr/bin/wp/php/boot-phar.php(5): include('phar:///usr/bin...')
#6 /usr/bin/wp(4): include('phar:///usr/bin...')
#7 {main}
thrown in /srv/www/thinlyveiledcontempt.com/releases/20160822152633/web/wp
/wp-includes/load.php on line 317
fatal: [thinlyveiledcontempt.com]: FAILED! => {"changed": false, "cmd": ["wp", "core", "is-installed"], "delta": "0:00:00.125996", "end": "2016-08-22 15:26:46.924832", "failed": true, "failed_when_result": true, "rc": 255, "start": "2016-08-22 15:26:46.798836", "stderr": "PHP Fatal error: Uncaught Error: Call to undefined function apply_filters() in /srv/www/thinlyveiledcontempt.com/releases/20160822152633/web/wp/wp-includes/load.php:317\nStack trace:\n#0 phar:///usr/bin/wp/php/utils-wp.php(22): wp_debug_mode()\n#1 phar:///usr/bin/wp/php/wp-settings-cli.php(59): WP_CLI\\Utils\\wp_debug_mode()\n#2 phar:///usr/bin/wp/php/WP_CLI/Runner.php(807): require('phar:///usr/bin...')\n#3 phar:///usr/bin/wp/php/WP_CLI/Runner.php(755): WP_CLI\\Runner->load_wordpress()\n#4 phar:///usr/bin/wp/php/wp-cli.php(21): WP_CLI\\Runner->start()\n#5 phar:///usr/bin/wp/php/boot-phar.php(5): include('phar:///usr/bin...')\n#6 /usr/bin/wp(4): include('phar:///usr/bin...')\n#7 {main}\n thrown in /srv/www/thinlyveiledcontempt.com/releases/20160822152633/web/wp/wp-includes/load.php on line 317", "stdout": "", "stdout_lines": [], "warnings": []}
I saw #639, which mentioned a need for an updated wp-cli to work with 4.6, so I updated the file in question (/trellis/roles/wp-cli/defaults/main.yml) with the version in the commit, but it is still failing. Could use some help.
I’m going to manually SSH into the instance and update wp-cli to the latest version. I’ll update if it helps.
It did.
I’ve root access disabled, so I used ssh admin@site.com to login to the instance. Running wp cli update fails with Error: /usr/bin/wp is not writable by current user, but you can overcome that with sudo wp cli update --allow-root.
So it seems like wp-cli is in limbo waiting for that upstream project to update so they can tag a new release, but they seem to have hacked in the necessary fix to resolve this issue in an intermediate commit. How can I edit ~/site/trellis/roles/wp-cli/defaults/main.yml to pull down dev-master commit of wp-cli instead of a tagged release? Is that even possible with the method Trellis uses to obtain it?
You can try to update the file I mentioned in the last post to download the master package from their github. it looks like they merge in a change which is pulling from the dev version of the software that is causing the issue. if you do that, it should let you update.