Page MenuHomePhabricator

Add structure test for minimum supported version of mediawiki vs. use of newer features
Open, Needs TriagePublic

Description

I just came across an extension (BoilerPlate) that only required MW 1.32+ but uses the hook handler system, which wasn't introduced until 1.35. I sent a patch for that extension and the others I found with the same issue[1] but it would be useful to have a structure test

  • check the minimum supported version of mediawiki
  • check the rest of extension.json for trying to use features introduced in a specific version

While an extension may be able to work in a version before the specific feature was introduced, it likely won't, or at least won't work as intended

[1] See https://gerrit.wikimedia.org/r/q/topic:%22hookhandlers-requires-1.35%22+(status:open%20OR%20status:merged)

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
DannyS712 moved this task from Inbox to PHPUnit on the MediaWiki-Core-Tests board.

It could also be part of the schema declaration if that is supported and than the structure test to validate extension.json would found it.

There is similar with AutoloadNamespaces I have fixed often: https://gerrit.wikimedia.org/r/q/topic:requires+owner:umherirrender_de.wp%2540web.de