Page MenuHomePhabricator

Bug report url is not rendered in the error message
Open, HighPublic

Description

Description:
When navigating to the Special:CommunityConfiguration/Mentorship page and attempting to save the configuration form, an error message is displayed with an unparsed link. The expected behavior is if the form has errors, any links in error messages to be correctly parsed.

Steps to Reproduce:

  1. Ensure your language is set to es
  2. Go to Special:CommunityConfiguration/Mentorship.(you must be logged out or not have permissions to save a configuration form for the error to show)
  3. Make changes to the configuration form.
  4. Click the 'Save' button.

Actual Results:
The following error message is displayed with an unparsed link:

Something went wrong when you saved your changes. Please try again later.

This page provides interface text for the software on this wiki, and is protected to prevent abuse. To add or change translations for all wikis, please use [https://translatewiki.net/ translatewiki.net], the MediaWiki localisation project.

If the problem persists, consider [$1 fill in a subject] in the bug reporting tool.

Expected Results:
If an error occurs, the error message should display a correctly parsed link.

Attachments:

Screenshot 2024-04-29 at 15.38.34.png (1×3 px, 431 KB)

Event Timeline

Cyndymediawiksim renamed this task from Parse link in error message to Error when saving configuration form on Special:CommunityConfiguration/Mentorship.Tue, Apr 30, 7:56 AM
Cyndymediawiksim updated the task description. (Show Details)

Note that we do set $wgCommunityConfigurationBugReportingToolURL in Beta:

urbanecm@wmf3345 mediawiki-config % git grep CommunityConfigurationBugReportingToolURL
wmf-config/CommonSettings.php:  $wgCommunityConfigurationBugReportingToolURL = 'https://phabricator.wikimedia.org/maniphest/task/edit/form/43';
urbanecm@wmf3345 mediawiki-config %
Sgs renamed this task from Error when saving configuration form on Special:CommunityConfiguration/Mentorship to Bug report url is not rendered in the error message.Tue, Apr 30, 11:53 AM

@Urbanecm_WMF, thank you for solving this quickly during our sync session. Assigning this to you to be moved to Q/A :).

@Etonkovidova Note this was a language-specific bug (only reproducable with the es language).

Urbanecm_WMF updated the task description. (Show Details)
Etonkovidova added a subscriber: KStoller-WMF.

Checked in es betalabs - the text (if translated) is displayed in Spanish.

Screen Shot 2024-04-30 at 12.45.42 PM.png (1×2 px, 269 KB)

Note: Will we have review of error messages for clarity and/or specificity? @KStoller-WMF

But the message about translatewiki is still unparsed and not in interface language.

Agreed, unless I'm missing something, it seems like this bug is unresolved.

Will we have review of error messages for clarity and/or specificity? @KStoller-WMF

I think that should be part of the general QA and design review (T359036) before releasing to pilot wikis, but I'm open to creating a new task for this specific purpose if you think it's needed.

@Cyndymediawiksim I think this needs more work, unless I'm misunderstanding something?

There are actually two bugs here: one is that the link to Phabricator does not appear, this is fixed by https://translatewiki.net/w/i.php?title=MediaWiki:Communityconfiguration-editor-client-file-bug/es&diff=prev&oldid=12379909. Second bug is that the link to translatewiki.net appears, but in wikitext syntax (it is not parsed). That second bug needs fixing separately. Reassigning to Cyndy to take a look on this.

There are actually two bugs here: one is that the link to Phabricator does not appear, this is fixed by https://translatewiki.net/w/i.php?title=MediaWiki:Communityconfiguration-editor-client-file-bug/es&diff=prev&oldid=12379909. Second bug is that the link to translatewiki.net appears, but in wikitext syntax (it is not parsed). That second bug needs fixing separately. Reassigning to Cyndy to take a look on this.

Sorry, my understanding was that it's a draft message representing a sort of work-in-progress state. Actually, there are more questions with that warning:

  • the warning message appears after an unauthorized user submits the form. The form should not be editable by unauthorized users.
  • the message is not specific enough: "Something went wrong when you saved your changes. Please try again later." Suggesting "Please try again later." for most likely unrecoverable failures might be misleading to users. In https://phabricator.wikimedia.org/T359928#9759270 there are specific examples of how failures are currently handled by VE and Special:EditGrowthConfig
  • "This page provides interface text for the software on this wiki, and is protected to prevent abuse." - the text might be misleading users into thinking that the form is about interface text for the software on this wiki, when, in fact, the form supplies numerical values that affect many aspects of Mentorship feature.
  • "To add or change translations..." - is the warning message the right place to suggest translation tool?

Thanks for listing out these other issues / questions we should be considering!

  • the warning message appears after an unauthorized user submits the form. The form should not be editable by unauthorized users.

That's OK for now. This should we resolved in T363525: Community Configuration edit form: protected / read only view.

the message is not specific enough: "Something went wrong when you saved your changes. Please try again later." Suggesting "Please try again later." for most likely unrecoverable failures might be misleading to users.

Agree, although for edge case errors that we can't predict I would rather have a "Please try again later" message than an error without any guidance.

