Page MenuHomePhabricator

Bad copy when marking mentor as away for more than a year
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

  • Try to mark a mentor as away for more than a year in the ManageMentors interface

What happens?:

Input in "You'll be gone for" is too high. The maximum number of days a mentor can be away for is 365 (one year).

What should have happened instead?:

Input in "Away until" is too high. The maximum number of days a mentor can be away for is 365 (one year).

Software version (on Special:Version page; skip for WMF-hosted wikis like Wikipedia):

Other information (browser name/version, screenshots, etc.):

I found a bug in admin Growth features literally the day I picked up admin rights again after a several-month break. Wow.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Nice to hear from you again! Good catch. Hmm... This happens, because the other form this can be done from is at Special:MentorDashboard:

image.png (448×1 px, 63 KB)

As you can see, here it is indeed called //You’ll be gone for://. Since the error is generated at the backend (shared for both forms), rather than by the form itself, this would be easiest to fix if the copy stays the same in both forms. This means not referring to the field by its name.

@Pppery @KStoller-WMF Any ideas on how to change the copy to be like that? If this cannot be done, we can rearrange how we validate the input and have two different copies. Moving to Needs Discussion in the meantime.

Trivial suggestion: delete the first sentence and say just "The maximum number of days a mentor can be away for is 365 (one year)."

Trivial suggestion: delete the first sentence and say just "The maximum number of days a mentor can be away for is 365 (one year)."

Sometimes the simplest solution is best, I agree this makes sense.
Thanks, Pppery for taking the time to log this bug!

Change #1091887 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/extensions/GrowthExperiments@master] [i18n] mentorship: Make `toohigh` error message more generic

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

Urbanecm_WMF edited projects, added Growth-Team (Current Sprint); removed Growth-Team.

Thanks all! Changing the copy is trivial, so I just uploaded a patch that does that.

Testing locally, the $ is still visible{F57716061}

FTR: This impacts Special:MentorDashboard (while this task was about Special:ManageMentors). T380149: Mentor dashboard: Error message for "away for too long" errors does not substitute params covers the Special:MentorDashboard bug.

Change #1091887 merged by jenkins-bot:

[mediawiki/extensions/GrowthExperiments@master] [i18n] mentorship: Make `toohigh` error message more generic

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

Etonkovidova subscribed.

Checked in testwiki wmf.4 - the error message is corrected (the issue with displaying $1will be addressed in T380149:

Screen Shot 2024-11-25 at 6.50.54 PM.png (1×2 px, 253 KB)