Page MenuHomePhabricator

Remove "php-" from wiki version numbers
Closed, DeclinedPublic

Description currently reads (in part):


"aawiki": "php-1.23wmf14",
"aawikibooks": "php-1.23wmf14",
"aawiktionary": "php-1.23wmf14",
"abwiki": "php-1.23wmf14",

The "php-" part seems unnecessary and can probably be (carefully) removed. Or perhaps replaced with "mw-".

Version: wmf-deployment
Severity: enhancement



Event Timeline

bzimport raised the priority of this task from to Lowest.Nov 22 2014, 2:59 AM
bzimport added a project: Deployments.
bzimport set Reference to bz61733.
bzimport added a subscriber: Unknown Object (MLST).

(In reply to MZMcBride from comment #0)

The "php-" part seems unnecessary and can probably be (carefully) removed.
Or perhaps replaced with "mw-".

Decisions, decisions

The php- prefix is hardcoded everywhere. There is no reason for us to invest time in fixing every possible occurrences or handle back compatibility code around.

(In reply to Antoine "hashar" Musso from comment #2)

The php- prefix is hardcoded everywhere.

This is hyperbole. Please don't be hasty.

What is the advantage / gain of removing it?

The values in the wikiversions.json and compiled wikiversions.cdb files are the directory names used for the branch checkouts relative to the /usr/local/apache/common directory on each apache server.

It is hardcoded in at least these locations in operations/mediawiki-config.git:

  • .gitignore
  • logmsg-git-hook
  • multiversion/activeMWVersions.php
  • multiversion/checkoutMediaWiki.php
  • multiversion/deleteMediaWiki
  • multiversion/MWMultiVersion.php
  • multiversion/updateBitsBranchPointers
  • multiversion/updateWikiversions.php
  • wmf-config/StartProfiler.php

There is also hard coded knowledge of this prefix in both the legacy scap scripts and the new python code.

Bryan see my comment #2 above. I dont think we should spend time dropping that prefix.

(In reply to Andre Klapper from comment #4)

What is the advantage / gain of removing it?

It looks silly. wikiversions.json includes "php-1.23wmf14". There's probably a good historical reason for this, but I don't think it needs to linger indefinitely. I think "mw-1.23wmf14" or "1.23wmf14" would be clearer, but perhaps as hashar suggests, this isn't worth the effort to change.

According to Tim in T45340#457954, this is just a historical leftover:

[00:24:40] <TimStarling> the php- prefix predates the name "mediawiki", it annoys me that it was kept through hetdeploy

So we can do this, and I don't think it'll be a lot of work, just needs to be done slowly and carefully. My very quick (likely overzealous) grep indicates: 31 results (in 14 files) for scap-related code and 1104 results in 46 files for production-related stuff (MW-config, puppet, etc). The latter # is over-counting, since I didn't exclude the wikiversions.json files.

hashar changed the task status from Open to Stalled.Jan 26 2021, 5:54 PM

Well that was open and showed up as is in our work board so I have explicitly marked it stalled which hide it from our views :-]

On a second view, I am not sure anyone will ever tackle that technical debt. With the project to migrate MediaWiki to Kubernetes I guess that decades old php- prefix will be gone entirely. As such I am inclined to just decline that task. Notably it is merely cosmetic and does no harm.

After all those years, I guess we will just stick to carry the php- prefix. It is not a problem but attempt to drop it might prove to be problematic. It is not worth it (even if it would theoretically be nice).