Page MenuHomePhabricator

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

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.


Version: unspecified
Severity: enhancement

Details

Commits
rOMWC63cceecc6e3c: $wmf* -> $wmg*
Reference
bz43956

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes
bzimport set Reference to bz43956.Nov 22 2014, 1:13 AM
hashar created this task.Jan 14 2013, 12:23 PM

[ Set tracking bug 39106 (EQIAD migration) as blocker. ]

If you do this, you should also rename the following:

$wmfConfigDir
$wmfDatacenter
$wmfExtendedVersionNumber
$wmfHostnames
$wmfSwiftBigWikis
$wmfSwiftConfig
$wmfSwiftShardCommon
$wmfSwiftShardLocal
$wmfUdp2logDest
$wmfVersionNumber
$wmfThrottlingExceptions
$wmfStandardAutoPromote
$wmfUseArticleCreationWorkflow

It looks to me like "$wmg" variables are used for particular features, e.g. which extensions to enable or setting a particular "$wg" variable. And except for the last three, it looks like "$wmf" variables are used for global configuration.

Don't forget to check extensions/WikimediaMaintenance and /usr/local/bin stuff too.

aravikn wrote:

I have already mailed people who are on the cc list of this bug. One of them told me to comment on this so that this bug would be assigned to me. So, could someone assign this bug to me?

(In reply to comment #3)

I have already mailed people who are on the cc list of this bug.

That's not a good idea if there is nothing private or off-topic to discuss - instead, comment on this bug report. Assigned to you now.

aravikn wrote:

Could you please mentor me for this bug fixing?

Hello,

I can mentor you for this bug.

Please poke me on IRC. Dereckson (I'm on #wikimedia-tech and #wikimedia-dev, I figure the first is more indicated for this kind of configuration bug).

aravikn wrote:

Is it okay if I mail you?

I don't see much sense in relying on one person only in private, when there's
an unlimited number of people who can help you in public.
The knowledge of the crowd is one of the advantages of free software. :)

I concur.

A little explanation for the bug status. We use:

  • UNCONFIRMED for bugs still needing clarification
  • NEW for (confirmed) new bugs
  • ASSIGNED for bug someone is working on (so if there is an assignee, status should be ASSIGNED, to avoid someone else meanwhile work on it)
  • PATCH_TO_REVIEW when bug has a code solution, pending code review
  • RESOLVED when the bug has been solved
  • VERIFIED for the areas using quality assurance, after the QA occurred

aravikn wrote:

Renamed $wmf to $wmg in mediawiki-config

Renamed $wmf* to $wmg* for consistency with other global variables.
$wmf= Wikimedia function
wmg= Wikimedia global

Attached:

Change 94354 had a related patch set uploaded by TTO:
Renamed $wmfConfigDir to $wmgConfigDir in mediawiki-config

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

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

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

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:

aravikn wrote:

Ok, Sure.

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

hashar removed a subscriber: hashar.Jun 17 2015, 8:15 PM
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.
Restricted Application added subscribers: Matanya, Aklapper. · View Herald TranscriptAug 12 2015, 9:27 PM

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

Restricted Application added a subscriber: JEumerus. · View Herald TranscriptApr 4 2016, 11:45 AM
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.
Krinkle added a subscriber: Krinkle.EditedApr 30 2017, 4:14 AM

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?

Zoranzoki21 moved this task from Backlog to Working on on the Wikimedia-Site-requests board.

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

Zoranzoki21 removed Zoranzoki21 as the assignee of this task.Oct 14 2017, 10:05 PM
Zoranzoki21 added a subscriber: Zoranzoki21.

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

Krinkle removed a subscriber: Krinkle.

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