Page MenuHomePhabricator

Rename $wmf* to $wmg* in wmf-config
Open, MediumPublic

Description

With https://gerrit.wikimedia.org/r/#/c/39056/ we renamed the old $realm to $wmfRealm. Tim mentioned:

It should be $wmgRealm, for consistency with other globals.
wmg = Wikimedia global, wmf = Wikimedia function.

We probably want to do that after the EQIAD migration though.

We can find them in operations/mediawiki-config with:

git grep -h -o -P '\$wmf.+?\b'|sort|uniq -c|sort -rn

As of Feb 4th 2020 we had:

57 $wmfConfigDir
53 $wmfRealm
36 $wmfAllServices
34 $wmfSwiftConfig
32 $wmfDatacenter
24 $wmfLocalServices
22 $wmfMasterDatacenter
15 $wmfHostnames
13 $wmfStandardAutoPromote
11 $wmfDbconfigFromEtcd
10 $wmfUdp2logDest
 6 $wmfSwiftShardLocal
 6 $wmfServiceConfig
 5 $wmfSwiftShardCommon
 5 $wmfPhabricatorApiToken
 4 $wmfMasterServices
 4 $wmfGerritApiUser
 4 $wmfGerritApiPassword
 3 $wmfSwiftBigWikis
 3 $wmfEtcdLastModifiedIndex
 1 $wmfUseRestbaseVRS

Revisions and Commits

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes

Change 94503 abandoned by Arav93:
Renamed $wmf* to $wmg* to improve consistency

Reason:
Revision added : https://gerrit.wikimedia.org/r/#/c/94354/

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

aravikn wrote:

Renamed $wmf to $wmg in mediawiki-config

Attached:

(In reply to comment #14)

Created attachment 13753 [details]
Renamed $wmf to $wmg in mediawiki-config

Patch is as broken as the patch that was uploaded to Gerrit, including lots of noise from conflicts like "<<<<<<< HEAD".
Please follow http://www.mediawiki.org/wiki/Gerrit/Tutorial and upload patches to Gerrit instead of Bugzilla, and fix potential issues in them. Thanks.

Attached:

Change 94354 abandoned by Arav93:
Renamed $wmfConfigDir to $wmgConfigDir in mediawiki-config

Reason:
Uploading new patch.

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

Change 94598 had a related patch set uploaded by Arav93:
Renamed $wmf* to $wmg*

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

aravikn wrote:

Could someone review? :)

Please don't ask for review after 40 minutes. Every comment creates bugmail and it is obvious to everybody anyway that there is a patch due to comment 18.

Also, as I had written several times on IRC, please AMEND changes instead of creating completely new numbers in Gerrit: https://www.mediawiki.org/wiki/Git/Tutorial#Amending_a_change

As mentioned three times now (comment 2, and twice in Gerrit), this change also requires a corresponding change to the mediawiki/extensions/WikimediaMaintenance project.

aravikn wrote:

How am I supposed to do that?

aravikn wrote:

And I'm sorry about spamming.

Change 94609 had a related patch set uploaded by Arav93:
Renamed $wmf* to $wmg* for consistency. Bug 43956 required a change in this repository as well.

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

Change 94598 abandoned by Arav93:
Renamed $wmf* to $wmg*

Reason:
Adding an improved patch.

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

aravikn wrote:

