Topic on Template talk:Extension

Samwilson (talkcontribs)

@Proactive programming: thanks for your recent changes.

Although I like the idea of extensions being able to declare what versions of MW they work with, I'm not sure this info needs to be given over three rows in the infobox. One row, with a comma-separated list of MW versions supported, would suffice I think.

I also wonder if this could be a single new parameter, parsed as required in Module:Extension (or wherever) to e.g. add categories etc.

Tacsipacsi (talkcontribs)

I like this three-row design. When a new MW version comes out, simply a new row needs to be added, and one can see in a glance that the extension doesn’t officially support it (yet). Was it one row, it would be less clear that even though an extension supports a bunch of MW versions, they’re all years old. Also, it’s easy to drop MW versions no longer supported by Wikimedia (i.e. versions that themselves get no security updates anymore), so no longer relevant information doesn’t clutter the infobox.

That being said, I’m not against using one parameter for all versions in code, given that it’s still displayed in three rows as now (neither am I definitely for it, though); and I think categorization is a good idea. Some documentation would also be useful, especially specifying the valid values, which would be needed to implement categorization (as well as to make this part of the template translatable).

Samwilson (talkcontribs)

I think what I don't like about the three rows is just the repetition of 'MediaWiki'. Maybe it could be a single row for the label (e.g. 'MediaWiki compatibility') and three rows for the current supported versions. I think it should also come after the 'Compatibility policy' row, because it's pretty similar — or maybe before that one, as this new info is actually of more use to people looking to install an extension.

But yeah, however it looks, it's good to have this. Documentation is a must. I think it could also use the MediaWiki version information templates, and perhaps have 'stable', 'LTS', etc. shown next to each.

Samwilson (talkcontribs)

Oh I forgot: I think it'd also be worth investigating whether it wouldn't be better to add supported-versions information to extension.json, because then it's tied to the code and is more easily queryable from everywhere (and can be included in the template via Module:ExtensionJson.

Tacsipacsi (talkcontribs)

Unfortunately extension.json can’t be used here. Module:ExtensionJson contains the extension.json files only from the default Git branch (usually named master), while the extension may support other MW versions, for example on branches matching the supported versions’ branches. This information is not available in the module, and I don’t think it’s even possible to determine programmatically which branches are actually maintained.

For using a separate row for “MediaWiki”: I don’t mind it either way. By the way, there’s a row titled “MediaWiki” already, so we could even do something like this:

Extension
Release status: unknown
MediaWiki 1.25
1.36 Not formally tested
1.34 Not formally tested
1.33 Not formally tested
Kghbln (talkcontribs)

Yeah, who is supposed to fill the information? I have the feeling that this is the wrong solution for the right problem. I also think that the information should be fetched from code and not manually be added here. PS Currently it shows 1.36, 1.34 and 1.32 where it should be 1.36, 1.35 and 1.31. We also had the case in the past that only two branches were supported at a time.

Samwilson (talkcontribs)

The existing requires values in extension.json are allowed to accept a version range (like Composer does), so something like "MediaWiki": ">=1.32 <=1.35" is permitted (but doesn't seem to be used anywhere).

Kghbln (talkcontribs)

In other words. The information will be fetched from extension.json instead of requiring editing on this wiki which is good. I think these lines should not be shown if no extension.json is around. They will not be filled anyways or in rare cases at best.

Ciencia Al Poder (talkcontribs)

Note that extension.json may only support the latest stable branch because of compatibility issues with MediaWiki interfaces, but the extension may work and be tested with older versions if you choose to download the corresponding branch of an older MediaWiki release.

AFAIK, Module:ExtensionJson only reads extension.json from the master branch (which may list a still unreleased MediaWiki version as the minimum supported version, like it usually happens with VisualEditor)

Kghbln (talkcontribs)

Good point. Thus the module needs to read the info from the respective branch.

Samwilson (talkcontribs)

Module:ExtensionJson could be modified to include each branch's compatibility information. It'd take slightly longer to generate, but I don't think it'd be an overly difficult thing. It'd also only apply when compatibility policy is rel or ltsrel.

Samwilson (talkcontribs)

I think we should remove these new parameters until it's clearer where the data for them is coming from. We don't want extension maintainers to start adding the info, only to later be told it's going to come from extension.json.

@Proactive programming: you added these, what do you think?

Samwilson (talkcontribs)