Page MenuHomePhabricator

Enable wgRelevantUserName for IP ranges
Open, Needs TriagePublic

Description

wgRelevantUserName was added to MW in 1.23, but it doesn't exist when viewing an IP range on (at least) Special:Block and Special:Contributions (compare 192.168.0.2 and 192.168.0.0/16). Some awkward workarounds are possible but inconsistent (using #mw-bi-target or input[name=wpTarget] on Special:Block, input[name=target].mw-input on Special:Contributions); it'd be nice to have a unified and reliable way to get it, regardless of user type.

Of note: it seems to always exist on Special:DeletedContributions, and does so on Special:Log iff the range is given with the user= parameter (e.g., https://en.wikipedia.org/wiki/Special:Log?user=192.168.0.0%2F16).

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 14 2018, 6:15 PM
Amorymeltzer updated the task description. (Show Details)Dec 12 2018, 8:31 PM

It turns out to be intentional - see highlighted lines of SpecialContributions.php. However, I cannot figure out why the comments say a 'logs' link (of an IP range) may be irrelevant and am looking forward to a reply from those who know it.

@WhitePhosphorus I don't believe logs work on IP ranges

@Amorymeltzer Oh yeah I got it. IMHO it would be more appropriate to enable it while do some additional check in skin stuff like SkinTemplate.php.

AlanM1 added a subscriber: AlanM1.Nov 30 2019, 5:12 AM
Xiplus added a subscriber: Xiplus.Dec 2 2019, 12:57 AM

@Anomie I actually meant to update this to something like your comment in T239527#5709615 after playing around with things more recently; there's enough of a difference in how we'd want to treat what could be called a "user" (account, single IP) and what could have edits displayed (that + range) that I think that's the right course.

Commenting as an admin + Twinkle user (pretty sure @Amorymeltzer has TW in mind here) that this functionality would be very useful - I routinely use Twinkle and I make rangeblocks fairly often, but when making rangeblocks my workflow is disrupted since Twinkle can't block from Special:Contribs/(IP)/(mask) so I have to use the normal block interface.

Aklapper removed a subscriber: Anomie.Oct 16 2020, 5:01 PM
Izno added a subscriber: Izno.Fri, Nov 20, 4:42 PM

Change 642610 had a related patch set uploaded (by Ammarpad; owner: Ammarpad):
[mediawiki/core@master] Define Skin RelevantUser for IP ranges

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

Jdlrobson added a subscriber: Jdlrobson.

I think this would benefit from some input from platform engineering.