[wp-trac] [WordPress Trac] #36819: Load plugin.php earlier in wp-settings.php

WordPress Trac noreply at wordpress.org
Wed May 11 20:13:31 UTC 2016


#36819: Load plugin.php earlier in wp-settings.php
----------------------------+-----------------
 Reporter:  jorbin          |      Owner:
     Type:  enhancement     |     Status:  new
 Priority:  normal          |  Milestone:  4.6
Component:  Bootstrap/Load  |    Version:
 Severity:  normal          |   Keywords:
  Focuses:                  |
----------------------------+-----------------
 In order to rectify the differences between wp-settings.php and the wp-cli
 counterpart, filters need to be available earlier.

 @rmccue summerized it in #34936 with:
 > Generally speaking, I think we should have more hooks more early. Given
 that plugin.php is almost entirely self-contained (we could split the file
 if needed), I'd be in favour of loading it earlier than it currently,
 moving it up to the first block of includes (load.php and default-
 constants.php). We could then add an action to wp_debug_mode for that,
 filter wp_maintenance, etc. It would result in a small amount more code
 loaded before advanced-cache kicks in (I imagine negligible in any case),
 but be super helpful for edge cases and advanced tooling.

 This could potentially affect `advance-cache.php`, if it is preloading and
 changing the filter globals,  so it will need dev notice and testing.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/36819>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list