Page MenuHomePhabricator

Replace use of $wgRequest in wmf-config (CommonSettings.php / throttle-analyze.php)
Closed, ResolvedPublic

Description

Use of $wgRequest could be deprecated and remove someday (T160810) and should be replaced also in wmf-config code.

A one-by-one replacement is with RequestContext::getMain()->getRequest(), better it is to use some inherit IContextSource, but it seems the arguments passed to the hooks does not provide a context source.

Details

Related Changes in Gerrit:

Event Timeline

Change #1281526 had a related patch set uploaded (by SomeRandomDeveloper; author: SomeRandomDeveloper):

[operations/mediawiki-config@master] Replace use of $wgRequest

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

Change #1281526 merged by jenkins-bot:

[operations/mediawiki-config@master] Replace use of $wgRequest

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

Mentioned in SAL (#wikimedia-operations) [2026-05-06T20:19:31Z] <catrope@deploy1003> Started scap sync-world: Backport for [[gerrit:1281526|Replace use of $wgRequest (T336703)]]

Mentioned in SAL (#wikimedia-operations) [2026-05-06T20:21:31Z] <catrope@deploy1003> catrope, somerandomdeveloper: Backport for [[gerrit:1281526|Replace use of $wgRequest (T336703)]] synced to the testservers (see https://wikitech.wikimedia.org/wiki/Mwdebug). Changes can now be verified there.

Mentioned in SAL (#wikimedia-operations) [2026-05-06T20:28:43Z] <catrope@deploy1003> Finished scap sync-world: Backport for [[gerrit:1281526|Replace use of $wgRequest (T336703)]] (duration: 09m 12s)