[wp-trac] [WordPress Trac] #54547: Fatal error when updating to 5.9 Beta 1 using WP-CLI on LocalWP

WordPress Trac noreply at wordpress.org
Wed Dec 1 20:37:08 UTC 2021


#54547: Fatal error when updating to 5.9 Beta 1 using WP-CLI on LocalWP
-----------------------------+---------------------
 Reporter:  nielslange       |       Owner:  (none)
     Type:  defect (bug)     |      Status:  new
 Priority:  normal           |   Milestone:  5.9
Component:  Upgrade/Install  |     Version:
 Severity:  blocker          |  Resolution:
 Keywords:                   |     Focuses:
-----------------------------+---------------------

Comment (by hellofromTonya):

 = Test Report

 Env:
 * OS: macOS Big Sur
 * Localhost: Local
 * WP-CLI (through Local's site shell)
 * Plugins: Core Rollback and Beta Tester

 Steps:
 1. Open the site shell through Local
 2. Type: `wp core update --version=5.9-beta1`
 3. Press enter/return key.
 4. After update, check error logs and ensure all Requests files are
 present.

 Results:
 * 59 files clean up
 {{{
 Updating to version 5.9-beta1 (en_US)...
 Downloading update from https://wordpress.org/wordpress-5.9-beta1.zip...
 Unpacking the update...
 Cleaning up files...
 File removed: wp-includes/Requests/Transport/fsockopen.php
 File removed: wp-includes/Requests/Transport/cURL.php
 File removed: wp-includes/Requests/Hooker.php
 File removed: wp-includes/Requests/IPv6.php
 File removed: wp-includes/Requests/Exception/Transport/cURL.php
 File removed: wp-includes/Requests/Exception/HTTP.php
 File removed: wp-includes/Requests/Exception/HTTP/502.php
 File removed: wp-includes/Requests/Exception/HTTP/Unknown.php
 File removed: wp-includes/Requests/Exception/HTTP/412.php
 File removed: wp-includes/Requests/Exception/HTTP/408.php
 File removed: wp-includes/Requests/Exception/HTTP/431.php
 File removed: wp-includes/Requests/Exception/HTTP/501.php
 File removed: wp-includes/Requests/Exception/HTTP/500.php
 File removed: wp-includes/Requests/Exception/HTTP/407.php
 File removed: wp-includes/Requests/Exception/HTTP/416.php
 File removed: wp-includes/Requests/Exception/HTTP/428.php
 File removed: wp-includes/Requests/Exception/HTTP/406.php
 File removed: wp-includes/Requests/Exception/HTTP/504.php
 File removed: wp-includes/Requests/Exception/HTTP/411.php
 File removed: wp-includes/Requests/Exception/HTTP/414.php
 File removed: wp-includes/Requests/Exception/HTTP/511.php
 File removed: wp-includes/Requests/Exception/HTTP/410.php
 File removed: wp-includes/Requests/Exception/HTTP/403.php
 File removed: wp-includes/Requests/Exception/HTTP/400.php
 File removed: wp-includes/Requests/Exception/HTTP/505.php
 File removed: wp-includes/Requests/Exception/HTTP/413.php
 File removed: wp-includes/Requests/Exception/HTTP/404.php
 File removed: wp-includes/Requests/Exception/HTTP/306.php
 File removed: wp-includes/Requests/Exception/HTTP/304.php
 File removed: wp-includes/Requests/Exception/HTTP/405.php
 File removed: wp-includes/Requests/Exception/HTTP/429.php
 File removed: wp-includes/Requests/Exception/HTTP/417.php
 File removed: wp-includes/Requests/Exception/HTTP/409.php
 File removed: wp-includes/Requests/Exception/HTTP/402.php
 File removed: wp-includes/Requests/Exception/HTTP/418.php
 File removed: wp-includes/Requests/Exception/HTTP/305.php
 File removed: wp-includes/Requests/Exception/HTTP/415.php
 File removed: wp-includes/Requests/Exception/HTTP/401.php
 File removed: wp-includes/Requests/Exception/HTTP/503.php
 File removed: wp-includes/Requests/IRI.php
 File removed: wp-includes/Requests/IDNAEncoder.php
 File removed: wp-includes/Requests/SSL.php
 File removed: wp-includes/Requests/Proxy/HTTP.php
 File removed: wp-includes/blocks/post-content/editor.min.css
 File removed: wp-includes/blocks/post-content/editor.css
 File removed: wp-includes/blocks/post-content/editor-rtl.css
 File removed: wp-includes/blocks/post-content/editor-rtl.min.css
 File removed: wp-includes/blocks/heading/editor.min.css
 File removed: wp-includes/blocks/heading/editor.css
 File removed: wp-includes/blocks/heading/editor-rtl.css
 File removed: wp-includes/blocks/heading/editor-rtl.min.css
 File removed: wp-includes/blocks/query-title/editor.min.css
 File removed: wp-includes/blocks/query-title/editor.css
 File removed: wp-includes/blocks/query-title/editor-rtl.css
 File removed: wp-includes/blocks/query-title/editor-rtl.min.css
 File removed: wp-includes/blocks/tag-cloud/editor.min.css
 File removed: wp-includes/blocks/tag-cloud/editor.css
 File removed: wp-includes/blocks/tag-cloud/editor-rtl.css
 File removed: wp-includes/blocks/tag-cloud/editor-rtl.min.css
 59 files cleaned up.
 }}}

 * error log in Local's `logs/php/error.log`

 {{{
 [01-Dec-2021 20:03:24 UTC] PHP Notice:  Constant WP_ENVIRONMENT_TYPE
 already defined in
 phar:///Applications/Local.app/Contents/Resources/extraResources/bin/wp-
 cli/wp-cli.phar/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php(1231) :
 eval()'d code on line 71
 [01-Dec-2021 20:03:24 UTC] PHP Stack trace:
 [01-Dec-2021 20:03:24 UTC] PHP   1. {main}()
 /Applications/Local.app/Contents/Resources/extraResources/bin/wp-cli/wp-
 cli.phar:0
 [01-Dec-2021 20:03:24 UTC] PHP   2. include()
 /Applications/Local.app/Contents/Resources/extraResources/bin/wp-cli/wp-
 cli.phar:4
 [01-Dec-2021 20:03:24 UTC] PHP   3. include()
 phar:///Applications/Local.app/Contents/Resources/extraResources/bin/wp-
 cli/wp-cli.phar/php/boot-phar.php:11
 [01-Dec-2021 20:03:24 UTC] PHP   4. WP_CLI\bootstrap()
 phar:///Applications/Local.app/Contents/Resources/extraResources/bin/wp-
 cli/wp-cli.phar/vendor/wp-cli/wp-cli/php/wp-cli.php:27
 [01-Dec-2021 20:03:24 UTC] PHP   5.
 WP_CLI\Bootstrap\LaunchRunner->process()
 phar:///Applications/Local.app/Contents/Resources/extraResources/bin/wp-
 cli/wp-cli.phar/vendor/wp-cli/wp-cli/php/bootstrap.php:77
 [01-Dec-2021 20:03:24 UTC] PHP   6. WP_CLI\Runner->start()
 phar:///Applications/Local.app/Contents/Resources/extraResources/bin/wp-
 cli/wp-cli.phar/vendor/wp-cli/wp-
 cli/php/WP_CLI/Bootstrap/LaunchRunner.php:23
 [01-Dec-2021 20:03:24 UTC] PHP   7. WP_CLI\Runner->load_wordpress()
 phar:///Applications/Local.app/Contents/Resources/extraResources/bin/wp-
 cli/wp-cli.phar/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php:1192
 [01-Dec-2021 20:03:24 UTC] PHP   8. eval()
 phar:///Applications/Local.app/Contents/Resources/extraResources/bin/wp-
 cli/wp-cli.phar/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php:1231
 [01-Dec-2021 20:03:24 UTC] PHP   9. define()
 phar:///Applications/Local.app/Contents/Resources/extraResources/bin/wp-
 cli/wp-cli.phar/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php(1231) :
 eval()'d code:71
 }}}

 * Go to a page in the admin area - Fatal error.

 {{{
 [01-Dec-2021 20:26:33 UTC] PHP Fatal error:  Uncaught Error: Class
 'WpOrg\Requests\Iri' not found in ../Local/test/app/public/wp-
 includes/Requests/Requests.php:682
 Stack trace:
 #0 ../Local/test/app/public/wp-includes/Requests/Requests.php(452):
 WpOrg\Requests\Requests::set_defaults('https://api.wor...', Array, Array,
 'POST', Array)
 #1 ../Local/test/app/public/wp-includes/class-wp-http.php(394):
 WpOrg\Requests\Requests::request('https://api.wor...', Array, Array,
 'POST', Array)
 #2 ../Local/test/app/public/wp-includes/class-wp-http.php(614):
 WP_Http->request('https://api.wor...', Array)
 #3 ../Local/test/app/public/wp-includes/http.php(179):
 WP_Http->post('https://api.wor...', Array)
 #4 ../Local/test/app/public/wp-includes/update.php(404):
 wp_remote_post('https://api.wor...', Array)
 #5 ../Local/test/app/public/wp-includes/class-wp-hook.php(303):
 wp_update_plugins('')
 #6 ../Local/test/app/public/wp-includes/class-wp-hook.php(327):
 WP_Hook->apply_filters(' in ../Local/test/app/public/wp-
 includes/Requests/Requests.php on line 682
 }}}

 * Looking at the filesystem in `wp-includes/Requests/` folder. Files are
 missing:
    * `wp-includes/Requests/IdnaEncoder.php`
    * `wp-includes/Requests/Ipv6.php`
    * `wp-includes/Requests/Iri.php`
    * `wp-includes/Requests/Ssl.php`
    * `wp-includes/Requests/Exception/Http.php`
    * `wp-includes/Requests/Proxy/Http.php`
    * `wp-includes/Requests/Transport/Curl.php`
    * `wp-includes/Requests/Transport/Fsockopen.php`

 This problem is not limited to Windows OS. It's also happening on macOS.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/54547#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list