Page MenuHomePhabricator

Use of $wgLogoHD was deprecated in Rename configuration variable to $wgLogos
Closed, ResolvedPublic

Description

Use of $wgLogoHD was deprecated in Rename configuration variable to $wgLogos 1.35. [Called from SkinTemplate::prepareQuickTemplate in /srv/mediawiki/php-1.35.0-wmf.19/includes/skins/SkinTemplate.php at line 326]
Use of $wgLogoHD was deprecated in Rename configuration variable to $wgLogos 1.35. [Called from ResourceLoaderSkinModule::getLessVars in /srv/mediawiki/php-1.35.0-wmf.19/includes/resourceloader/ResourceLoaderSkinModule.php at line 417]
Use of $wgLogoHD was deprecated in Rename configuration variable to $wgLogos 1.35. [Called from ApiQuerySiteinfo::appendGeneralInfo in /srv/mediawiki/php-1.35.0-wmf.19/includes/api/ApiQuerySiteinfo.php at line 139]

Ping Bug: T232140

Event Timeline

Restricted Application added subscribers: Liuxinyu970226, Aklapper. · View Herald Transcript
Reedy triaged this task as High priority.Feb 13 2020, 6:29 PM

Tagging as high as there's thousands of these a minute in the logs

Screenshot 2020-02-13 at 11.29.38.png (1×2 px, 213 KB)

Krinkle added subscribers: Jdlrobson, Krinkle.

@Jdlrobson Probably best to remove that deprecation call for now in SkinModule.php and SWAT deploy to wmf.19. Then think about it some more next week after we've had a sucessfull train go out before changing anything else.

Change 572064 had a related patch set uploaded (by Jforrester; owner: Jforrester):
[mediawiki/core@wmf/1.35.0-wmf.19] ResourceLoaderSkinModule: Don't hard-deprecate wgLogoHD just now

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

If https://gerrit.wikimedia.org/r/c/operations/mediawiki-config/+/570379 isn't landed in prod before wmf.20 is cut, we'll need to do this for wmf.20 too.

Change 572064 merged by jenkins-bot:
[mediawiki/core@wmf/1.35.0-wmf.19] ResourceLoaderSkinModule: Don't hard-deprecate wgLogoHD just now

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

Mentioned in SAL (#wikimedia-operations) [2020-02-13T19:20:19Z] <jforrester@deploy1001> Synchronized php-1.35.0-wmf.19/includes/resourceloader/ResourceLoaderSkinModule.php: T245182 ResourceLoaderSkinModule: Don't hard-deprecate wgLogoHD just now (duration: 01m 03s)

Side note, wfDeprecated is used wrong here:

  • the third argument is for specifying the extension/library, using it for an extra message like here just adds to the confusion. If it's important (IMO not) put it in the first parameter.
  • by default caller offset is two, which is appropriate for deprecating a function (the deprecation warning tells which function called the function that calls wfDeprecated). Since it's not ResourceLoaderSkinModule::getAvailableLogos itself that's being deprecated, that's confusing here and a caller offset of 1 should be used.

Yeah, my priority was logspam reduction, but you're right.

Thanks @Jdforrester-WMF I was off last 2 days. I can pickup the issue from here since I caused it. Moving into sprint board since this was caused by T232140

Side note, wfDeprecated is used wrong here:

  • the third argument is for specifying the extension/library, using it for an extra message like here just adds to the confusion. If it's important (IMO not) put it in the first parameter.
  • by default caller offset is two, which is appropriate for deprecating a function (the deprecation warning tells which function called the function that calls wfDeprecated). Since it's not ResourceLoaderSkinModule::getAvailableLogos itself that's being deprecated, that's confusing here and a caller offset of 1 should be used.

Syntax fixed in Iadeec9520867bc1b6ace885fd4d93b856f6373d4. I think the default $callerOffset of 2 should be fine for now?

Krinkle claimed this task.

Yes, let's continue at T232140.

Change 573993 had a related patch set uploaded (by Reedy; owner: Jforrester):
[mediawiki/core@wmf/1.35.0-wmf.20] ResourceLoaderSkinModule: Don't hard-deprecate wgLogoHD just now

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

Change 573994 had a related patch set uploaded (by Reedy; owner: Jforrester):
[mediawiki/core@master] ResourceLoaderSkinModule: Don't hard-deprecate wgLogoHD just now

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

Change 573993 merged by Reedy:
[mediawiki/core@wmf/1.35.0-wmf.20] ResourceLoaderSkinModule: Don't hard-deprecate wgLogoHD just now

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

Mentioned in SAL (#wikimedia-operations) [2020-02-21T13:38:15Z] <reedy@deploy1001> Synchronized php-1.35.0-wmf.20/includes/resourceloader/ResourceLoaderSkinModule.php: T245778 T245182 T232140 (duration: 01m 00s)

Change 573994 merged by jenkins-bot:
[mediawiki/core@master] ResourceLoaderSkinModule: Don't hard-deprecate wgLogoHD just now

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