[wp-trac] [WordPress Trac] #30261: Split all existing shared taxonomy terms on WP upgrade

WordPress Trac noreply at wordpress.org
Sun Aug 9 19:30:43 UTC 2015


#30261: Split all existing shared taxonomy terms on WP upgrade
-------------------------------------+---------------------------
 Reporter:  boonebgorges             |       Owner:  boonebgorges
     Type:  enhancement              |      Status:  reopened
 Priority:  normal                   |   Milestone:  4.3
Component:  Taxonomy                 |     Version:
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-testing  |     Focuses:
-------------------------------------+---------------------------

Comment (by boonebgorges):

 Chouby, thanks for the report.

 > Unless, I missed something, the 'split_shared_term' action is inoperant
 since plugins are not loaded during the upgrade.

 Plugins are loaded during upgrades. `wp_upgrade()` is called from wp-
 admin/upgrade.php, which calls the full WP bootstrap via wp-load.php. If
 you were seeing failures in your tests, it's probably because (a) of the
 db_version problem you mentioned, or (b) because your plugin doesn't
 register its taxonomies early enough to be caught during upgrade routines.

 > I'd like to reopen this ticket as terms are not splitted when upgrading
 from an old WP version.

 This is correct - thank you very much for catching it. At some point, the
 db_version check here can be removed altogether, but for the time being, a
 safe fix is to add a `WP_INSTALLING` check alongside the db_version check.
 See [attachment:30261.4.diff].

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


More information about the wp-trac mailing list