[wp-trac] [WordPress Trac] #12041: wp-includes/wp-db.php WP_DEBUG constant

WordPress Trac wp-trac at lists.automattic.com
Sun Jan 31 21:24:44 UTC 2010

#12041: wp-includes/wp-db.php WP_DEBUG constant
 Reporter:  wpmuguru      |        Owner:  donncha   
     Type:  defect (bug)  |       Status:  assigned  
 Priority:  normal        |    Milestone:  Unassigned
Component:  Multisite     |      Version:  2.9.1     
 Severity:  normal        |   Resolution:            
 Keywords:                |  
Changes (by nacin):

  * owner:  => donncha
  * status:  reopened => assigned


 This is related to #11881.

 In plain WP, we removed a check for whether WP_DEBUG was defined in wp-
 db.php. The install script (which includes wp-db.php to be db aware
 without loading the rest of WP) has error_reporting(0), which suppresses
 everything anyway, so we didn't notice it. That's fixed in 3.0.

 However, the MU installer doesn't bother with error_reporting at all, and
 your environment default probably includes E_NOTICE, hence you're seeing
 this notice (which would normally be suppressed throughout all of WP).

 If there's a (see also #12090), this might as well go in. (An
 undefined constant is assumed to be true, so $this->show_errors() is
 turned on even though it shouldn't be.) Assigning to donncha.

 Simple fix is to add {{{define('WP_DEBUG', false);}}} to index-install.php
 before we include wp-db.php.

Ticket URL: <http://core.trac.wordpress.org/ticket/12041#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software

More information about the wp-trac mailing list