Page MenuHomePhabricator

[scap] Recompute and sync git version cache when sync-* are used
Closed, ResolvedPublic


The versions (of MW Core, skins, and extensions) listed on Special:Version is updated during a full scap. It is not updated by any of the sync-* commands.

This may lead to surprises when people are trying to verify what is deployed.

Version: wmf-deployment
Severity: enhancement
See Also:



Event Timeline

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

Add some recent Special:Version code contributors in case they have any idea on how to get it back to providing some useful version info.

This only ever works if the git objects have been sync'd out...

Generally ignore the commit has, look at the wmf version instead (1.21wmf1 etc.). Wikis are deployed in groups based on that. All wikis running on 1.21wmf1 will be running on the same git commit as there is only 1 code base of 1.21wmf1.

And generally whatever the latest head[1] of a branch is according to gerrit will be what is deployed.


Converting ticket into a general task to somehow keep the .git info synchronised. So far that only happens with scap afaik.

I guess the scap script is explictely ignoring .git folder...

No, scap is not explicitly ignoring anything. It synchronises the entire /common directory including all subfolders (including docroot, live-1.5/, php-1.21wmf1/ and anything inside it, such as .git/)

The problem is with the other sync scripts:


  • Bug 43673 has been marked as a duplicate of this bug. ***

Syncing the entire .git directory is unnecessary. The php code (GitInfo.php) only needs .git/HEAD and the .git/refs/heads/* files to extract the SHA1.

Updated bug summary to clarify the scope of this issue (sync-* scripts).

Changing bug summary to reflect work that would need to be done to implement this. Since the resolution of bug 53972, scap creates json files containing git version information which are synced to the MediaWiki servers and read by Special:Version and other GitInfo consumers.

The sync-* family of scripts could be updated to recompute the git info cache and sync these files along with the specified payload. Due to construction of the python implementation of scap, this actually would not be incredibly difficult to implement.

greg set Security to None.
greg removed a subscriber: wikibugs-l-list.
demon claimed this task.
demon added a subscriber: demon.

This is live everywhere now (scap 3.5.5), feel free to reopen if it doesn't work.