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

WordPress Trac noreply at wordpress.org
Sun Aug 9 21:22:42 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 - You are correct. I'd missed this because I'd been using an mu-
 plugin for my testing of the upgrade script.

 This complication means that term splitting (or at least, the firing of
 hooks) needs to be moved to the pageload following the upgrade. See
 [attachment:30261.5.diff] for an example of how this would work. I'm not a
 fan of this pattern (the 'admin_init' check) but there's some precedent -
 see 'link_manager_enabled'.

 Would really appreciate feedback on the approach in the patch. I'm
 particularly concerned about introducing race conditions, but I've tried
 to mitigate this with the 'update_core' cap check, as well as by setting
 the 'shared_terms_split' flag *before* running the split routine.

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


More information about the wp-trac mailing list