Page MenuHomePhabricator

Notification involving suppressed revision produces erroneous link
Closed, ResolvedPublic

Description

If you get a notification involving a revision which was suppressed before you saw it, you get this message:

Example mentioned you on the Example talk page in "This page revision has been suppressed.".

Links in the above are

<Example> → User:Example
<Example talk page> → Talk:Example
<This page revision has been suppressed.> → Talk:Example#This_page_revision_has_been_suppressed.

The suppression message is getting treated as a section ID, trailing full stop and all, which is obviously incorrect.

There doesn't seem to be much point in delivering such a notification, but by the looks of it that would be complicated. Echo appears to be pulling the page title at the time the user asks to see the notification, by which point it's gone. Perhaps Special:RevisionDelete could pass suppressed revision IDs to Echo at the time of action, saying "cancel any unsent notifications relating to this revision"? Seems like it might take some work to do though.

Failing that, I'd suggest a correction of:

Example mentioned you on the Example talk page, but that revision has been suppressed.


See Also:
T56433: Notification messages for mentions assume article namespace, do not reflect other namespaces

Details

Reference
bz64504

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 3:09 AM
bzimport added a project: Notifications.
bzimport set Reference to bz64504.
bzimport added a subscriber: Unknown Object (MLST).
SBisson claimed this task.
SBisson subscribed.

We do proactively remove notifications upon suppression of their associated page but not revision because of how the database is currently structured. Events are linked to pages with the event_page_id field, It is indexed so we can easily go find all the events related to the page that is currently being suppressed. However, revision data is part of event_extra in a json blob so we can't find event that are linked to a specific revision in a performant way.

I'm resolving this because the main problem reported here, the link to Talk:Example#This_page_revision_has_been_suppressed, is fixed. While the notification remains visible, its information is correctly replaced by removal messages and that seem consistent with the rest of MediaWiki.

Please reopen if I'm missing something.