Page MenuHomePhabricator

Special:OAuth/foo doesn't parse HTML error link
Closed, ResolvedPublic

Description

Steps to reproduce
Go to https://en.wikipedia.org/wiki/Special:OAuth/lorem_ipsum

Actual content:

Display
Sorry, something went wrong, you'll need to contact the application author for help with this.

Unknown URL, <a class="external" href="https://www.mediawiki.org/wiki/Help:OAuth/Errors#E002">E002</a>

Return to Main Page.
HTML
<p>Sorry, something went wrong, you'll need to contact the application author for help with this.
</p><p><span class="plainlinks mw-mwoautherror-details">Unknown URL, &lt;a class="external" href="<a class="external free" href="https://www.mediawiki.org/wiki/Help:OAuth/Errors#E002">https://www.mediawiki.org/wiki/Help:OAuth/Errors#E002</a>"&gt;E002&lt;/a&gt;</span>
</p><p id="mw-returnto">Return to <a href="/wiki/Main_Page" title="Main Page">Main Page</a>.</p>

Details

Related Changes in Gerrit:

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Sorry, something went wrong, you'll need to contact the application author for help with this.

Unknown URL, Error: E002

Return to Main Page.

is this what is required?
OR

Sorry, something went wrong, you'll need to contact the application author for help with this.

Unknown URL, E002

Return to Main Page.

where should I submit the Gerrit patch or pull request?

The raw HTML should be something like

<p>Sorry, something went wrong, you'll need to contact the application author for help with this.</p>
<p><span class="plainlinks mw-mwoautherror-details">Unknown URL, <a class="external" href="https://www.mediawiki.org/wiki/Help:OAuth/Errors#E002">E002</a></span></p>
<p id="mw-returnto">Return to <a href="/wiki/Main_Page" title="Main Page">Main Page</a>.</p>

You probably need to change how the relevant error message gets parsed, see the messages API.

The repo is mediawiki/extensions/OAuth on gerrit.

Sorry, something went wrong, you'll need to contact the application author for help with this.

Unknown URL, Error: E002

Return to Main Page.

I got the result using this raw HTML

<p>Sorry, something went wrong, you'll need to contact the application author for help with this.</p>
<p><span class="plainlinks mw-mwoautherror-details">Unknown URL, <a class="external free", href="https://www.mediawiki.org/wiki/Help:OAuth/Errors#E002">Error: E002</a></span></p>
<p id="mw-returnto">Return to <a href="/wiki/Main_Page" title="Main Page">Main Page</a>.</p>

do we need to display the description of error as well?

@Nikitrain Are you still working on this? If so (which would be fine), nevermind, if not, I would like to use this task as a Google-Code-in-2019 task? :)

@Florian I'm not currently working on this. You may use this as a Gooogle-code-in task. :)

Change 561366 had a related patch set uploaded (by BrandonXLF; owner: BrandonXLF):
[mediawiki/extensions/OAuth@master] Parse error E002 error link

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

Change 561366 merged by jenkins-bot:
[mediawiki/extensions/OAuth@master] Parse error E002 error link

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