Hi guys,
After the release of Wordpress 6.0 I updated the roots/wordpress
version in my composer.json in an existing project to 6.0 like in this Bedrock commit:
"roots/wordpress": "^6.0",
"wpackagist-theme/twentytwentytwo": "^1.2"
Locally this worked great, I can see the wp-content folder is not there anymore.
However, when I tried to deploy these changes to an existing staging droplet, I’m getting his error:
TASK [deploy : WordPress Installed?] *******************************************
System info:
Ansible 2.10.17; Darwin
Trellis version (per changelog): "Improve handling of PHP versions and support PHP 8.0"
---------------------------------------------------
Warning: strpos(): Empty needle in
/srv/www/mydomain/releases/20220525094312/web/wp/wp-includes/link-template.php
on line 3535
Warning: strpos(): Empty needle in
/srv/www/mydomain/releases/20220525094312/web/wp/wp-includes/link-template.php
on line 3535
fatal: [82.196.1.191]: FAILED! => {"changed": false, "cmd": ["wp", "core", "is-installed", "--skip-plugins", "--skip-themes", "--require=/srv/www/mydomain/shared/tmp_multisite_constants.php"], "delta": "0:00:01.115367", "end": "2022-05-25 09:44:01.258353", "failed_when_result": true, "rc": 0, "start": "2022-05-25 09:44:00.142986", "stderr": "Warning: strpos(): Empty needle in /srv/www/mydomain/releases/20220525094312/web/wp/wp-includes/link-template.php on line 3535\nWarning: strpos(): Empty needle in /srv/www/mydomain/releases/20220525094312/web/wp/wp-includes/link-template.php on line 3535", "stderr_lines": ["Warning: strpos(): Empty needle in /srv/www/mydomain/releases/20220525094312/web/wp/wp-includes/link-template.php on line 3535", "Warning: strpos(): Empty needle in /srv/www/mydomain/releases/20220525094312/web/wp/wp-includes/link-template.php on line 3535"], "stdout": "", "stdout_lines": []}
When I lookup the strpos
function call in link-template.php
on line 3535:
$mu_plugin_dir = wp_normalize_path( WPMU_PLUGIN_DIR );
if ( ! empty( $plugin ) && 0 === strpos( $plugin, $mu_plugin_dir ) ) {
$url = WPMU_PLUGIN_URL;
} else {
$url = WP_PLUGIN_URL;
}
It seems the $mu_plugin_dir
variable is empty?
Any ideas what’s going on here?
I already merged this Bedrock commit for the new Bedrock autoloader?
Downgrading roots/wordpress
to ^5.9
fixes the failing deploys for now.
Thanks!