"This page provides interface text for the software on this wiki, and is protected to prevent abuse." - the text might be misleading users into thinking that the form is about interface text for the software on this wiki, when, in fact, the form supplies numerical values that affect many aspects of Mentorship feature.

Agreed. Should we consider something like: "This page adjusts the configuration of [WikiLanguage] [WikiName], and is protected to prevent abuse." @JFernandez-WMF, will you suggest final copy?

"To add or change translations..." - is the warning message the right place to suggest translation tool?

I was also a little surprised by this. Is this currently a source of confusion for admins adjusting EditGrowthConfig? @Trizek-WMF

@KStoller-WMF , yes it needs more work but we do not need a separate task for it.IMO, it shouldn't be a big fix. I"ll create patches for it.

Regarding interface translation, I'm not sure. Homepage or Help panel have sometimes been pre-filled with English texts, which can be changed in EditGrowthConfig. having this link could be confusing. I would not keep the link there.

I'm more concerned about the lack of details regarding the error.

Regarding interface translation, I'm not sure. Homepage or Help panel have sometimes been pre-filled with English texts, which can be changed in EditGrowthConfig. having this link could be confusing. I would not keep the link there.

The interface message not being translated is a bug, fixed in 1026456. We cannot change the content of that particular error because it is used MW-wide. The reason why the message is confusing is a technical limitation due to the usage of the MediaWiki namespace for the json config pages. What we can do is to avoid to display that error in the particular use case where the user is not logged in.

I'm more concerned about the lack of details regarding the error.

Can you elaborate on which details are you missing. For context, here's a summary of the currently handled errors (using Spanish):
A) Client code errors

Screenshot 2024-05-06 at 16.21.51.png (1×1 px, 478 KB)

These are definitely bugs and we want to catch them asap, so asking for bug filing is fair. The headline includes Please try again later which seems also fair as a mechanism to "double-check" the error is persistent before filing a bug task.
B) Permissions errors (on submission)
When user does not have the right permissions to edit a configuration (could be a logged out user, not enough privileges, etc.)
Screenshot 2024-05-06 at 16.27.38.png (412×1 px, 108 KB)

In this case the headline includes Please try again later which seems out of point. Not sure about the prompt to file an issue in this situation, maybe miss-leading. Mind that the scenario of not having enough permissions should be almost impossible to reach once we resolve T363525.
C) Validation errors (on submission)
Screenshot 2024-05-06 at 16.32.31.png (386×1 px, 86 KB)

Ditto.. the headline includes Please try again later which seems out of point. These are the only error messages that we aren't able to translate yet since it's construction comes from a third party, the validation library we use, see T351879. Filing an issue in this case is also worth since we want to create forms that make "near to impossible" to generate invalid data. So we'd like to know if users are getting these kind of errors.

To summarize I think we need to:

  • Remove Please try again later from cases (B) and (C)
  • Maybe remove If the problem persists, consider filling an issue in the bug reporting tool. from case (B)
  • Prioritize T363525 and T351879 accordingly

What do you think? @KStoller-WMF @Trizek-WMF @JFernandez-WMF

Change #1026456 had a related patch set uploaded (by Sergio Gimeno; author: Sergio Gimeno):

[mediawiki/extensions/CommunityConfiguration@master] Editor: show API errors in the interface language

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

I'm not concerned by client code errors or permission error much. They are respectively independent from the form and users aren't supposed to edit a pages the have no right to edit.

Validation is more important. When I get a message that says "A number is required", I find it easier to handle if I know which field is concerned. I guess you plan to have it covered with the Key: parameter?

Connecting the top-of-the-page error message with the actual error is important. We have this problem at EditGrowth Feature, where a message at the top of the page says something went wrong, but nothing indicates which field is concerned, except if you scroll down the page. Have a link to jump to the error(s) would help.

Connecting the top-of-the-page error message with the actual error is important. We have this problem at EditGrowth Feature, where a message at the top of the page says something went wrong, but nothing indicates which field is concerned, except if you scroll down the page. Have a link to jump to the error(s) would help.

I filed T363855: Improve validation errors wording and behavior specifically for this, I'm waiting for design specifications, cc @JFernandez-WMF

Connecting the top-of-the-page error message with the actual error is important. We have this problem at EditGrowth Feature, where a message at the top of the page says something went wrong, but nothing indicates which field is concerned, except if you scroll down the page. Have a link to jump to the error(s) would help.

@Trizek-WMF - I filed T364057: [minor] CommunityConfiguration: success/failure messages require scrolling up ; it can be merged with other, more general form submission/validation improvement task(s).

  • I don't know what "considering" is supposed to mean - so should I? or should I not? Based on which criteria am I supposed to make an educated decision?
  • To whom is the link to the bug reporting tool exposed? Any users? CommunityConfiguration 'admins' only? Please think thrice before linking to an issue tracker instead of e.g. https://www.mediawiki.org/wiki/Extension_talk:CommunityConfiguration or such. It was a bad idea to make MediaViewer error messages link to Wikimedia Phabricator (see T188729 or resulting H297 ("Auto-close MediaViewer reports about CORS headers on 3rd party sites") if you can access Herald). You and I do not want to deal for years with support requests for extension configuration on random third-party wikis reported as Phabricator tasks, please. :)