WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 6 years ago

#7331 closed defect (bug) (invalid)

Plugin caching prevents detection of newly installed plugins

Reported by: Murmatron 2 Owned by:
Milestone: Priority: normal
Severity: normal Version: 2.6
Component: Administration Keywords:
Focuses: Cc:

Description

Use of wp_cache_get/wp_cache_set in get_plugins in /wp-admin/includes/plugin.php prevents a newly installed plugin from being detected until object cache is purged.

By the same mechanism, a plugin directory that has been manually zapped from the filesystem is shown as a recently deactivated plugin.

There's no obvious criterion for invalidating the cached object since it's created from a filesystem scan and actively prevents another one occurring.

Perhaps something like a "Scan disk for new/deleted plugins" button on the admin page that deletes the plugins cache would be a solution worth considering.

Change History (2)

comment:1 DD326 years ago

It sounds like the Object Cache has not been updated to respect the non-persistent groups introduced with #6740

A workaround i can think of is to manually purge the object cache groups upon each pageload if the group is registered as non-persistent.

As a side note: There are also some Object caches which appear to ignore the cache_flush()'s and will remember the cached data after its supposed to have been invalidated; I believe thats caused some issues elsewhere, But this is not specifically related to this ticket issue.

comment:2 ryan6 years ago

  • Milestone 2.7 deleted
  • Resolution set to invalid
  • Status changed from new to closed

The cache backend needs to use the API from #6740. Some caches have already been changed, so you might need to update.

Note: See TracTickets for help on using tickets.