[wp-trac] [WordPress Trac] #56481: Short-circuit HEAD methods in Core controllers

WordPress Trac noreply at wordpress.org
Sat Mar 29 19:26:55 UTC 2025


#56481: Short-circuit HEAD methods in Core controllers
--------------------------------------+------------------------------------
 Reporter:  TimothyBlynJacobs         |       Owner:  TimothyBlynJacobs
     Type:  task (blessed)            |      Status:  reopened
 Priority:  normal                    |   Milestone:  6.8
Component:  REST API                  |     Version:  4.7
 Severity:  normal                    |  Resolution:
 Keywords:  has-patch has-unit-tests  |     Focuses:  rest-api, performance
--------------------------------------+------------------------------------

Comment (by antonvlasenko):

 I've reviewed both Hosting Test Reports
 ([https://make.wordpress.org/hosting/test-results/r59970/ 1],
 [https://make.wordpress.org/hosting/test-results/r60044/ 2]), and the
 related test failures appear to be the following:
 1. https://make.wordpress.org/hosting/test-
 results/r59970/wpmudevbot-r59970-8-1-mysql-ver-15-1-distrib-10-6-18
 -mariadb-for-debian-linux-gnu-x86_64-using-editline-wrapper/
 2. https://make.wordpress.org/hosting/test-
 results/r59970/wpmudevbot-r59970-8-2-mysql-ver-15-1-distrib-10-6-18
 -mariadb-for-debian-linux-gnu-x86_64-using-editline-wrapper/
 3. https://make.wordpress.org/hosting/test-
 results/r59970/wpmudevbot-r59970-8-3-mysql-ver-15-1-distrib-10-6-18
 -mariadb-for-debian-linux-gnu-x86_64-using-editline-wrapper/
 4. https://make.wordpress.org/hosting/test-
 results/r60044/xserverbot-r60044-7-4-mysql-ver-15-1-distrib-10-5-22
 -mariadb-for-linux-x86_64-using-editline-wrapper/
 5. https://make.wordpress.org/hosting/test-
 results/r60044/xserver2bot-r60044-8-2-mysql-ver-15-1-distrib-10-5-22
 -mariadb-for-linux-x86_64-using-editline-wrapper/
 6. https://make.wordpress.org/hosting/test-
 results/r60044/wpmudevbot-r60044-8-3-mysql-ver-15-1-distrib-10-6-18
 -mariadb-for-debian-linux-gnu-x86_64-using-editline-wrapper/
 7. https://make.wordpress.org/hosting/test-
 results/r60044/wpmudevbot-r60044-8-3-mysql-ver-15-1-distrib-10-6-18
 -mariadb-for-debian-linux-gnu-x86_64-using-editline-wrapper/
 8. https://make.wordpress.org/hosting/test-
 results/r60044/wpmudevbot-r60044-8-4-mysql-ver-15-1-distrib-10-6-18
 -mariadb-for-debian-linux-gnu-x86_64-using-editline-wrapper/.

 All of them are caused by the hardcoded database table name in the
 `WP_Test_REST_Users_Controller::test_get_items_only_fetches_ids_for_head_requests`
 method.

 [https://github.com/WordPress/wordpress-develop/pull/8614 The proposed PR]
 addresses this issue and is ready for review.

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


More information about the wp-trac mailing list