[wp-trac] [WordPress Trac] #61467: Inconsistent cache handling for network (site) meta

WordPress Trac noreply at wordpress.org
Wed Jun 4 10:23:00 UTC 2025


#61467: Inconsistent cache handling for network (site) meta
-------------------------------------------------+-------------------------
 Reporter:  xParham                              |       Owner:
                                                 |  spacedmonkey
     Type:  defect (bug)                         |      Status:  assigned
 Priority:  normal                               |   Milestone:  6.9
Component:  Cache API                            |     Version:  3.0
 Severity:  major                                |  Resolution:
 Keywords:  has-test-info dev-feedback has-      |     Focuses:  multisite,
  patch                                          |  performance
-------------------------------------------------+-------------------------

Comment (by logicrays):

 The issue is due to inconsistent cache handling between
 `update_network_option()` and `update_metadata( 'site', ... )`, both of
 which manage `wp_sitemeta` but use different cache keys. When both methods
 are used together, it causes cache mismatch and out-of-sync values. For
 example, WP CLI uses metadata functions that update the value, but
 `get_network_option()` still returns the old cached value. This
 inconsistency can confuse developers and lead to bugs. A unified cache
 strategy or proper cache invalidation is needed to fix this behavior.

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


More information about the wp-trac mailing list