Could someone tell why this (https://gerrit.wikimedia.org/r/#/c/101820/) cannot be merged?

Somebody still needs to review the patch...

aravikn wrote:

Are you sure that's the only reason?

Change 94609 had a related patch set uploaded (by Nemo bis):
Renamed $wmf* to $wmg* for consistency

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

Krenair renamed this task from rename $wmfRealm to $wmgRealm in mediawiki-config.git to rename $wmf* to $wmg* in mediawiki-config.git.Aug 12 2015, 9:27 PM
Krenair set Security to None.

Change 231169 had a related patch set uploaded (by Alex Monk):
Rename wmfVersionNumber to wmgVersionNumber

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

Change 94609 merged by jenkins-bot:
Renamed $wmf* to $wmg* for consistency

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

Change 231193 had a related patch set uploaded (by Alex Monk):
Renamed $wmf* to $wmg* for consistency

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

Change 231194 had a related patch set uploaded (by Alex Monk):
Renamed $wmf* to $wmg* for consistency

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

Change 231194 merged by jenkins-bot:
Renamed $wmf* to $wmg* for consistency

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

Change 231169 merged by jenkins-bot:
Rename wmfVersionNumber to wmgVersionNumber

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

Change 231193 merged by jenkins-bot:
Renamed $wmf* to $wmg* for consistency

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

So this should now almost all be in mediawiki-config, except of course wmfSwiftEqiadConfig

Krinkle renamed this task from rename $wmf* to $wmg* in mediawiki-config.git to Rename $wmf* and $wmg* to $wgWMF in wmf-config.Apr 30 2017, 3:56 AM
Krinkle renamed this task from Rename $wmf* and $wmg* to $wgWMF in wmf-config to Rename $wmf* to $wmg* in wmf-config.

Remaining:

  • wmfCluster, wmfDatacenter, wmfRealm.
  • wmfAllServices, wmfLocalServices, wmfMasterServices.
  • wmfHostnames, wmfUdp2logDest
  • wmfStandardAutoPromote
  • wmfSwiftConfig (beware: private repo)
  • wmfSwiftBigWikis, wmfSwiftShardLocal, wmfSwiftShardCommon

Note however that in more recent events Tim also proposed we rename both $wmf* and $wmg* to wgWMF instead, but that's a separate task.

Isn't $wmf* better than $wgWMF tho?

Change 383944 had a related patch set uploaded (by Zoranzoki21; owner: Zoranzoki21):
[operations/mediawiki-config@master] Rename $wmf* to $wmg* in wmf-config

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

Kizule added a subscriber: Kizule.

I can not work on patch anymore. I'm leaving this to somebody else.

Change 383944 abandoned by Dereckson:
Rename $wmf* to $wmg* in wmf-config and tests folder

Reason:
Per last comment. If Zoranzoki21 or someone else wants to work on this, they can restore this change.

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

Change 392184 had a related patch set uploaded (by TerraCodes; owner: TerraCodes):
[operations/mediawiki-config@master] $wmf* -> $wmg*

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

Change 393126 had a related patch set uploaded (by TerraCodes; owner: TerraCodes):
[mediawiki/extensions/WikimediaMessages@master] $wmf* -> $wmg*

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

Change 393126 abandoned by TerraCodes:
$wmf* -> $wmg*

Reason:
turns out $wmgRealm stayed as $wmfRealm

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

Change 393126 restored by TerraCodes:
$wmf* -> $wmg*

Reason:
turns out it is changed

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

Change 393131 had a related patch set uploaded (by TerraCodes; owner: TerraCodes):
[mediawiki/extensions/WikimediaMaintenance@master] $wmf* -> $wmg*

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

Change 392184 abandoned by TerraCodes:
$wmf* -> $wmg*

Reason:
in favor of Krinkle's suggestion

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

Change 417215 had a related patch set uploaded (by Reedy; owner: TerraCodes):
[operations/mediawiki-config@master] Start renaming $wmfRealm to $wmgRealm in MWRealm.php

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

Change 417215 merged by jenkins-bot:
[operations/mediawiki-config@master] Start renaming $wmfRealm to $wmgRealm in MWRealm.php

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

Mentioned in SAL (#wikimedia-operations) [2018-03-19T23:35:45Z] <reedy@tin> Synchronized multiversion/MWRealm.php: T45956 (duration: 00m 57s)

Isn't $wmf* better than $wgWMF tho?

That depends. The Config abstraction layer in MediaWiki maps logical names (e.g. "ArticlePath") to a global named $wgArticlePath. If we used "wgWMF", these variables could (in the future) be managed through the same system, interacting with $wgWmfRealm as "WmfRealm".

Anyway, that's a later step. We can at least standardise first on one of the two patterns we already use (wmf* -> wmg*).

Isn't $wmf* better than $wgWMF tho?

That depends. The Config abstraction layer in MediaWiki maps logical names (e.g. "ArticlePath") to a global named $wgArticlePath. If we used "wgWMF", these variables could (in the future) be managed through the same system, interacting with $wgWmfRealm as "WmfRealm".

Anyway, that's a later step. We can at least standardise first on one of the two patterns we already use (wmf* -> wmg*).

Ah. Also ye, we should get it all on $wmg* first.

Change 393126 merged by jenkins-bot:
[mediawiki/extensions/WikimediaMessages@master] Rename $wmfRealm to $wmgRealm

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

Change 393131 merged by jenkins-bot:
[mediawiki/extensions/WikimediaMaintenance@master] Rename $wmfRealm to $wmgRealm

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

Change 444425 had a related patch set uploaded (by TerraCodes; owner: TerraCodes):
[operations/mediawiki-config@master] Finish $wmfRealm to $wmgRealm

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

Change 467104 had a related patch set uploaded (by MGChecker; owner: MGChecker):
[operations/mediawiki-config@master] Reduce Codesniffer exclusions

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

@TerraCodes are you still planning to work on this?

Change 444425 abandoned by TerraCodes:
Finish $wmfRealm to $wmgRealm

Reason:
going to redo, as it would be easier to redo the change rather than try to rebase an over year old change

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

@TerraCodes are you still planning to work on this?

Yeah, it kinda slipped my mind, but I'm still willing to do it.

Change 551778 had a related patch set uploaded (by TerraCodes; owner: TerraCodes):
[operations/mediawiki-config@master] Complete wmfRealm to wmgRealm

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

(this patch was a pain to get sent for review because I accidentally used the wrong email/name when committing it, why can't we use something thats easier to use like github or phab?)

(this patch was a pain to get sent for review because I accidentally used the wrong email/name when committing it, why can't we use something thats easier to use like github or phab?)

Completely off topic ;)

https://stackoverflow.com/questions/3042437/how-to-change-the-commit-author-for-one-specific-commit

(this patch was a pain to get sent for review because I accidentally used the wrong email/name when committing it, why can't we use something thats easier to use like github or phab?)

Completely off topic ;)

https://stackoverflow.com/questions/3042437/how-to-change-the-commit-author-for-one-specific-commit

Yeah its kinda offtopic, but its also on topic because its related to the patch I just uploaded

and yeah I tried that, which is why it was painful for me, at first I just tried amend, which updated git log, but git review didn't like it, so then I tried rebasing it, which worked fine till git decided that it needed to go through and rebase all 20k+ commits, which I cancelled about 200 commits through, and then I tried amending again, which review somehow liked, and let me submit the patch, so it would be nice to have something like phab or github where its easy to submit a patch and review it via the UI rather than having to get git review and gerrit to play nice (gerrit isn't exactly the most user friendly thing for new users) but if you want me to discuss this in a different place then feel free to point me towards it. :)

Change 551778 abandoned by TerraCodes:
[operations/mediawiki-config@master] Complete wmfRealm to wmgRealm

Reason:
merge conflicts change is pretty old, so it might be better to start over

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