Page MenuHomePhabricator

Redirect when a URL cannot be adapted to the new filter system for Recent Changes
Closed, ResolvedPublic

Description

URLs based on the old filter schema (i.e., hide X), need to be supported under the new filtering mode proposed ("show Y"). As a general rule, a "filter X" parameter can be translated into a "show other items in the group apart from X". However, it is possible to add contradicting parameters in the URL (hide registered + hide unregistered) that cannot be directly represented in the new model.

Remove the conflicting parameters (that can not be created in the new RC page) from the URL then redirect.

Old description below:

For cases where the user reaches Recent Changes through a URL with contradicting parameters (e.g., bookmarked links, tweaking URL parameters, etc.), the idea is to communicate such situation to the user for the user to check the results correspond to their expectations.

  • When the user reaches the page by using a problematic URL, a bubble notification is shown.
    • The message indicates that "Contradicting parameters from the link you followed have been ignored. Please, check that active filters are as expected."
    • Bubble notifications are a standard component showing a message for a few seconds to the user and vanishing after that.
  • The resulting URL (after the translation to the new system) should reflect the active filters shown after the adaptation, and sharing or bookmarking it should not propagate the message to be shown when accessing it again.

The messaging avoid technical terms such as URL to use a more familiar concept such as following a link. Although it may be 100% precise (e.g., advanced users manipulating the URLs themselves), seems adequate for less experienced users not to freak out when just following a link they found elsewhere (e.g., at the teahouse) unaware of their parameters.

Event Timeline

Restricted Application added a project: Collaboration-Team-Triage. · View Herald TranscriptNov 29 2016, 1:40 PM
SBisson added a subscriber: SBisson.EditedNov 29 2016, 2:25 PM

A few things I'd like to clarify.

The title of this ticket sounds like some URLs worked in with the old system but don't in the new one. It is not the case.

The only way to generate a URL that doesn't make sense because 1) it's guaranteed to return no result and 2) it is not possible to visually represent it as a combination of filters in the UI, is to type it in manually in the address bar.

The only exception (hideanons=1 & hideliu=1), which contains hidden features, could be temporarily supported with the following redirects:

hideanons=1 & hideliu=1 & hidebots=1 -> hideliu=1 & hidebots=1
hideanons=1 & hideliu=1 & hidebots=0 -> hidehumans=1

All other cases of invalid URLs had to be typed in and cannot be the result of following a previously valid link.

I think redirecting to a valid URL by discarding the contradicting parameters is plenty of feedback already for the URL hackers. If such a URL is crafted and shared before it was fixed by redirect, I'm wondering what are the odds of the user actually understanding what happened and what can be done about it.

A few things I'd like to clarify.

Thanks for the clarification. If the bar is so high for getting into this situation, I agree it makes sense to start by just letting the redirect to happen without further interruptions.

Change 325567 had a related patch set uploaded (by Sbisson):
[WIP] Fix contradictory RC filters

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

The data for this is the same as for #1 and #3 at T149452 , so it should be centralized as part of T152754 .

A few things I'd like to clarify.

Thanks for the clarification. If the bar is so high for getting into this situation, I agree it makes sense to start by just letting the redirect to happen without further interruptions.

@SBisson @Mattflaschen-WMF @Pginer-WMF, does this mean I can close this ticket?

jmatazzoni closed this task as Resolved.Jan 5 2017, 9:58 PM
jmatazzoni claimed this task.
SBisson reopened this task as Open.Jan 6 2017, 2:22 PM
SBisson claimed this task.

The redirection is still part of this ticket. There's a patch for it (https://gerrit.wikimedia.org/r/325567) but it depends on the filters definition that Matt is or will be working on.

Mattflaschen-WMF renamed this task from Inform users when a URL cannot be adapted to the new filter system for Recent Changes to Redirect when a URL cannot be adapted to the new filter system for Recent Changes.Mar 23 2017, 9:35 PM
Mattflaschen-WMF updated the task description. (Show Details)

Change 325567 merged by jenkins-bot:
[mediawiki/core@master] Fix contradictory RC filters and add back-compat

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

Checked in betalabs the cases listed in https://gerrit.wikimedia.org/r/#/c/325567/ - urls with parameters listed in the patch will redirect
hideanons=1 & hideliu=1 & hidebots=1 -> hideliu=1 & hidebots=1
hideanons=1 & hideliu=1 & hidebots=0 -> hidehumans=1

QA Recommendation: Resolve

jmatazzoni closed this task as Resolved.May 27 2017, 12:06 AM