[go: nahoru, domu]

Page MenuHomePhabricator

Page info cache should take config change into account
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

  • Set $wgNamespacesWithSubpages[ NS_MEDIAWIKI ] = false;
  • Set up WANObjectCache with valid config.
  • Visit action=info of a page in the MediaWiki namespace (build the cache)
  • Set $wgNamespacesWithSubpages[ NS_MEDIAWIKI ] = true;
  • Visit action=info of that page again.

What happens?:

Number of subpages of this page [INVALID] ([INVALID] redirects; [INVALID] non-redirects)

What should have happened instead?:

The subpage count is displayed correctly, and no errors in the log.
Or only display subpage counts if the cache has them, since this is not very important (so we don't need to re-generate the cache).

Software version (skip for WMF-hosted wikis like Wikipedia):

Other information (browser name/version, screenshots, etc.):

Event Timeline

Change 933677 had a related patch set uploaded (by Func; author: Func):

[mediawiki/core@master] InfoAction: Brace against change on the namespace subpage config

https://gerrit.wikimedia.org/r/933677

Or only display subpage counts if the cache has them, since this is not very important (so we don't need to re-generate the cache).

Is there a way for users to force regenerating the cache? While probably most people arriving on info pages just after the configuration change aren’t interested in the subpage count, there are certainly some who are. If they can simply purge the page to regenerate the cache, then it makes sense to optimize for the more likely scenario.

It seems there is no way to force regen the cache, should we make action=purge work for this cache?

If it’s not too expensive, then yes please.

Change 945011 had a related patch set uploaded (by Func; author: Func):

[mediawiki/core@master] Allow force regenerating the page info cache via action=purge

https://gerrit.wikimedia.org/r/945011

Change 945011 merged by jenkins-bot:

[mediawiki/core@master] Allow force regenerating the page info cache via action=purge

https://gerrit.wikimedia.org/r/945011

Change 933677 merged by jenkins-bot:

[mediawiki/core@master] InfoAction: Brace against change on the namespace subpage config

https://gerrit.wikimedia.org/r/933677