[wp-trac] [WordPress Trac] #45958: Errors displayed on shutdown handler

WordPress Trac noreply at wordpress.org
Mon Jan 14 08:00:53 UTC 2019

#45958: Errors displayed on shutdown handler
 Reporter:  spacedmonkey                         |       Owner:  (none)
     Type:  defect (bug)                         |      Status:  new
 Priority:  high                                 |   Milestone:  Awaiting
                                                 |  Review
Component:  Bootstrap/Load                       |     Version:  trunk
 Severity:  normal                               |  Resolution:
 Keywords:  has-screenshots servehappy has-      |     Focuses:  multisite
  patch needs-testing                            |

Comment (by schlessera):

 I think the patch breaks the `WP_DISPLAY_DEBUG` constant, as it is set
 early, and you're now overriding it no matter what. This line is meant to
 represent the exceptions for `WP_DISPLAY_DEBUG` is actually set to `true`.
 In such a case, the filtered requests you saw in the changed line here
 still need to not display anything to avoid breaking the response.

 I had already looked into this as well, and the main problem is that the
 shutdown handler should decide whether or not to display the error, but at
 the moment the shutdown handler receives control, PHP has already printed
 the error.

Ticket URL: <https://core.trac.wordpress.org/ticket/45958#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform

More information about the wp-trac mailing list