Page MenuHomePhabricator

Allow user to mute notifications from Special:Mute page
Closed, ResolvedPublic2 Story Points

Description

This is a follow-up from T218265: Mute: Add links to disable email and mute specific user to emails sent via Special:EmailUser.

Value proposition

We should support muting notifications for users from Special:Mute, which is the special page we will be using for T218270: Mute: Add links to the Tools menu on user pages to mute/unmute user and T218266: Mute: Add links to mute specific user to Echo notification. This is also a step forward towards bringing the mute lists closer.

Acceptance criteria:

  • Add the second checkbox (Mute notifications from this user) on Special:Mute page:

  • If a user checks this checkbox and hits save, the user they are muting is added to the Muted users list under the Notifications tab in Special:Preferences.
  • After save, the checkboxes and save button go away and a confirmation message displays: User:ABC has been muted. See all muted users in Special:Preferences. - the link goes to Special:Preferences on the wiki they are on.
  • If a user lands on Special:Mute with the user they request to mute already being in one or both of the mute lists, those respective checkboxes are already checked. Unchecking a box and saving the form, removes the user from the respective mute list.

Note that this only holds if Echo is installed and enabled. If there is no Echo, we only show the one checkbox that's added in T218265

Event Timeline

Niharika triaged this task as Normal priority.Apr 5 2019, 12:33 AM
Niharika created this task.
Restricted Application added subscribers: MGChecker, Aklapper. · View Herald TranscriptApr 5 2019, 12:33 AM
Niharika updated the task description. (Show Details)Apr 17 2019, 5:06 PM
Niharika removed the point value for this task.

Just to clarify, if Echo is not enabled, then the checkboxes will not be there, correct? or would there be a single checkbox?

Just to clarify, if Echo is not enabled, then the checkboxes will not be there, correct? or would there be a single checkbox?

There will be a single checkbox. I'll add that to the description. :)

Niharika updated the task description. (Show Details)Apr 17 2019, 5:11 PM

Can we change the text of the "Mute user" button to just "Save"? The reason being, that if the user is unumutting a user, then they uncheck the box and then click "Mute user"? seems odd. :)

Can we change the text of the "Mute user" button to just "Save"? The reason being, that if the user is unumutting a user, then they uncheck the box and then click "Mute user"? seems odd. :)

Oh, good point. I'll update it. Thanks for catching that!

Niharika updated the task description. (Show Details)Apr 17 2019, 5:14 PM
Niharika set the point value for this task to 2.May 2 2019, 6:55 PM
dmaza claimed this task.Jun 21 2019, 12:31 PM
dmaza moved this task from Ready to In Progress on the Anti-Harassment (The Letter Song) board.

Change 520050 had a related patch set uploaded (by Dmaza; owner: Dmaza):
[mediawiki/core@master] [WIP] Add support for extentions to modify page form

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

Change 520051 had a related patch set uploaded (by Dmaza; owner: Dmaza):
[mediawiki/extensions/Echo@master] [WIP] Add Special:Mute notification blacklist through a Hook

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

dmaza added a comment.Jul 2 2019, 8:04 PM

@Niharika this task introduces a few changes that conflict with the error messages we added on T218265: Mute: Add links to disable email and mute specific user to emails sent via Special:EmailUser

For instance, we used to show the message below as an error page but if there is a second option like "Mute Notifications" it doesn't make sense to do that anymore.

`You must confirm your email address before you can mute a user. You may do so from Special:Preferences.`

I suggest that we get rid of all the error messages that arise from accessing the page with the wrong configs and add only a generic one if there are no options on the form. Suggestions welcome for this message
As to the option Mute emails from this user, I would say to only display it when all the conditions are met, meaning when wgEnableUserEmailBlacklist, wgEnableUserEmail are true and the user has confirmed their email address.

@dmaza Okay. Thinking about how the generic message can be most useful/informational to the user. Here's my sense of when there will be no options on the form -

  • Echo is not installed AND
  • Email address is not confirmed OR emails are disabled OR email blacklist is disabled in Special:Prefs

Am I missing a scenario?
If that is correct, we can say:

Mute features are unavailable. This might be because: you haven't confirmed your email address, your email blacklist is disabled in [[Special:Preferences]] or the wiki administrator has disabled email features for this wiki.

What do you think?

As to the option Mute emails from this user, I would say to only display it when all the conditions are met, meaning when wgEnableUserEmailBlacklist, wgEnableUserEmail are true and the user has confirmed their email address.

Agreed.

Instead of saying "Mute emails from this user" and "Mute emails from this user" would it be better to say: "Mute emails from user ABC" and "Mute notifications from user ABC"?

I was just wondering because when I first come to the page, my brain skips the first line entirely and I read the options, which use this and then I have to figure out what this is.

dmaza added a comment.Jul 11 2019, 3:23 PM

Instead of saying "Mute emails from this user" and "Mute emails from this user" would it be better to say: "Mute emails from user ABC" and "Mute notifications from user ABC"?
I was just wondering because when I first come to the page, my brain skips the first line entirely and I read the options, which use this and then I have to figure out what this is.

IMO it looks a bit repetitive to keep mentioning "user ABC" on the form fields. Maybe we could update the page header instead to make it more "in your face" that you are muting user ABC. What do you think @Niharika? But to be honest, if a user takes action on a form without reading what it is about or understanding it, there isn't much we can do

@dmaza @dbarratt I agree it seems repetitive. We can make the user's name bold in the sentence above to make it a bit more prominent but let's go with ...from this user for now.

@dmaza @dbarratt I agree it seems repetitive. We can make the user's name bold in the sentence above to make it a bit more prominent but let's go with ...from this user for now.

Sounds good to me

Change 520050 merged by Dbarratt:
[mediawiki/core@master] Add support for extentions to change Special:Mute form

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

Change 520051 merged by jenkins-bot:
[mediawiki/extensions/Echo@master] Add option to mute/unmute notifications on Special:Mute

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

dom_walden added a subscriber: dom_walden.

Special:Mute adds and removes from the user_properties table (also visible in Special:Preferences#mw-prefsection-echo).

Checked that it sets the mute globally (if configured) or locally (if locally overridden) as appropriate.

Tried different combinations of truth values for $wgEnableUserEmailBlacklist and $wgEchoPerUserBlacklist. Appears to work fine with one or both set to true.

You can "globally" mute a user with the config. variable $wgEchoAgentBlacklist (see). This fact is not reflected in either Special:Mute/Hugh or Special:Preferences. But muting the same user with Special:Mute appears harmless.

With the Echo extension disabled, Special:Mute works as before.

No errors seen in the logs.

dbarratt closed this task as Resolved.Jul 22 2019, 5:26 PM

You can "globally" mute a user with the config. variable $wgEchoAgentBlacklist (see). This fact is not reflected in either Special:Mute/Hugh or Special:Preferences. But muting the same user with Special:Mute appears harmless.

I hadn't seen that preference... that's fun.